cyw43: Create leave function on Control struct.

Create a function, which disassociates us, from the currently connected infra.
This commit is contained in:
Frostie314159
2023-08-28 21:34:14 +02:00
parent 05ee02b593
commit e025693914
2 changed files with 6 additions and 0 deletions

View File

@ -433,6 +433,11 @@ impl<'a> Control<'a> {
events: &self.events,
}
}
/// Leave the wifi, with which we are currently associated.
pub async fn leave(&mut self) {
self.ioctl(IoctlType::Set, IOCTL_CMD_DISASSOC, 0, &mut []).await;
info!("Disassociated")
}
}
pub struct Scanner<'a> {