Hello dear friends!
I am using FIR16 filter from fixed point dsp library (fir.h, fir16.asm - V1.20.00.00).
In description FIXEDPT-SW-LIB-UG-V1.20.00.00 have note:
1. The delay buffer is assigned to a section, “firldb”, which should be aligned to 256 word boundary in the data memory (RAM) for the FIR16 module. The FIR16_Alt module does not require any alignment
2. The coefficients are placed in a section, “firfilt”, that can be placed anywhere in the data memory (RAM).
I create coefficients from MatLab, and generate .h file with this coefficients.
Do I understand correctly, if I use reorder function, I can not align the filter coefficient in the memory?
if((FIR_ORDER & 0x01) == 0){
revCoeff[FIR_ORDER_REV-1] = 0;
}
// Reorder the coefficients
for(i = 0; i < FIR_ORDER + 2; i = i + 2){
revCoeff[FIR_ORDER_REV-i-1] = coeff[i/2+FIR_ORDER_REV/2];
revCoeff[FIR_ORDER_REV-i-2] = coeff[i/2];
}
I only align the dbuffer in memory?
firldb align(0x100) > RAMM0, PAGE = 0
Because in .cmd file from example (F28335_FIXPT_FIR_lnk.cmd) specified:
firldb align(0x100) > RAML1, PAGE = 0
firfilt : > RAML1, PAGE = 0
#if defined(RAM)
coefffilt align(0x100)> RAML2, PAGE = 0
#elif defined(FLASH)
coefffilt align(0x100)> FLASHA, PAGE = 0
#endif //RAM


