Part Number: TMS320F280049
Dear Champs,
I am asking this for our customers.
They are confused about some casting issues on CLA.
They wrote codes like below:
// In xxx.cla
int16_T A;
// In xxx.c
A = -7U;
// Use CPU to CLA
#pragma DATA_SECTION(A, "CpuToClaMsgRAM");
// in xxx.cla, cast int16 to int32
int32_T U;
U = (int32_T)(A);
// In CCS window,
They found U = 65529 rather than -7.
However, if they use positive value for A, then it works correctly.
Would you please show me why it is?
Why is it viewed as unsigned rather than signed int?
Or is there any restriction when using negative integer value for CLA?
What is the correct way to cast them?
Wayne Huang