Quantcast
Channel: Microcontrollers
Viewing all articles
Browse latest Browse all 227049

Forum Post: TMS320F28379D: memcpy_fast_far() documenation.

$
0
0
Part Number: TMS320F28379D I am using memcpy_fast_far() from the C2000ware v1.00.06.00 FPU library and was reading the FPU DSP Software Library User's Guide ref Oct 18,2018 pg 124. The documentation says: 5.46 Optimized Memory Copy (Far Memory) Description: Header File: fpu_vector.h Declaration: This module performs optimized memory copy of data in far (>22-bit address space) memory to near memory void memcpy_fast_far(volatile void* dst, volatile const void* src, uint16_t N); Usage: memcpy_fast_far(dst, src, N); volatile void* dst pointer to destination volatile const void* src pointer to source N number of 16-bit words to copy Alignment Requirements: None However the example code shows: #include "fpu_vector.h" #define SIZE 0x500 // 32-Bit Word //Buffer in local memory Uint32 g_ulLocalRAMBuf[SIZE]; //Buffer in far memory __attribute__((far)) volatile Uint32 g_ulSDRAMBuf[SIZE]; main() { // Read far memory buffer into local (near) buffer memcpy_fast_far(g_ulLocalRAMBuf, g_ulSDRAMBuf, SIZE); } Which is correct? 1) Is N supposed to be the number of 16 bit words? and the example code is wrong (only copying half of the data buffer)? 2) Or is the example correct and N is the number of 32 bit words, and the documentation incorrect?

Viewing all articles
Browse latest Browse all 227049


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>