int main(void)
{
init_led();
init_pwm();
init_irq();
while(1){
switch(Run_Mode){
/*计算模式,此模式下将计算的SPWM脉冲宽度对应的定时器初值放入数组里面,需要关闭SPWM输出*/
case CALCULATION_MODE:
TCON &= (~(1<<8)); //首先关闭定时器1;
for(Count=1;Count<=N;Count++)
Spwm_Code_H[Count-1] = SPWM_CALCULATEF_H(Count);
GPBDATA &= (~(1<<5)); //LED1亮代表计算完成
break;
}
}
return 0;
}
编译出现:
main.c:(.text+0x144): undefined reference to `__aeabi_i2d'
main.c:(.text+0x150): undefined reference to `__aeabi_dmul'
main.c:(.text+0x15c): undefined reference to `__aeabi_dmul'
main.c:(.text+0x160): undefined reference to `cos'
main.c:(.text+0x174): undefined reference to `__aeabi_i2d'
main.c:(.text+0x180): undefined reference to `__aeabi_dmul'
main.c:(.text+0x18c): undefined reference to `__aeabi_dmul'
main.c:(.text+0x190): undefined reference to `cos'
main.c:(.text+0x1a4): undefined reference to `__aeabi_dsub'
main.c:(.text+0x1b0): undefined reference to `__aeabi_dmul'
main.c:(.text+0x1bc): undefined reference to `__aeabi_dmul'
main.c:(.text+0x1c8): undefined reference to `__aeabi_ddiv'
main.c:(.text+0x1d4): undefined reference to `__aeabi_dmul'
main.c:(.text+0x1d8): undefined reference to `__aeabi_d2uiz'
后来我自己把switch case语句给注释了,就没问题,请问我的switch case这样用有问题吗?
|