MCU:STM32F407
環(huán)境:VSCode + PlatformIO IDE + STM32CubeF4(v1.5.2)
編譯器:7.2.1 20170904 (release) [ARM/embedded-7-branch revision 255204]
PlatformIO Core: version 5.1.1
問題描述
由于用的是STM32F4平臺(tái)哈肖,在ST產(chǎn)品線中定位為高性能計(jì)算產(chǎn)品浆熔,帶有FPU和DSP指令集书蚪,這不用來做數(shù)字信號(hào)處理屬實(shí)浪費(fèi)规揪,剛好近期工作需求要用到FFT或者FIR,所以迷帜,萬事俱備口叙,開搞!织盼!
1. DSP庫在哪?文檔酱塔?
看了一下PlatformIO自帶的STM32CubeF4庫沥邻,為了節(jié)約服務(wù)器帶寬和用戶下載時(shí)間,所以包很精簡羊娃,可是...這用起來很不方便呀唐全,沒有文檔怎么寫代碼?
于是去官網(wǎng)下了一個(gè)標(biāo)準(zhǔn)版本蕊玷,1.6.1最新版邮利,帶了文檔。然而后來才發(fā)現(xiàn)垃帅,原來CMSIS文檔是有在線版的:>>> CMSIS DSP Software Library <<<
官網(wǎng):STMicroelectronics/STM32CubeF4: STM32Cube MCU Full Package for the STM32F4 series - Github
2. 編譯Demo
按理說三分鐘出demo的事延届,結(jié)果一開始情況就不太妙...首先找到自帶例程(為了要例程還是得下完整庫)。拿一個(gè)FIR的例子開刀:
復(fù)制進(jìn)自己的項(xiàng)目贸诚,該函數(shù)名方庭,燒錄運(yùn)行?運(yùn)行效果:
=垂獭械念!直接復(fù)制進(jìn)來用會(huì) 遇到成噸報(bào)錯(cuò)轟炸!运悲!
觀察日志會(huì)發(fā)現(xiàn)基本全是CMSIS庫中的變量缺失錯(cuò)誤龄减,以及類型缺失錯(cuò)誤。定位錯(cuò)誤可以發(fā)現(xiàn):
類型錯(cuò)誤很好解決班眯,直接導(dǎo)入HAL的總?cè)肟?h文件
#include <stm32f4xx_hal.h>
(加到math_helper.h
頂部)希停。參考:#error "Compiler generates FPU instructions for a device without an FPU (check __FPU_PRESENT)"
3. arm_math.h:932:41: error: redefinition of '__SMLALD'
編譯過后,錯(cuò)誤少了一大筐:
但依然會(huì)有類似這種錯(cuò)誤:
C:\Users\JOY\.platformio\packages\framework-stm32cubef4\Drivers\CMSIS\Include/cmsis_gcc.h:1652:31: note: previous definition of '__SHADD16' was here
1652 | __STATIC_FORCEINLINE uint32_t __SHADD16(uint32_t op1, uint32_t op2)
| ^~~~~~~~~
In file included from lib\arm_fir_example_f32\math_helper.h:45,
from lib\arm_fir_example_f32\arm_fir_example_f32.c:125:
C:\Users\JOY\.platformio\packages\framework-stm32cubef4\Drivers\CMSIS\DSP\Include/arm_math.h:932:41: error: redefinition of '__SMLALD'
932 | CMSIS_INLINE __STATIC_INLINE uint64_t __SMLALD(
| ^~~~~~~~
In file included from C:\Users\JOY\.platformio\packages\framework-stm32cubef4\Drivers\CMSIS\Include/cmsis_compiler.h:48,
from C:\Users\JOY\.platformio\packages\framework-stm32cubef4\Drivers\CMSIS\Include/core_cm4.h:162,
from C:\Users\JOY\.platformio\packages\framework-stm32cubef4\Drivers\CMSIS\Device\ST\STM32F4xx\Include/stm32f407xx.h:167,
from C:\Users\JOY\.platformio\packages\framework-stm32cubef4\Drivers\CMSIS\Device\ST\STM32F4xx\Include/stm32f4xx.h:133,
from C:\Users\JOY\.platformio\packages\framework-stm32cubef4\Drivers\STM32F4xx_HAL_Driver\Inc/stm32f4xx_hal_def.h:30,
from C:\Users\JOY\.platformio\packages\framework-stm32cubef4\Drivers\STM32F4xx_HAL_Driver\Inc/stm32f4xx_hal_rcc.h:29,
from C:\Users\JOY\.platformio\packages\framework-stm32cubef4\Drivers\STM32F4xx_HAL_Driver\Inc/stm32f4xx_hal_conf.h:281,
from C:\Users\JOY\.platformio\packages\framework-stm32cubef4\Drivers\STM32F4xx_HAL_Driver\Inc/stm32f4xx_hal.h:30,
from lib\arm_fir_example_f32\math_helper.h:44,
from lib\arm_fir_example_f32\arm_fir_example_f32.c:125:
繼續(xù)定位署隘,發(fā)現(xiàn)缺失的變量在cmsis_iccarm.h
文件有定義:
根據(jù)導(dǎo)入鏈脖苏,查看
arm_math.h
文件,發(fā)現(xiàn)里面有這樣一行宏定義定踱,在VSCode中顯示為灰色:
#if defined(ARM_MATH_CM7)
#include "core_cm7.h"
#define ARM_MATH_DSP
#elif defined (ARM_MATH_CM4)
#include "core_cm4.h"
#define ARM_MATH_DSP
這個(gè)解決辦法就很明確了,直接在頂層include 文件添加一個(gè)宏定義恃鞋,對(duì)應(yīng)到自己的MCU平臺(tái)即可崖媚。由于STM32F4系列對(duì)應(yīng)于Cortex-M4架構(gòu)亦歉,所以這里定義一個(gè)ARM_MATH_CM4
。
math_helper.h頭部:
#define ARM_MATH_CM4
#include <stm32f4xx_hal.h>
#include "arm_math.h"
編譯:
4. arm_fir_example_f32.c:202: undefined reference to `arm_fir_f32'
Archiving .pio\build\black_f407zg\liba89\libarm_fir_example_f32.a
Archiving .pio\build\black_f407zg\libFrameworkCMSISDevice.a
Linking .pio\build\black_f407zg\firmware.elf
c:/users/joy/.platformio/packages/toolchain-gccarmnoneeabi@2.00000.0/bin/../lib/gcc/arm-none-eabi/10.2.1/../../../../arm-none-eabi/bin/ld.exe: .pio\build\black_f407zg\liba89\libarm_fir_example_f32.a(arm_fir_example_f32.o): in function `fir_test':
C:\Documents\PlatformIO\Projects\STM32F4_ADC_Sampling_v2/lib\arm_fir_example_f32/arm_fir_example_f32.c:194: undefined reference to `arm_fir_init_f32'
c:/users/joy/.platformio/packages/toolchain-gccarmnoneeabi@2.00000.0/bin/../lib/gcc/arm-none-eabi/10.2.1/../../../../arm-none-eabi/bin/ld.exe: C:\Documents\PlatformIO\Projects\STM32F4_ADC_Sampling_v2/lib\arm_fir_example_f32/arm_fir_example_f32.c:202: undefined reference to `arm_fir_f32'
collect2.exe: error: ld returned 1 exit status
*** [.pio\build\black_f407zg\firmware.elf] Error 1
經(jīng)典的符號(hào)未定義問題畅哑,而且是在link階段出現(xiàn)的肴楷,說明DSP庫沒有正確鏈接上。也就是說這個(gè)庫對(duì)于編譯器來說是不知道在哪個(gè)位置的荠呐,需要自己添加上赛蔫。
定位庫文件:
用的GCC編譯器,進(jìn)去發(fā)現(xiàn)問題來了泥张,選哪個(gè)呢呵恢?
搜索了解后知道,l是指little endian媚创,f是指帶有硬件除法器渗钉,那么沒有疑問,用帶lf的那個(gè)钞钙,也就是
libarm_cortexM4lf_math.a
鳄橘。
5. 導(dǎo)入DSP靜態(tài)庫
問題又來了,怎么導(dǎo)入到PIO呢芒炼?
打開platformio.ini
文件瘫怜,在環(huán)境中添加一行:
build_flags =
-LC:\Users\JOY\.platformio\packages\framework-stm32cubef4\Drivers\CMSIS\Lib\GCC
-larm_cortexM4lf_math
第N次編譯,結(jié)果:
c:/users/joy/.platformio/packages/toolchain-gccarmnoneeabi@2.00000.0/bin/../lib/gcc/arm-none-eabi/10.2.1/../../../../arm-none-eabi/bin/ld.exe: error: C:\Users\JOY\.platformio\packages\framework-stm32cubef4\Drivers\CMSIS\Lib\GCC\libarm_cortexM4lf_math.a(arm_fir_init_q15.o) uses VFP register arguments, .pio\build\black_f407zg\firmware.elf does not
c:/users/joy/.platformio/packages/toolchain-gccarmnoneeabi@2.00000.0/bin/../lib/gcc/arm-none-eabi/10.2.1/../../../../arm-none-eabi/bin/ld.exe: failed to merge target specific data of file C:\Users\JOY\.platformio\packages\framework-stm32cubef4\Drivers\CMSIS\Lib\GCC\libarm_cortexM4lf_math.a(arm_fir_init_q15.o)
c:/users/joy/.platformio/packages/toolchain-gccarmnoneeabi@2.00000.0/bin/../lib/gcc/arm-none-eabi/10.2.1/../../../../arm-none-eabi/bin/ld.exe: error: C:\Users\JOY\.platformio\packages\framework-stm32cubef4\Drivers\CMSIS\Lib\GCC\libarm_cortexM4lf_math.a(arm_fir_init_f32.o) uses VFP register arguments, .pio\build\black_f407zg\firmware.elf does not
c:/users/joy/.platformio/packages/toolchain-gccarmnoneeabi@2.00000.0/bin/../lib/gcc/arm-none-eabi/10.2.1/../../../../arm-none-eabi/bin/ld.exe: failed to merge target specific data of file C:\Users\JOY\.platformio\packages\framework-stm32cubef4\Drivers\CMSIS\Lib\GCC\libarm_cortexM4lf_math.a(arm_fir_init_f32.o)
c:/users/joy/.platformio/packages/toolchain-gccarmnoneeabi@2.00000.0/bin/../lib/gcc/arm-none-eabi/10.2.1/../../../../arm-none-eabi/bin/ld.exe: error: C:\Users\JOY\.platformio\packages\framework-stm32cubef4\Drivers\CMSIS\Lib\GCC\libarm_cortexM4lf_math.a(arm_fir_f32.o) uses VFP register arguments, .pio\build\black_f407zg\firmware.elf does not
c:/users/joy/.platformio/packages/toolchain-gccarmnoneeabi@2.00000.0/bin/../lib/gcc/arm-none-eabi/10.2.1/../../../../arm-none-eabi/bin/ld.exe: failed to merge target specific data of file C:\Users\JOY\.platformio\packages\framework-stm32cubef4\Drivers\CMSIS\Lib\GCC\libarm_cortexM4lf_math.a(arm_fir_f32.o)
collect2.exe: error: ld returned 1 exit status
*** [.pio\build\black_f407zg\firmware.elf] Error 1
6. 啟用編譯器(MCU)浮點(diǎn)數(shù)擴(kuò)展
這里理一下思路:我們要用F4的浮點(diǎn)數(shù)運(yùn)算能力本刽,但是浮點(diǎn)數(shù)運(yùn)算需要用到VFP指令和寄存器鲸湃,但是libarm_cortexM4lf_math.a
使用了VFP
寄存器,而.pio\build\black_f407zg\firmware.elf
沒有使用....
這個(gè)問題的解讀就是盅安,生成一個(gè)可執(zhí)行文件elf時(shí)唤锉,其所有的中間對(duì)象*.o
都要是同樣的編譯條件,至少對(duì)于VFP指令集的設(shè)置應(yīng)該是相同的别瞭。但是目前的ELF
文件沒有啟用這個(gè)選項(xiàng)窿祥。
那么問題就簡單了,啟用一下不就可以了蝙寨,而方式應(yīng)該就是通過對(duì)編譯器傳參晒衩,在platformIO中就對(duì)應(yīng)于,設(shè)置platformio.ini
文件中的build_flags
墙歪。
查過以上資料后听系,發(fā)現(xiàn)我應(yīng)該這么設(shè)置:
[env:black_f407zg]
build_type = debug
platform = ststm32
board = black_f407zg
framework = stm32cube
upload_protocol = stlink
debug_tool = stlink
monitor_speed = 115200
build_flags =
-LC:\Users\JOY\.platformio\packages\framework-stm32cubef4\Drivers\CMSIS\Lib\ARM
-larm_cortexM4lf_math
-mthumb -mcpu=cortex-m4 -march=armv7e-m -mfloat-abi=hard -mfpu=fpv4-sp-d16
也就是添加一行5個(gè)flag
-mthumb -mcpu=cortex-m4 -march=armv7e-m -mfloat-abi=hard -mfpu=fpv4-sp-d16
使用過后,編譯結(jié)果:
c:/users/joy/.platformio/packages/toolchain-gccarmnoneeabi@2.00000.0/bin/../lib/gcc/arm-none-eabi/10.2.1/../../../../arm-none-eabi/bin/ld.exe: failed to merge target specific data of file .pio\build\black_f407zg\FrameworkHALDriver\Src\stm32f4xx_ll_fsmc.o
c:/users/joy/.platformio/packages/toolchain-gccarmnoneeabi@2.00000.0/bin/../lib/gcc/arm-none-eabi/10.2.1/../../../../arm-none-eabi/bin/ld.exe: error: .pio\build\black_f407zg\src\system_stm32f4xx.o uses VFP register arguments, .pio\build\black_f407zg\firmware.elf does not
c:/users/joy/.platformio/packages/toolchain-gccarmnoneeabi@2.00000.0/bin/../lib/gcc/arm-none-eabi/10.2.1/../../../../arm-none-eabi/bin/ld.exe: failed to merge target specific data of file .pio\build\black_f407zg\src\system_stm32f4xx.o
c:/users/joy/.platformio/packages/toolchain-gccarmnoneeabi@2.00000.0/bin/../lib/gcc/arm-none-eabi/10.2.1/../../../../arm-none-eabi/bin/ld.exe: error: .pio\build\black_f407zg\liba89\libarm_fir_example_f32.a(arm_fir_example_f32.o) uses VFP register arguments, .pio\build\black_f407zg\firmware.elf does not
...
c:/users/joy/.platformio/packages/toolchain-gccarmnoneeabi@2.00000.0/bin/../lib/gcc/arm-none-eabi/10.2.1/../../../../arm-none-eabi/bin/ld.exe: failed to merge target specific data of file .pio\build\black_f407zg\liba89\libarm_fir_example_f32.a(arm_fir_example_f32.o)
c:/users/joy/.platformio/packages/toolchain-gccarmnoneeabi@2.00000.0/bin/../lib/gcc/arm-none-eabi/10.2.1/../../../../arm-none-eabi/bin/ld.exe: error: .pio\build\black_f407zg\liba89\libarm_fir_example_f32.a(fft.o) uses VFP register arguments, .pio\build\black_f407zg\firmware.elf does not
c:/users/joy/.platformio/packages/toolchain-gccarmnoneeabi@2.00000.0/bin/../lib/gcc/arm-none-eabi/10.2.1/../../../../arm-none-eabi/bin/ld.exe: failed to merge target specific data of file .pio\build\black_f407zg\liba89\libarm_fir_example_f32.a(fft.o)
c:/users/joy/.platformio/packages/toolchain-gccarmnoneeabi@2.00000.0/bin/../lib/gcc/arm-none-eabi/10.2.1/../../../../arm-none-eabi/bin/ld.exe: error: .pio\build\black_f407zg\liba89\libarm_fir_example_f32.a(math_helper.o) uses VFP register arguments, .pio\build\black_f407zg\firmware.elf does not
c:/users/joy/.platformio/packages/toolchain-gccarmnoneeabi@2.00000.0/bin/../lib/gcc/arm-none-eabi/10.2.1/../../../../arm-none-eabi/bin/ld.exe: failed to merge target specific data of file .pio\build\black_f407zg\liba89\libarm_fir_example_f32.a(math_helper.o)
c:/users/joy/.platformio/packages/toolchain-gccarmnoneeabi@2.00000.0/bin/../lib/gcc/arm-none-eabi/10.2.1/../../../../arm-none-eabi/bin/ld.exe: error: .pio\build\black_f407zg\liba89\libarm_fir_example_f32.a(arm_fir_data.o) uses VFP register arguments, .pio\build\black_f407zg\firmware.elf does not
c:/users/joy/.platformio/packages/toolchain-gccarmnoneeabi@2.00000.0/bin/../lib/gcc/arm-none-eabi/10.2.1/../../../../arm-none-eabi/bin/ld.exe: failed to merge target specific data of file .pio\build\black_f407zg\liba89\libarm_fir_example_f32.a(arm_fir_data.o)
c:/users/joy/.platformio/packages/toolchain-gccarmnoneeabi@2.00000.0/bin/../lib/gcc/arm-none-eabi/10.2.1/../../../../arm-none-eabi/bin/ld.exe: error: C:\Users\JOY\.platformio\packages\framework-stm32cubef4\Drivers\CMSIS\Lib\GCC\libarm_cortexM4lf_math.a(arm_fir_init_q15.o) uses VFP register arguments, .pio\build\black_f407zg\firmware.elf does not
c:/users/joy/.platformio/packages/toolchain-gccarmnoneeabi@2.00000.0/bin/../lib/gcc/arm-none-eabi/10.2.1/../../../../arm-none-eabi/bin/ld.exe: failed to merge target specific data of file C:\Users\JOY\.platformio\packages\framework-stm32cubef4\Drivers\CMSIS\Lib\GCC\libarm_cortexM4lf_math.a(arm_fir_init_q15.o)
c:/users/joy/.platformio/packages/toolchain-gccarmnoneeabi@2.00000.0/bin/../lib/gcc/arm-none-eabi/10.2.1/../../../../arm-none-eabi/bin/ld.exe: error: C:\Users\JOY\.platformio\packages\framework-stm32cubef4\Drivers\CMSIS\Lib\GCC\libarm_cortexM4lf_math.a(arm_fir_init_f32.o) uses VFP register arguments, .pio\build\black_f407zg\firmware.elf does not
c:/users/joy/.platformio/packages/toolchain-gccarmnoneeabi@2.00000.0/bin/../lib/gcc/arm-none-eabi/10.2.1/../../../../arm-none-eabi/bin/ld.exe: failed to merge target specific data of file C:\Users\JOY\.platformio\packages\framework-stm32cubef4\Drivers\CMSIS\Lib\GCC\libarm_cortexM4lf_math.a(arm_fir_init_f32.o)
c:/users/joy/.platformio/packages/toolchain-gccarmnoneeabi@2.00000.0/bin/../lib/gcc/arm-none-eabi/10.2.1/../../../../arm-none-eabi/bin/ld.exe: error: C:\Users\JOY\.platformio\packages\framework-stm32cubef4\Drivers\CMSIS\Lib\GCC\libarm_cortexM4lf_math.a(arm_fir_f32.o) uses VFP register arguments, .pio\build\black_f407zg\firmware.elf does not
c:/users/joy/.platformio/packages/toolchain-gccarmnoneeabi@2.00000.0/bin/../lib/gcc/arm-none-eabi/10.2.1/../../../../arm-none-eabi/bin/ld.exe: failed to merge target specific data of file C:\Users\JOY\.platformio\packages\framework-stm32cubef4\Drivers\CMSIS\Lib\GCC\libarm_cortexM4lf_math.a(arm_fir_f32.o)
collect2.exe: error: ld returned 1 exit status
*** [.pio\build\black_f407zg\firmware.elf] Error 1
使用過后虹菲,不但出現(xiàn)了前面的靜態(tài)鏈接庫鏈接不上的問題靠胜,其他所有文件都鏈接不上了。。浪漠。陕习??址愿?
7. 大地的災(zāi)難
查查資料该镣,發(fā)現(xiàn)眾說紛紜,講什么的都有响谓,其中比較有代表性和參考價(jià)值的幾篇:
Cortex-M4F: xxx.elf uses VFP register arguments, yyy.o does not · Issue #2660 · RIOT-OS/RIOT
這篇內(nèi)容相當(dāng)精煉损合,是用GCC+Makefile寫的,編譯參數(shù)透明娘纷,參考價(jià)值比較大嫁审。里面用到的編譯參數(shù)是:CCFLAGS=-mcpu=cortex-m4 -mthumb -g -mfloat-abi=hard -fsingle-precision-constant -mfpu=fpv4-sp-d16 -I ../../CMSIS/CMSIS-master/CMSIS/Include -D ARM_MATH_CM4 -D __FPU_PRESENT=1
Simple DSP with ARM CMSIS and GCC on the STM32F303
用Keil用DSP庫是基本沒太大問題的,至少不會(huì)有奇怪到難以解決的問題失驶。Using cortex-m4 FPU with gcc toolchain
這篇是一個(gè)日本人寫的土居,用谷歌翻譯了一下,證明用STM32CubeIDE是可以直接用沒問題的嬉探。如何在STM32 Cube IDE環(huán)境中使用CMSIS-DSP | ioloa.com
總結(jié):這里查了一堆資料擦耀,然而并沒有什么卵用。
8. 遲來的春天
這地方卡了我一整天涩堤,真的調(diào)到后面腦袋都大了眷蜓。。胎围。查了很多資料都沒有解決吁系,直到后來想到既然其他IDE沒問題,會(huì)不會(huì)是PlatformIO的問題白魂?然后看到這篇:
-
How to pass flags to final firmware.elf linkage? - PlatformIO Core - PlatformIO Community
這個(gè)標(biāo)題似乎沒有什么汽纤,但后來才反應(yīng)過來這就是我想要的...不過里面提到的一個(gè)bug issue鏈接參考價(jià)值很大,: -
Flags specified in platformio.ini build_flags variable not applied to all necessary steps in the build process · Issue #594 · platformio/platformio-core
這里講的是PlatformIO的一個(gè)bug福荸,而且是2016年5月就有人提了issue蕴坪,而且被官方人員關(guān)閉了。我當(dāng)然會(huì)以為早已經(jīng)修復(fù)好了敬锐,但是還是抱著試試的心態(tài)測試了一下背传,里面提到的方案是:
在platformio.ini
文件中添加一行extra_script = update_link_flags.py
:
[env:disco_f407vg]
platform = ststm32
framework = spl
board = disco_f407vg
build_flags = -mthumb -march=armv7e-m -mfloat-abi=hard -mfpu=fpv4-sp-d16
extra_script = update_link_flags.py
然后在項(xiàng)目根目錄中添加一個(gè)文件:update_link_flags.py
,內(nèi)容為:
# Custom settings, as referred to as "extra_script" in platformio.ini
#
# See http://docs.platformio.org/en/latest/projectconf.html#extra-script
from SCons.Script import DefaultEnvironment
env = DefaultEnvironment()
env.Append(
LINKFLAGS=[
"-mthumb",
"-march=armv7e-m",
"-mfloat-abi=hard",
"-mfpu=fpv4-sp-d16"
]
)
9. 原因分析
總的來說台夺,就是一顆老鼠屎径玖,毀了整鍋湯的案例重現(xiàn),因?yàn)镻latformIO或者stm32插件的一個(gè)漏網(wǎng)的bug颤介,導(dǎo)致后來成噸不明所以的編譯錯(cuò)誤梳星。
表現(xiàn)為:
如圖中描述的赞赖,編譯過程的Flags不會(huì)對(duì)所有中間對(duì)象都生效,也就是說丰泊,這里的
firmware.elf
文件薯定,在編譯過程中是沒有拿到build_flags
中的參數(shù)的瞳购,也就導(dǎo)致最終所有中間對(duì)象*.o
文件無法鏈接到這個(gè)target中來。而解決辦法就是,使用一個(gè)額外的腳本(extra_script),用于在編譯時(shí)滴劲,對(duì)每個(gè)編譯對(duì)象重新添加一遍flags芯砸,從而規(guī)避了這個(gè)bug双揪。
可是這都16年的bug了婴噩,怎么留到現(xiàn)在的迅办???哭死o(╥﹏╥)o
其他解決方案
其實(shí)也有折中的辦法,但是都不能完美解決問題。
- 使用softfp浮點(diǎn)數(shù)指令,這樣可以解決玩敏,但是效率會(huì)成問題几苍,尤其是DSP這類密集性計(jì)算算法。
- 使用
libarm_cortexM4l_math.a
庫文件圣拄,實(shí)測是可以正常編譯且正常執(zhí)行的。但是這種方案也是沒有用到浮點(diǎn)數(shù)指令的,所以還是類似軟件浮點(diǎn)數(shù)的方法衰腌,損失了效率饶囚。 - 換其他IDE,比如Keil或者STM32CubeIDE衫仑,似乎都不會(huì)遇到這個(gè)問題瞄崇,但是代碼編寫體驗(yàn)不如VSCode。
總結(jié)
解決這個(gè)問題的過程是比較曲折的苏研,甚至我試著按照PlatformIO格式更新了STM32Cube庫到最新版等浊,還有去ARM官網(wǎng)下載了新版的編譯器,也沒有效果摹蘑。但是中間還是有比較多的收獲筹燕,掌握了STM32 DSP庫的用法,PIO插件的格式衅鹿,以及查閱文檔撒踪、檢索資料的習(xí)慣等等。