Skip to content

Commit c380e0e

Browse files
committed
[Fixes #74] First attempt on embedded-hal 1.0
The model is inspired by Embassy's `embassy-rp` HAL.
1 parent 46a36c9 commit c380e0e

File tree

15 files changed

+211
-40
lines changed

15 files changed

+211
-40
lines changed

Cargo.lock

Lines changed: 96 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

hal/Cargo.toml

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -29,11 +29,14 @@ rust-version = "1.70"
2929

3030
[dependencies]
3131
cortex-m = { version = "0.7" }
32-
embedded-hal = { version = "0.2.7" }
32+
embedded-hal-02 = { package = "embedded-hal", version = "0.2.7", features = ["unproven"] }
33+
embedded-hal-1 = { package = "embedded-hal", version = "1.0" }
34+
embedded-hal-async = { version = "1.0" }
35+
embedded-hal-nb = { version = "1.0" }
3336
nb = "1"
34-
fugit = "0.3.6"
37+
fugit = "0.3.7"
3538
paste = "1"
36-
usb-device = "0.3.1"
39+
usb-device = "0.3.2"
3740
bit-iter = "1"
3841
rtic-monotonic = "1"
3942
void = { version = "1", default-features = false }
@@ -92,7 +95,7 @@ __device-selected = []
9295

9396
# External feature flags; part of the interface.
9497
can = ["mcan-core"]
95-
unproven = ["embedded-hal/unproven"]
98+
unproven = ["embedded-hal-02/unproven"]
9699
usart-spi-host-without-select = []
97100
reconfigurable-system-pins = []
98101

hal/src/afec.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ let voltage: f32 = afec.read(&mut pin).unwrap();
3333
*/
3434

3535
use crate::clocks::{Clock, HostClock, PeripheralIdentifier};
36-
use crate::ehal::adc;
36+
use crate::legacy_ehal::adc;
3737
use crate::pac::{afec0::RegisterBlock, AFEC0, AFEC1};
3838
use crate::{generics, pio::*};
3939

0 commit comments

Comments
 (0)