Crate embassy_stm32
source ·Expand description
Feature flags
-
rt
(enabled by default) — Enablestm32-metapac
’srt
feature -
defmt
— Usedefmt
for logging -
memory-x
— Automatically generatememory.x
file usingstm32-metapac
-
nightly
— Enable nightly-only features -
unstable-pac
— Re-export stm32-metapac atembassy_stm32::pac
. This is unstable because semver-minor (non-breaking) releases of embassy-stm32 may major-bump (breaking) the stm32-metapac version. If this is an issue for you, you’re encouraged to directly depend on a fixed version of the PAC. There are no plans to make this stable. -
unstable-traits
— Implement embedded-hal 1.0 alpha traits. Implement embedded-hal-async traits ifnightly
is set as well.
Time
-
time
— Enables additional driver features that depend on embassy-time -
time-driver-any
— Use any time driver -
time-driver-tim2
— Use TIM2 as time driver -
time-driver-tim3
— Use TIM3 as time driver -
time-driver-tim4
— Use TIM4 as time driver -
time-driver-tim5
— Use TIM5 as time driver -
time-driver-tim12
— Use TIM12 as time driver -
time-driver-tim15
— Use TIM15 as time driver
Analog Switch Pins (Pxy_C) on STM32H7 series
Get PXY
and PXY_C
singletons. Digital impls are on PXY
, Analog impls are on PXY_C
If disabled, you get only the PXY
singleton. It has both digital and analog impls.
-
split-pa0
— Split PA0 -
split-pa1
— Split PA1 -
split-pc2
— Split PC2 -
split-pc3
— Split PC3 -
_split-pins-enabled
— internal use only
Chip-selection features
Select your chip by specifying the model as a feature, e.g. stm32c011d6
.
Check the Cargo.toml
for the latest list of supported chips.
Important: Do not forget to adapt the target chip in your toolchain,
e.g. in .cargo/config.toml
.
Re-exports
pub use stm32_metapac as pac;
Modules
- Interrupt definitions.
- Types for the peripheral singletons.
- Time units
Macros
- Macro to bind interrupts to handlers.
Structs
- An exclusive reference to a peripheral.
- Struct containing all the peripheral singletons.
Constants
- Number available in the NVIC for configuring priority
Traits
- Trait for any type that can be used as a peripheral of type
P
.
Functions
- Initialize embassy.