This repository was archived by the owner on Jul 29, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +12
-6
lines changed
Expand file tree Collapse file tree 2 files changed +12
-6
lines changed Original file line number Diff line number Diff line change @@ -18,6 +18,8 @@ panic-halt = "0.2.0"
1818# alloc-cortex-m = "0.3.5"
1919
2020# Uncomment for the device example.
21+ # Update `memory.x`, set target to `thumbv7em-none-eabihf` in `.cargo/config`,
22+ # and then use `cargo build --examples device` to build it.
2123# [dependencies.stm32f3]
2224# features = ["stm32f303", "rt"]
2325# version = "0.7.1"
Original file line number Diff line number Diff line change 55//!
66//! [`svd2rust`]: https://crates.io/crates/svd2rust
77//!
8- //! This example depends on the [`stm32f103xx`] crate so you'll have to add it to your Cargo.toml.
8+ //! This example depends on the [`stm32f3`] crate so you'll have to
9+ //! uncomment it in your Cargo.toml.
910//!
10- //! [`stm32f103xx `]: https://crates.io/crates/stm32f103xx
11+ //! [`stm32f3 `]: https://crates.io/crates/stm32f3
1112//!
1213//! ```
1314//! $ edit Cargo.toml && tail $_
14- //! [dependencies.stm32f103xx ]
15- //! features = ["rt"]
16- //! version = "0.10.0 "
15+ //! [dependencies.stm32f3 ]
16+ //! features = ["stm32f303", " rt"]
17+ //! version = "0.7.1 "
1718//! ```
1819//!
20+ //! You also need to set the build target to thumbv7em-none-eabihf,
21+ //! typically by editing `.cargo/config` and uncommenting the relevant target line.
22+ //!
1923//! ---
2024
2125#![ no_main]
@@ -27,7 +31,7 @@ extern crate panic_halt;
2731use cortex_m:: peripheral:: syst:: SystClkSource ;
2832use cortex_m_rt:: entry;
2933use cortex_m_semihosting:: hprint;
30- use stm32f30x :: { interrupt, Interrupt , NVIC } ;
34+ use stm32f3 :: stm32f303 :: { interrupt, Interrupt , NVIC } ;
3135
3236#[ entry]
3337fn main ( ) -> ! {
You can’t perform that action at this time.
0 commit comments