Based on the wifi-capacity script, with some code specific to ap-auto. Signed-off-by: Ben Greear <greearb@candelatech.com>