summaryrefslogtreecommitdiff
path: root/examples
diff options
context:
space:
mode:
authorDario Nieuwenhuis <dirbaio@dirbaio.net>2021-10-15 16:22:02 +0200
committerGitHub <noreply@github.com>2021-10-15 16:22:02 +0200
commitb087b61f095a6a383956130a7e95e1d85ae11486 (patch)
treef1b72d7b4938699d0262eb0cd186048350daae55 /examples
parenta6c6b1f7cb54f412c5865f33b51987e5aa8427a6 (diff)
parent0d96ded98486cb5f178b8d635eb29157b1a2a9d5 (diff)
downloadnrf-softdevice-b087b61f095a6a383956130a7e95e1d85ae11486.zip
Merge pull request #83 from albertskog/feature/fix-example
fix panic in example
Diffstat (limited to 'examples')
-rw-r--r--examples/src/bin/ble_l2cap_peripheral.rs4
1 files changed, 2 insertions, 2 deletions
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)));