[PIC®/AVR®/dsPIC®产品] PIC 单片机 C 程序 MAPLAB 编译出错是什么原因?

[复制链接]
1037|9
 楼主| stormwind123 发表于 2025-1-15 14:56 | 显示全部楼层 |阅读模式
Error   [491] ; . can't find 0xC words for psect "temp" in segment "COMBANK"
Error   [593] ; . can't find 0xBB words (0xbb withtotal) for psect "text14" in segment "CODE"
Error   [593] ; . can't find 0xBA words (0xba withtotal) for psect "text21" in segment "CODE"
Error   [593] ; . can't find 0xAA words (0xaa withtotal) for psect "text24" in segment "CODE"
Error   [593] ; . can't find 0x8D words (0x8d withtotal) for psect "text22" in segment "CODE"
Error   [593] ; . can't find 0x72 words (0x72 withtotal) for psect "text9" in segment "CODE"
Error   [593] ; . can't find 0x72 words (0x72 withtotal) for psect "text20" in segment "CODE"
Error   [593] ; . can't find 0x65 words (0x65 withtotal) for psect "text17" in segment "CODE"
Error   [593] ; . can't find 0x4E words (0x4e withtotal) for psect "text12" in segment "CODE"
Error   [593] ; . can't find 0x3F words (0x3f withtotal) for psect "text13" in segment "CODE"
Error   [593] ; . can't find 0x1E words (0x1e withtotal) for psect "text0" in segment "CODE"
Error   [593] ; . can't find 0x1C words (0x1c withtotal) for psect "text7" in segment "CODE"
Error   [593] ; . can't find 0x1C words (0x1c withtotal) for psect "text6" in segment "CODE"
Error   [593] ; . can't find 0x16 words (0x16 withtotal) for psect "text8" in segment "CODE"
Error   [593] ; . can't find 0x16 words (0x16 withtotal) for psect "text15" in segment "CODE"
Error   [593] ; . can't find 0x15 words (0x15 withtotal) for psect "text" in segment "CODE"
Error   [593] ; . can't find 0x15 words (0x15 withtotal) for psect "text1" in segment "CODE"
Error   [593] ; . can't find 0x13 words (0x13 withtotal) for psect "text11" in segment "CODE"
Error   [593] ; . can't find 0x13 words (0x13 withtotal) for psect "text16" in segment "CODE"
Error   [593] ; . can't find 0x11 words (0x11 withtotal) for psect "text4" in segment "CODE"
Error   [593] ; . can't find 0x11 words (0x11 withtotal) for psect "text3" in segment "CODE"
Error   [593] ; . can't find 0x11 words (0x11 withtotal) for psect "text5" in segment "CODE"
Error   
elephant00 发表于 2025-1-15 15:36 | 显示全部楼层
检查代码中是否有拼写错误或作用域问题导致的未声明标识符错误。
两只袜子 发表于 2025-1-15 16:00 | 显示全部楼层
可能是编译环境配置问题
jcky001 发表于 2025-1-15 18:00 | 显示全部楼层
可能是交叉编译环境安装不正确
duo点 发表于 2025-1-15 18:00 | 显示全部楼层
检查变量、函数参数或返回值的类型是否一致。
cr315 发表于 2025-1-15 19:00 | 显示全部楼层
库文件路径未指定
onlycook 发表于 2025-1-15 20:00 | 显示全部楼层
代码可能有语法错误
onlycook 发表于 2025-1-15 20:26 | 显示全部楼层
在某些情况下,特别是在使用旧版本的MPLAB IDE和编译器时,变量的赋值顺序可能会影响编译结果。
七毛钱 发表于 2025-1-15 22:00 | 显示全部楼层
检查数组和其他数据结构的索引是否超出了其合法范围。
灰色与青 发表于 2025-9-20 15:56 | 显示全部楼层
PIC 单片机 C 程序在 MPLAB 中编译出错可能有多种原因:语法错误(如拼写、括号不匹配)、头文件缺失或路径错误、未定义的函数 / 变量、硬件配置不当(如时钟、引脚定义)、编译器版本不兼容,或选择的芯片型号与项目设置不符。
您需要登录后才可以回帖 登录 | 注册

本版积分规则

605

主题

3747

帖子

3

粉丝
快速回复 在线客服 返回列表 返回顶部