diff options
author | Dario Nieuwenhuis <dirbaio@dirbaio.net> | 2021-02-03 06:25:30 +0100 |
---|---|---|
committer | Dario Nieuwenhuis <dirbaio@dirbaio.net> | 2021-02-03 06:25:30 +0100 |
commit | 96e625fc3baa4f258e9e9f761845a76751710b0d (patch) | |
tree | 50f25a17c00f23dba5bb67acde88c715e5c322ca /examples/src/bin/ble_bas_central.rs | |
parent | 1c821300e2b39c8cc31b11f0f857df81b1aaa9f2 (diff) | |
download | nrf-softdevice-96e625fc3baa4f258e9e9f761845a76751710b0d.zip |
unify and improve central config structs
Diffstat (limited to 'examples/src/bin/ble_bas_central.rs')
-rw-r--r-- | examples/src/bin/ble_bas_central.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/examples/src/bin/ble_bas_central.rs b/examples/src/bin/ble_bas_central.rs index 13f6fb5..be90a4c 100644 --- a/examples/src/bin/ble_bas_central.rs +++ b/examples/src/bin/ble_bas_central.rs @@ -37,9 +37,9 @@ async fn ble_central_task(sd: &'static Softdevice) { AddressType::RandomStatic, [0x06, 0x6b, 0x71, 0x2c, 0xf5, 0xc0], )]; - - let config = central::Config::default(); - let conn = unwrap!(central::connect(sd, addrs, &config).await); + let mut config = central::ConnectConfig::default(); + config.scan_config.whitelist = Some(addrs); + let conn = unwrap!(central::connect(sd, &config).await); info!("connected"); let client: BatteryServiceClient = unwrap!(gatt_client::discover(&conn).await); |