如何修复 Keil EFM8 ERROR C267 'SLAB_ASSERT': requires ANSI-style prototype
问题:
你想编译你的 EFM8 应用程序,但你看到这些错误消息:
efm8-errors.txt
*** WARNING C206 IN LINE 86 OF C:\SiliconLabs\SimplicityStudio\v4\developer\sdks\8051\v4.1.7\Device\EFM8BB3\peripheral_driver\src\adc_0.c: 'SLAB_ASSERT': missing function-prototype
*** ERROR C267 IN LINE 86 OF C:\SiliconLabs\SimplicityStudio\v4\developer\sdks\8051\v4.1.7\Device\EFM8BB3\peripheral_driver\src\adc_0.c: 'SLAB_ASSERT': requires ANSI-style prototype解决方案
进入你的项目属性(通过在左上角右键单击你的项目并点击"Properties")-> C/C++ Build -> Project Modules
在那里,选择 8051 -> EFM8 并勾选 Assert 复选框以包含断言模块。现在重新编译你的模块。

If this post helped you, please consider buying me a coffee or donating via PayPal to support research & publishing of new posts on TechOverflow