mirror of
https://github.com/embassy-rs/embassy.git
synced 2025-09-27 04:10:25 +00:00
Updated stm32-metapac
This commit is contained in:
parent
556ae0106b
commit
92d12b5d88
@ -81,7 +81,7 @@ futures-util = { version = "0.3.30", default-features = false }
|
||||
sdio-host = "0.9.0"
|
||||
critical-section = "1.1"
|
||||
#stm32-metapac = { version = "16" }
|
||||
stm32-metapac = { git = "https://github.com/embassy-rs/stm32-data-generated", tag = "stm32-data-f0ef9106642ed869e7cfbf82d891d364c98ebb43" }
|
||||
stm32-metapac = { git = "https://github.com/embassy-rs/stm32-data-generated", tag = "stm32-data-a236d845991bb48198427e08dc61ae3e257057a8" }
|
||||
|
||||
vcell = "0.1.3"
|
||||
nb = "1.0.0"
|
||||
@ -110,7 +110,7 @@ proc-macro2 = "1.0.36"
|
||||
quote = "1.0.15"
|
||||
|
||||
#stm32-metapac = { version = "16", default-features = false, features = ["metadata"]}
|
||||
stm32-metapac = { git = "https://github.com/embassy-rs/stm32-data-generated", tag = "stm32-data-f0ef9106642ed869e7cfbf82d891d364c98ebb43", default-features = false, features = ["metadata"] }
|
||||
stm32-metapac = { git = "https://github.com/embassy-rs/stm32-data-generated", tag = "stm32-data-a236d845991bb48198427e08dc61ae3e257057a8", default-features = false, features = ["metadata"] }
|
||||
|
||||
[features]
|
||||
default = ["rt"]
|
||||
|
@ -5,7 +5,6 @@ use core::marker::PhantomData;
|
||||
use embassy_hal_internal::PeripheralType;
|
||||
use stm32_metapac::vrefbuf::vals::*;
|
||||
|
||||
use crate::pac::RCC;
|
||||
use crate::Peri;
|
||||
|
||||
/// Voltage Reference (VREFBUF) driver.
|
||||
@ -20,14 +19,17 @@ impl<'d, T: Instance> VoltageReferenceBuffer<'d, T> {
|
||||
pub fn new(_instance: Peri<'d, T>, voltage_scale: Vrs, impedance_mode: Hiz) -> Self {
|
||||
#[cfg(rcc_wba)]
|
||||
{
|
||||
use crate::pac::RCC;
|
||||
RCC.apb7enr().modify(|w| w.set_vrefen(true));
|
||||
}
|
||||
#[cfg(any(rcc_u5, rcc_h50, rcc_h5))]
|
||||
{
|
||||
use crate::pac::RCC;
|
||||
RCC.apb3enr().modify(|w| w.set_vrefen(true));
|
||||
}
|
||||
#[cfg(any(rcc_h7rs, rcc_h7rm0433, rcc_h7ab, rcc_h7))]
|
||||
{
|
||||
use crate::pac::RCC;
|
||||
RCC.apb4enr().modify(|w| w.set_vrefen(true));
|
||||
}
|
||||
let vrefbuf = T::regs();
|
||||
|
Loading…
x
Reference in New Issue
Block a user