Skip to content

Commit 975f7fb

Browse files
committed
refactor(examples): remove the direct dependency on atsamd-hal
It's re-exported by `wio_terminal`.
1 parent b2cc9bb commit 975f7fb

File tree

3 files changed

+5
-7
lines changed

3 files changed

+5
-7
lines changed

Cargo.lock

Lines changed: 0 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

examples/basic_wio_terminal/Cargo.toml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@ wio_terminal = { version = "0.4" }
1818
cortex-m-rt = { version = "0.6.12" }
1919
usbd-serial = { version = "0.1" }
2020
usb-device = { version = "0.2.7" }
21-
atsamd-hal = { version = "0.13", features = ["samd51p"] }
2221
arrayvec = { version = "0.7.1", default-features = false }
2322
cortex-m = { version = "*" }
2423
cryo = { version = "0.3.1", default-features = false, features = ["atomic"] }

examples/basic_wio_terminal/src/main.rs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ use usb_device::{
3535
};
3636
use usbd_serial::{SerialPort, USB_CLASS_CDC};
3737
use wio::{
38-
hal::{clock::GenericClockController, gpio, usb::UsbBus},
38+
hal::{self, clock::GenericClockController, gpio, usb::UsbBus},
3939
pac::{CorePeripherals, Peripherals},
4040
prelude::*,
4141
Pins, Sets,
@@ -262,10 +262,10 @@ fn init_hardware(
262262

263263
type HardwareLateInitInput = (
264264
GenericClockController,
265-
atsamd_hal::pac::MCLK,
265+
hal::pac::MCLK,
266266
Option<wio_terminal::Display>,
267-
atsamd_hal::gpio::Port,
268-
Option<atsamd_hal::pac::SERCOM7>,
267+
hal::gpio::Port,
268+
Option<hal::pac::SERCOM7>,
269269
);
270270

271271
fn init_hardware_late_task_body(
@@ -287,7 +287,7 @@ fn init_hardware_late_task_body(
287287
/// Implements `DelayMs` using `System::sleep`.
288288
struct DelayByKernel;
289289

290-
impl atsamd_hal::hal::blocking::delay::DelayMs<u16> for DelayByKernel {
290+
impl hal::hal::blocking::delay::DelayMs<u16> for DelayByKernel {
291291
#[inline]
292292
fn delay_ms(&mut self, ms: u16) {
293293
System::sleep(r3::time::Duration::from_millis(ms as i32)).unwrap();

0 commit comments

Comments
 (0)