MStory2.0 소스 컴파일 시 에러 발생 시 대처법 (첨부파일 참조)
Mango-Z1.Firmware
Z1.Src009.USB.HID
basic_rf.c Error[Pe147]: declaration is incompatible with "__nounwind __interwork __softfp unsigned long __get_PSP(void)" (declared at line 52 of "C:\ D:\TmpDnFiles\MStory2.0\Mango-Z1.Firmware\Libraries\CMSIS\Core\CM3\core_cm3.h 667 Program Files (x86)\IAR Systems\Embedded Workbench 7.3\arm\inc\c\intrinsics.h") ... ... ... ... ... ... ... |
General Options -> Library Configuration -> USE CMSIS 선택
MStory2.0\Mango-Z1.Firmware\Libraries\CMSIS\Core\CM3폴더로 이동합니다.
core_cm3.c와core_cm3.h를 삭제합니다.
이제는 에러는 없이 빌드되지만 Warning이 있습니다.
startup_stm32f10x_md.s Warning[25]: Label 'NMI_Handler' is defined pubweak in a section implicitly declared root D:\TmpDnFiles\MStory2.0\Mango-Z1.Firmware\Libraries\CMSIS\Core\CM3\startup\iar\startup_stm32f10x_md.s 123 ... ... ... ... ... ... ... |
해당 Warning을 클릭합니다.
startup_stm32f10x_md.s 파일이 열립니다.
PUBWEAK NMI_Handler SECTION .text:CODE:REORDER:NOROOT(1) NMI_Handler B NMI_Handler
PUBWEAK HardFault_Handler SECTION .text:CODE:REORDER:NOROOT(1) HardFault_Handler B HardFault_Handler |
위와 같이 해당 위치에 :NOROOT를 추가하면 됩니다.
모든 위치에 작업을 합니다.
이에 재 빌드를 수행하면 모든 문제가 없이 빌드됩니다.
내용