Simplify now that I have it working

still need to figure out the bound method business
This commit is contained in:
Ryan T. Hamilton 2020-09-19 21:04:07 -07:00
parent 04ffd0dca0
commit bc8863a3c7

View File

@ -151,6 +151,7 @@ mp_obj_t common_hal_wifi_radio_get_ap_rssi(wifi_radio_obj_t *self) {
if (!esp_netif_is_netif_up(self->netif)) {
return mp_const_none;
}
// Make sure the interface is in STA mode
wifi_mode_t if_mode;
esp_wifi_get_mode(&if_mode);
@ -161,10 +162,7 @@ mp_obj_t common_hal_wifi_radio_get_ap_rssi(wifi_radio_obj_t *self) {
wifi_ap_record_t ap_info;
esp_wifi_sta_get_ap_info(&ap_info);
mp_obj_t rssi;
rssi = MP_OBJ_NEW_SMALL_INT(ap_info.rssi);
return rssi;
return MP_OBJ_NEW_SMALL_INT(ap_info.rssi);
}
mp_obj_t common_hal_wifi_radio_get_ipv4_gateway(wifi_radio_obj_t *self) {