-
Notifications
You must be signed in to change notification settings - Fork 54
/
Copy pathlib.rs
executable file
·71 lines (56 loc) · 1.44 KB
/
lib.rs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
#![no_std]
#![allow(non_camel_case_types)]
#[cfg(not(feature = "device-selected"))]
compile_error!(
"This crate requires one of the following features enabled: stm32g030, stm32g070, stm32g031, stm32g041, stm32g071, stm32g081, stm32g0b1"
);
extern crate bare_metal;
extern crate void;
pub extern crate cortex_m;
pub extern crate embedded_hal as hal;
pub extern crate nb;
pub extern crate stm32g0;
pub use nb::block;
#[cfg(feature = "device-selected")]
pub use stm32 as pac;
#[cfg(feature = "stm32g030")]
pub use stm32g0::stm32g030 as stm32;
#[cfg(feature = "stm32g031")]
pub use stm32g0::stm32g031 as stm32;
#[cfg(feature = "stm32g041")]
pub use stm32g0::stm32g041 as stm32;
#[cfg(feature = "stm32g071")]
pub use stm32g0::stm32g071 as stm32;
#[cfg(feature = "stm32g081")]
pub use stm32g0::stm32g081 as stm32;
#[cfg(feature = "stm32g070")]
pub use stm32g0::stm32g070 as stm32;
#[cfg(feature = "stm32g0b1")]
pub use stm32g0::stm32g0b1 as stm32;
#[cfg(feature = "rt")]
pub use crate::stm32::interrupt;
pub mod analog;
pub mod crc;
pub mod dma;
pub mod dmamux;
pub mod exti;
pub mod flash;
pub mod gpio;
pub mod i2c;
pub mod power;
pub mod prelude;
pub mod rcc;
#[cfg(any(feature = "stm32g041", feature = "stm32g081"))]
pub mod rng;
pub mod rtc;
pub mod serial;
pub mod spi;
pub mod time;
pub mod timer;
pub mod watchdog;
#[cfg(feature = "device-selected")]
mod sealed {
pub trait Sealed {}
}
#[cfg(feature = "device-selected")]
pub(crate) use sealed::Sealed;