Do not perform forced scanning if device is busy#207
Conversation
Signed-off-by: Gunjan Gupta <viraniac@gmail.com>
|
Additional information supplied by the author of the PR: PR #207 is for another issue where the volumio websocket service hangs because of forced scan when the driver is busy. This happens when user navigates through the setup wizard and lands into the wifi configuration dialog box. On VIM1S, if driver returns busy status for wifi scan and then a scan is forced on it, the scan call simply hangs there and does not return. With changes included in PR #207, I was able to get through the dialog box. I also stayed on the dialog for couple of minutes to see if the wifi network list is getting refreshed or not, and I was able to see new networks that were created after landing on the wifi configuration dialog box. I believe this should be tested, it may fix an issue we have also seen being reported a number of times. |
On some devices, I am seeing this behavior that websocket service gets stuck when ap-force is used for scanning. When I checked further, I noticed that there were already another call for getWirelessNetworks that was running which caused
iwlist wlan0 scanin the websocket service call to fail. The code then executed ap-force command that got hanged resulting into websocket service to hang as well.Hence adding a check to make sure that device is not busy and resulting cached result if device is busy.