This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

CCS/TMS320F28377S: ramp generation

Part Number: TMS320F28377S
Other Parts Discussed in Thread: TMS320F28035

Tool/software: Code Composer Studio

hi,

i am using ramp generation macro it was different in tms320f28035 and tms320f28377s

i am confused in this loop

#define    ANGLE_WRAP(angle)              \
             if(angle > _IQ(1.0))         \
               angle -= _IQ(1.0);         \
             else if(angle < _IQ(0.0))    \
               angle += _IQ(1.0);

this was in tms320f28035

and

#define    ANGLE_WRAP(angle)            \
             if(angle > 1.0)            \
               angle -= 2.0;            \
             else if(angle < -1.0)      \
               angle += 2.0;

this was in tms320f28377s

please assist me

  • This is for using different scale factor, the _IQ(0.0) to _IQ(1.0) in per unit means 0 to 2*PI in F28035 using IQmath library, but -1.0 to 1.0 means -PI to PI, or 0.0 to 2.0 means 0 to 2*PI in F2837x using FPU math library.