Page 1 of 1

Checking WiFi strength?

Posted: Mon Jul 25, 2022 9:49 pm
by liudr
I wonder if there's a simple way to check the dbm value of wifi reception on MP.

According to the doc, there's a scan() that returns a list of access points. Here is what I got:

(b'my_SSID', b'\xd8\x07\xb6\xd8\xc0/', 5, -34, 3, False)

I wonder if the -34 is the dBm. Can I get the strength of specific AP instead of using scan() or getting currently connected AP's strength? Thanks.

Re: Checking WiFi strength?

Posted: Mon Jul 25, 2022 9:52 pm
by davef

Code: Select all

    try:
        rssi = sta_if.status('rssi')
        print ('RSSI = ' + str(rssi) + 'dBm')
    except:
        print ('signal level too low')

Re: Checking WiFi strength?

Posted: Tue Jul 26, 2022 6:20 am
by liudr
That works! Thank you! If I may ask, where can I find the complete official doc for wlan? Is the following it?

https://docs.micropython.org/en/latest/ ... twork.html

I thought I should look under ESP8266 and/or ESP32 but didn't realize under network library there are these very brief descriptions.

Re: Checking WiFi strength?

Posted: Tue Jul 26, 2022 7:16 am
by davef

Re: Checking WiFi strength?

Posted: Tue Jul 26, 2022 3:03 pm
by liudr
Thanks!