Reputation: 47
How can I get Wifi Signal Strength Level On android phone with linux? My Android phone is plug in via usb to linux. I use adb module to communicate with my phone "adb shell". I access in android shell and I search the file or the directory in the android phone shell with the Wifi Signal Strength Level. I would like use a linux command from python via popen module.
Upvotes: 3
Views: 3396
Reputation: 1313
Android will give you the WiFi signal strength as an RSSI value. This will be a number between -100 and 0 dBm, where 0 is the strongest and -100 is the weakest signal.
A quick and easy method to find the RSSI via adb shell is to use dumpsys
For example:
adb shell "dumpsys | grep RSSI:"
There are some related questions getting-wifi-signal-strength-in-android and how-to-get-the-connection-strength-of-wifi-access-points that are worth reading if you would like to write a more directed tool for the job.
WifiManager.startScan() and WifiManager.getScanResults() are the api calls you would use for that.
Upvotes: 2