Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions esp-radio/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Added

- `AccessPointInfo::country` to access the Country Code from the Wi-Fi scan results (#3837)
- Added `reinit` method to `BleConnector` to properly reset the BLE modem (#3877)


### Changed
Expand Down
6 changes: 6 additions & 0 deletions esp-radio/src/ble/controller/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,12 @@ impl<'d> BleConnector<'d> {
Self { _device: device }
}

pub fn reinit(&mut self) {
// Reinitialize the BLE controller
crate::ble::ble_deinit();
crate::ble::ble_init();
}

pub fn next(&mut self, buf: &mut [u8]) -> Result<usize, BleConnectorError> {
Ok(read_next(buf))
}
Expand Down
Loading