pub fn set_mode(&mut self, mode: WifiMode) -> Result<(), WifiError> {
        esp_wifi_result!(unsafe { esp_wifi_set_mode(mode.into()) })?;
        Ok(())
    }
Set the WiFi mode.

This will override the mode inferred by [Self::set_configuration].
esp-wifi/src/wifi/mod.rs