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.

28035的CLA任务内部是否可以定义和使用局部变量?



#pragma DATA_SECTION(current,"CpuToCla1MsgRAM");
volatile float current;

#pragma DATA_SECTION(power,"ClaDataRam0");
volatile float power;

__interrupt void Cla1Task1 ( void )
{

float fi;//此处是否可以定义局部变量?

fi = current*current;

power = 1.015 * 58 * fi;

}