I noticed that if I attach to a port, which stops scanning temporarily as expected, and then connect via a different session and issue "radio n scanstart", scanning begins even though there is still a port attached. Shouldn't the scanstart command either be denied or just wait until a disconnect if there is either a port attached or a conversation in progress that started with an incoming connection?
The context is I have a script that can send beacons during scanning by issuing scanstop, setting the intended frequency, and pushing the test button in the web interface for the intended port. The problem scenario is when a conversation is in progress because the scanstart and scanstop commands still work in that case. If scanstart is issued at the end of the script in order to undo the scanstop that was issued first, scanning starts immediately and can disrupt an existing connection.