请教两个问题:
1. 程序有时候编译能通过,运行(reset go) 时会弹出出现Progam counter is odd的错误,请问
是怎么回事,如何消除这个错误。
2. 还有一个是HEw里面用emum 的问题:
例如定义如下:
enum T_ANGLES
{
DEG350 = 63715,
DEG10 = 1820,
DEG50 = 9102,
DEG70 = 12743,
DEG110 = 20024,
DEG130 = 23665,
DEG170 = 30947,
DEG190 = 34588,
DEG230 = 41870,
DEG250 = 45511,
DEG290 = 52793,
DEG310 = 56434,
DEG22 = 4005,
DEG90 = 16384,
DEG285 = 51883
};
有的值超过了Int 的界限,会报错,请问有什么好的解决方案。一定要用
#define DEG350 63715
吗?
共6条
1/1 1 跳转至页
Progam Counter is odd

关键词: Progam Counter

第一个问题没遇到过,只能Google一下。
有两条信息相关。查查PC和SP指针吧。尤其是程序中用汇编改过什么的话。
Program counter is odd Since the program counter holds an odd value, execution of
the program is not possible.
If a PC or SP value is illegally set (e.g., an odd value) and the user program is
executed, an error message such as ‘Program counter is odd’ may be displayed
twice.
有两条信息相关。查查PC和SP指针吧。尤其是程序中用汇编改过什么的话。
Program counter is odd Since the program counter holds an odd value, execution of
the program is not possible.
If a PC or SP value is illegally set (e.g., an odd value) and the user program is
executed, an error message such as ‘Program counter is odd’ may be displayed
twice.
共6条
1/1 1 跳转至页
回复
有奖活动 | |
---|---|
【有奖活动】分享技术经验,兑换京东卡 | |
话不多说,快进群! | |
请大声喊出:我要开发板! | |
【有奖活动】EEPW网站征稿正在进行时,欢迎踊跃投稿啦 | |
奖!发布技术笔记,技术评测贴换取您心仪的礼品 | |
打赏了!打赏了!打赏了! |
打赏帖 | |
---|---|
基于MSPM0L1306的MODBUS-RTU协议通讯实验被打赏50分 | |
每周了解几个硬件知识+485硬件知识分享被打赏10分 | |
【换取手持示波器】树莓派PICOW网页烟花被打赏18分 | |
【换取手持示波器】树莓派PICO逻辑分析仪被打赏16分 | |
【分享评测,赢取加热台】教你五分钟本地部署蒸馏版本的DeepSeekR1-7B被打赏12分 | |
【换取手持示波器】蓝牙音箱更换电池被打赏8分 | |
【换取手持示波器】鼠标更换微动开关被打赏10分 | |
【我要开发板】4.传感器移植被打赏50分 | |
【换取手持数字示波器】RISC-VGCC使用-fno-omit-frame-pointer编译选项实现栈回溯被打赏29分 | |
【分享评测,赢取加热台】+开关电源简述被打赏7分 |