如何才能支持这两个头文件

发布于 2024-06-18 13:44:24

请问如何才能让w806支持#include <libmaple/pwr.h>

include <libmaple/scb.h>这两个头文件?? 这是在STM32中使用的,我是新手,不知道怎么弄,所以才来求助,希望大佬能答疑解惑。

查看更多

关注者
0
被浏览
953
2 个回答
abcd
abcd 认证专家 2024-06-18
我只是个路过的老年人~

1、确认下是否用到了这两个头文件里的接口或者定义,如果没用到直接删除引用头文件即可,或者直接删除看是否能编译通过。
2、在第一步确认的基础上,确实用到了这两个头文件,那需要有这两个.h的源文件,剩下的操作就和stm32用keil编译一样了,在CDK里左边的工程处,右键add这两个头文件到工程里,在工程设置里把头文件的的路径添加上。就可以了。

AnatolSher
AnatolSher 认证专家 2024-06-20
Lover of the ocean, yachts and Arduino

Hello newbie! When adapting code for STM32 to use on the W806, you need to understand the differences in the hardware of these controllers. That is, the code can be divided into two parts - hardware dependent and hardware independent. You must rework the hardware-dependent part in relation to the features of the W806.
You may not need STM32-specific header files

撰写答案

请登录后再发布答案,点击登录

发布
问题

分享
好友

手机
浏览

扫码手机浏览