diff options
| author | everdrone <[email protected]> | 2025-11-11 16:12:49 +0100 |
|---|---|---|
| committer | everdrone <[email protected]> | 2025-11-11 16:12:49 +0100 |
| commit | 6e7855d84e3bfd724ac0eacc20db34c1eee0761b (patch) | |
| tree | b10efc01119e5c0ec18a08dae3c9650a15b7f9f0 | |
| parent | ce9a9078a694d96800823577a6541ceb539b4aee (diff) | |
add docs for PinNumber
| -rw-r--r-- | embassy-stm32/src/gpio.rs | 5 | ||||
| -rw-r--r-- | embassy-stm32/src/rcc/n6.rs | 3 |
2 files changed, 8 insertions, 0 deletions
diff --git a/embassy-stm32/src/gpio.rs b/embassy-stm32/src/gpio.rs index 1813a887b..17c5a9962 100644 --- a/embassy-stm32/src/gpio.rs +++ b/embassy-stm32/src/gpio.rs | |||
| @@ -804,6 +804,11 @@ pub(crate) trait SealedPin { | |||
| 804 | /// is needed to hold the total pin number `(ports * number)`. | 804 | /// is needed to hold the total pin number `(ports * number)`. |
| 805 | #[cfg(not(stm32n6))] | 805 | #[cfg(not(stm32n6))] |
| 806 | pub type PinNumber = u8; | 806 | pub type PinNumber = u8; |
| 807 | |||
| 808 | /// GPIO pin number type. | ||
| 809 | /// | ||
| 810 | /// Some chips have a total number of ports that exceeds 8, a larger integer | ||
| 811 | /// is needed to hold the total pin number `(ports * number)`. | ||
| 807 | #[cfg(stm32n6)] | 812 | #[cfg(stm32n6)] |
| 808 | pub type PinNumber = u16; | 813 | pub type PinNumber = u16; |
| 809 | 814 | ||
diff --git a/embassy-stm32/src/rcc/n6.rs b/embassy-stm32/src/rcc/n6.rs index c9c874e75..866851bbd 100644 --- a/embassy-stm32/src/rcc/n6.rs +++ b/embassy-stm32/src/rcc/n6.rs | |||
| @@ -167,6 +167,7 @@ impl Config { | |||
| 167 | } | 167 | } |
| 168 | } | 168 | } |
| 169 | 169 | ||
| 170 | #[allow(dead_code)] | ||
| 170 | struct ClocksOutput { | 171 | struct ClocksOutput { |
| 171 | cpuclk: Hertz, | 172 | cpuclk: Hertz, |
| 172 | sysclk: Hertz, | 173 | sysclk: Hertz, |
| @@ -580,6 +581,7 @@ struct PllInput { | |||
| 580 | } | 581 | } |
| 581 | 582 | ||
| 582 | #[derive(Clone, Copy, Default)] | 583 | #[derive(Clone, Copy, Default)] |
| 584 | #[allow(dead_code)] | ||
| 583 | struct PllOutput { | 585 | struct PllOutput { |
| 584 | divm: Option<Hertz>, | 586 | divm: Option<Hertz>, |
| 585 | divn: Option<Hertz>, | 587 | divn: Option<Hertz>, |
| @@ -707,6 +709,7 @@ fn init_pll(pll_config: Option<Pll>, pll_index: usize, input: &PllInput) -> PllO | |||
| 707 | } | 709 | } |
| 708 | } | 710 | } |
| 709 | 711 | ||
| 712 | #[allow(dead_code)] | ||
| 710 | struct OscOutput { | 713 | struct OscOutput { |
| 711 | hsi: Option<Hertz>, | 714 | hsi: Option<Hertz>, |
| 712 | hse: Option<Hertz>, | 715 | hse: Option<Hertz>, |
