Test application to see if USB works on STM32 in Rust...spoilers...not so much.
[target.thumbv7em-none-eabi]
# use the Tlink.x scrip from the cortex-m-rt crate
rustflags = [
"-C", "link-arg=-Tlink.x",
]
[build]
target = "thumbv7em-none-eabi"
[dependencies.stm32f3xx-hal]
version = "0.9.1"
features = ["stm32f303xe", "rt"]
/* memory.x - Linker script for the STM32F303ZET6 */
MEMORY
{
/* Flash memory begins at 0x80000000 and has a size of 512KB*/
FLASH : ORIGIN = 0x08000000, LENGTH = 512K
/* RAM begins at 0x20000000 and has a size of 64kB*/
RAM : ORIGIN = 0x20000000, LENGTH = 64K
}
> cargo build --target thumbv7em-none-eabi --release
> cargo flash --target thumbv7em-none-eabi --chip STM32F303ZETx --release