From 0d96ded98486cb5f178b8d635eb29157b1a2a9d5 Mon Sep 17 00:00:00 2001 From: Albert Skog Date: Fri, 15 Oct 2021 13:17:40 +0200 Subject: fix panic in example --- examples/src/bin/ble_l2cap_peripheral.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'examples/src/bin/ble_l2cap_peripheral.rs') diff --git a/examples/src/bin/ble_l2cap_peripheral.rs b/examples/src/bin/ble_l2cap_peripheral.rs index e7cff49..ecda5f4 100644 --- a/examples/src/bin/ble_l2cap_peripheral.rs +++ b/examples/src/bin/ble_l2cap_peripheral.rs @@ -145,10 +145,10 @@ fn main() -> ! { ..Default::default() }; - unwrap!(RawError::convert(unsafe { raw::sd_clock_hfclk_request() })); - let sd = Softdevice::enable(&config); + unwrap!(RawError::convert(unsafe { raw::sd_clock_hfclk_request() })); + let executor = EXECUTOR.put(Executor::new()); executor.run(|spawner| { unwrap!(spawner.spawn(softdevice_task(sd))); -- cgit v1.2.3