请选择 进入手机版 | 继续访问电脑版
搜索
查看: 724|回复: 4

[求助] mplab x ide 的MCC配置不能配置中断,否则自动生成代码不能...

[复制链接]
发表于 2018-7-26 23:57:45 | 显示全部楼层 |阅读模式
我的电脑系统win7  64;
mplab x ide 4.2;
xc8 v2.0;
使用pic16f18854单片机;
在使用MCC配置时如果不配置任何一个中断,则MCC生成的代码可以编译;
如果使用MCC配置,在配置中包含中断,怎MCC生成代码无法编译。
显示错误如下:
make -f nbproject/Makefile-default.mk SUBPROJECTS= .build-conf
make[1]: Entering directory 'D:/Code_mpxide/Test1.X'
make  -f nbproject/Makefile-default.mk dist/default/production/Test1.X.production.hex
make[2]: Entering directory 'D:/Code_mpxide/Test1.X'
"C:\Program Files (x86)\Microchip\xc8\v2.00\bin\xc8-cc.exe"  -mcpu=16F18854 -c  -fno-short-double -fno-short-float -O0 -fasmfile -maddrqual=ignore -xassembler-with-cpp -Wa,-a -DXPRJ_default=default  -msummary=-psect,-class,+mem,-hex,-file  -ginhx032 -Wl,--data-init -mno-keep-startup -mno-osccal -mno-resetbits -mno-save-resetbits -mno-download -mno-stackcall   -std=c99 -gdwarf-3 -mstack=compiled:auto:auto     -o build/default/production/main.p1 main.c
"C:\Program Files (x86)\Microchip\xc8\v2.00\bin\xc8-cc.exe"  -mcpu=16F18854 -c  -fno-short-double -fno-short-float -O0 -fasmfile -maddrqual=ignore -xassembler-with-cpp -Wa,-a -DXPRJ_default=default  -msummary=-psect,-class,+mem,-hex,-file  -ginhx032 -Wl,--data-init -mno-keep-startup -mno-osccal -mno-resetbits -mno-save-resetbits -mno-download -mno-stackcall   -std=c99 -gdwarf-3 -mstack=compiled:auto:auto     -o build/default/production/mcc_generated_files/mcc.p1 mcc_generated_files/mcc.c
"C:\Program Files (x86)\Microchip\xc8\v2.00\bin\xc8-cc.exe"  -mcpu=16F18854 -c  -fno-short-double -fno-short-float -O0 -fasmfile -maddrqual=ignore -xassembler-with-cpp -Wa,-a -DXPRJ_default=default  -msummary=-psect,-class,+mem,-hex,-file  -ginhx032 -Wl,--data-init -mno-keep-startup -mno-osccal -mno-resetbits -mno-save-resetbits -mno-download -mno-stackcall   -std=c99 -gdwarf-3 -mstack=compiled:auto:auto     -o build/default/production/mcc_generated_files/interrupt_manager.p1 mcc_generated_files/interrupt_manager.c
In file included from mcc_generated_files/interrupt_manager.c:49:
mcc_generated_files/interrupt_manager.h:109:6: error: variable has incomplete type 'void'
void interrupt INTERRUPT_InterruptManager(void);
     ^
mcc_generated_files/interrupt_manager.h:109:15: error: expected ';' after top level declarator
void interrupt INTERRUPT_InterruptManager(void);
              ^
              ;
In file included from main.c:44:
In file included from ./mcc_generated_files/mcc.h:53:
./mcc_generated_files/interrupt_manager.h:109:6: error: variable has incomplete type 'void'
void interrupt INTERRUPT_InterruptManager(void);
     ^
./mcc_generated_files/interrupt_manager.h:109:15: error: expected ';' after top level declarator
void interrupt INTERRUPT_InterruptManager(void);
              ^
              ;
2 errors generated.
(908) exit status = 1
nbproject/Makefile-default.mk:189: recipe for target 'build/default/production/main.p1' failed
In file included from mcc_generated_files/mcc.c:47:
In file included from mcc_generated_files/mcc.h:53:
mcc_generated_files/interrupt_manager.h:109:6: error: variable has incomplete type 'void'
void interrupt INTERRUPT_InterruptManager(void);
     ^
mcc_generated_files/interrupt_manager.h:109:15: error: expected ';' after top level declarator
void interrupt INTERRUPT_InterruptManager(void);
              ^
              ;
2 errors generated.
(908) exit status = 1
nbproject/Makefile-default.mk:175: recipe for target 'build/default/production/mcc_generated_files/mcc.p1' failed
mcc_generated_files/interrupt_manager.c:52:6: error: variable has incomplete type 'void'
void interrupt INTERRUPT_InterruptManager (void)
     ^
mcc_generated_files/interrupt_manager.c:52:15: error: expected ';' after top level declarator
void interrupt INTERRUPT_InterruptManager (void)
              ^
              ;
4 errors generated.
make[2]: *** [build/default/production/main.p1] Error 1
make[2]: *** Waiting for unfinished jobs....
make[2]: *** [build/default/production/mcc_generated_files/mcc.p1] Error 1
make[2]: *** [build/default/production/mcc_generated_files/interrupt_manager.p1] Error 1
make[1]: *** [.build-conf] Error 2
make: *** [.build-impl] Error 2
(908) exit status = 1
nbproject/Makefile-default.mk:161: recipe for target 'build/default/production/mcc_generated_files/interrupt_manager.p1' failed
make[2]: Leaving directory 'D:/Code_mpxide/Test1.X'
nbproject/Makefile-default.mk:90: recipe for target '.build-conf' failed
make[1]: Leaving directory 'D:/Code_mpxide/Test1.X'
nbproject/Makefile-impl.mk:39: recipe for target '.build-impl' failed
BUILD FAILED (exit value 2, total time: 2s)

回复

使用道具 举报

发表于 2018-8-14 18:53:06 | 显示全部楼层
我也是第一次用这个芯片,用C来写这个代码 不知道如何设置中断入口(用的是PIC16F1947),求高手指点。
回复 支持 反对

使用道具 举报

发表于 2018-8-15 09:52:08 | 显示全部楼层
XC8版本的问题
回复 支持 反对

使用道具 举报

发表于 2018-8-17 19:18:10 | 显示全部楼层
XC8 下载1.45版本
回复 支持 反对

使用道具 举报

发表于 2018-8-20 09:06:07 | 显示全部楼层
建的工程应该和mplab开发环境在同一个盘符下。mplab安装在C盘,那么新建的工程也要放在C盘。
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

关闭

站长推荐上一条 /5 下一条

facebook google plus twitter linkedin youku weibo rss
©2018 Microchip Corporation

小黑屋|手机版|Archiver|Microchip技术社区

GMT+8, 2018-11-15 05:33 , Processed in 0.050215 second(s), 6 queries , MemCache On.

快速回复 返回顶部 返回列表