STM32F303 上的引导加载程序:工厂内置还是外部编程?

Bootloader on STM32F303: built in from factory or externally programmed?

我对 ATMEL 和 ATMEL 引导加载程序有一些了解,我们正在为一个新项目转向 ARM。特别是我们将使用 STM32F303RET6。 这本质上是一个具有更多模拟输入引脚的 Cortex M4。

我一直在浏览有关引导加载程序的文档,但我感到非常困惑:

Getting Started Document 的第 19 页,它说了以下内容:

"The embedded boot loader is located in the System memory, programmed by ST during production"

此外,应用说明 AN2606,第 81 页提到此内置引导加载程序不支持通过 USB 编程。 (仅限 UART、I2C 或 CAN)

然而 在 Internet 上的其他地方(例如 this one,虽然是 F103)我已经读到需要编程使用 ST-link V2 (ISP) 的引导程序。

其中我很困惑,所以这是我的问题:

我知道我很困惑,非常感谢你的帮助。

谢谢 佩德罗

application note AN2606, page 81 mentions this built in bootloader does not support programming over USB. (only UART, I2C or CAN)

第 81 页的标题说 STM32F303x4(6/8)/334xx/328xx 设备引导加载程序,但你说你有一个 STM32F303RE6。在第 77 页查找 table 36 以找到您的设备。

Do STM32 chips actually come with a bootloader programmed from factory or not?

他们有。

Is the factory embedded bootloader some form of failsafe, "always there" programming interface?

它一直都在,您可能会认为它是故障保险。另一个故障保护是 JTAG/SWD 调试器接口。

Meaning I can later program a second bootloader?

是的,你可以。然后你可以 select 哪一个到 运行 通过外部引脚。

if I use the ST-linkV2 programmer will I overwrite the factory programmed bootloader?

没有,没有危险,生产后内部写保护。

I am at a total loss regarding the BOOT1 selection bit. How am I supposed to set it if it's a logic feature of the processor?

BOOT0和BOOT1是输入脚。您可以从外部设置它,使用 pullup/pulldown 电阻器、开关、跳线,无论您的电路板提供什么。在我的探索板上,它们在引脚 headers.

上可用

Finally can I reflash this chip over USB or not?

根据参考手册,可以。

Do I need a different bootloader?

没有,但是当你对内部的不满意时,你可以换一个。 STM32CubeF3 库分发中有一个示例,在 Projects/STM32F303RE-Nucleo/Applications/USB_Device/DFU_Standalone.