all hals: reexport PAC if unstable-pac feature is set.

This commit is contained in:
Dario Nieuwenhuis
2021-07-14 22:19:04 +02:00
parent 6444066589
commit f916fe5476
6 changed files with 30 additions and 0 deletions

View File

@ -5,6 +5,13 @@ authors = ["Dario Nieuwenhuis <dirbaio@dirbaio.net>"]
edition = "2018"
[features]
# Reexport the PAC for the currently enabled chip at `embassy_nrf::pac`.
# This is unstable because semver-minor (non-breaking) releases of embassy-nrf may major-bump (breaking) the PAC 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-pac = []
defmt-trace = [ ]
defmt-debug = [ ]
defmt-info = [ ]

View File

@ -65,7 +65,11 @@ mod chip;
#[path = "chips/nrf52840.rs"]
mod chip;
#[cfg(feature = "unstable-pac")]
pub use chip::pac;
#[cfg(not(feature = "unstable-pac"))]
pub(crate) use chip::pac;
pub use chip::{peripherals, Peripherals};
pub mod interrupt {