aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--embassy-stm32/Cargo.toml4
-rw-r--r--embassy-stm32/src/vrefbuf/mod.rs4
2 files changed, 5 insertions, 3 deletions
diff --git a/embassy-stm32/Cargo.toml b/embassy-stm32/Cargo.toml
index 590216c21..c4322b9ba 100644
--- a/embassy-stm32/Cargo.toml
+++ b/embassy-stm32/Cargo.toml
@@ -81,7 +81,7 @@ futures-util = { version = "0.3.30", default-features = false }
81sdio-host = "0.9.0" 81sdio-host = "0.9.0"
82critical-section = "1.1" 82critical-section = "1.1"
83#stm32-metapac = { version = "16" } 83#stm32-metapac = { version = "16" }
84stm32-metapac = { git = "https://github.com/embassy-rs/stm32-data-generated", tag = "stm32-data-f0ef9106642ed869e7cfbf82d891d364c98ebb43" } 84stm32-metapac = { git = "https://github.com/embassy-rs/stm32-data-generated", tag = "stm32-data-a236d845991bb48198427e08dc61ae3e257057a8" }
85 85
86vcell = "0.1.3" 86vcell = "0.1.3"
87nb = "1.0.0" 87nb = "1.0.0"
@@ -110,7 +110,7 @@ proc-macro2 = "1.0.36"
110quote = "1.0.15" 110quote = "1.0.15"
111 111
112#stm32-metapac = { version = "16", default-features = false, features = ["metadata"]} 112#stm32-metapac = { version = "16", default-features = false, features = ["metadata"]}
113stm32-metapac = { git = "https://github.com/embassy-rs/stm32-data-generated", tag = "stm32-data-f0ef9106642ed869e7cfbf82d891d364c98ebb43", default-features = false, features = ["metadata"] } 113stm32-metapac = { git = "https://github.com/embassy-rs/stm32-data-generated", tag = "stm32-data-a236d845991bb48198427e08dc61ae3e257057a8", default-features = false, features = ["metadata"] }
114 114
115[features] 115[features]
116default = ["rt"] 116default = ["rt"]
diff --git a/embassy-stm32/src/vrefbuf/mod.rs b/embassy-stm32/src/vrefbuf/mod.rs
index 2546ccfed..f614fcf99 100644
--- a/embassy-stm32/src/vrefbuf/mod.rs
+++ b/embassy-stm32/src/vrefbuf/mod.rs
@@ -5,7 +5,6 @@ use core::marker::PhantomData;
5use embassy_hal_internal::PeripheralType; 5use embassy_hal_internal::PeripheralType;
6use stm32_metapac::vrefbuf::vals::*; 6use stm32_metapac::vrefbuf::vals::*;
7 7
8use crate::pac::RCC;
9use crate::Peri; 8use crate::Peri;
10 9
11/// Voltage Reference (VREFBUF) driver. 10/// Voltage Reference (VREFBUF) driver.
@@ -20,14 +19,17 @@ impl<'d, T: Instance> VoltageReferenceBuffer<'d, T> {
20 pub fn new(_instance: Peri<'d, T>, voltage_scale: Vrs, impedance_mode: Hiz) -> Self { 19 pub fn new(_instance: Peri<'d, T>, voltage_scale: Vrs, impedance_mode: Hiz) -> Self {
21 #[cfg(rcc_wba)] 20 #[cfg(rcc_wba)]
22 { 21 {
22 use crate::pac::RCC;
23 RCC.apb7enr().modify(|w| w.set_vrefen(true)); 23 RCC.apb7enr().modify(|w| w.set_vrefen(true));
24 } 24 }
25 #[cfg(any(rcc_u5, rcc_h50, rcc_h5))] 25 #[cfg(any(rcc_u5, rcc_h50, rcc_h5))]
26 { 26 {
27 use crate::pac::RCC;
27 RCC.apb3enr().modify(|w| w.set_vrefen(true)); 28 RCC.apb3enr().modify(|w| w.set_vrefen(true));
28 } 29 }
29 #[cfg(any(rcc_h7rs, rcc_h7rm0433, rcc_h7ab, rcc_h7))] 30 #[cfg(any(rcc_h7rs, rcc_h7rm0433, rcc_h7ab, rcc_h7))]
30 { 31 {
32 use crate::pac::RCC;
31 RCC.apb4enr().modify(|w| w.set_vrefen(true)); 33 RCC.apb4enr().modify(|w| w.set_vrefen(true));
32 } 34 }
33 let vrefbuf = T::regs(); 35 let vrefbuf = T::regs();