This shows you the differences between two versions of the page.
Both sides previous revision Previous revision | |||
startup-sh [2015/04/28 15:05] zoza removed |
— (current) | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | <code bash> | ||
- | #!/bin/sh | ||
- | /etc/init.d/networking stop | ||
- | |||
- | # start airodump, write to a file | ||
- | echo starting airmon-ng | ||
- | sudo airmon-ng start wlan2 | ||
- | echo scanning the Hotspot Linz network | ||
- | # it would be better to scan for a specific --bssid value, but since this can change within a network, scanning for the channel and encryption type should also focus on the same network | ||
- | xterm -e sudo airodump-ng --channel 13 --encrypt OPN -o csv -w $HOME/rknfg/hotspot mon0 & | ||
- | |||
- | sleep 10 | ||
- | # to give airodump enough time to actually gather some data | ||
- | |||
- | echo Starting python | ||
- | |||
- | # start the python script which reads the dump and controls the motors | ||
- | python $HOME/rknfg/motor-scanner.py | ||
- | |||
- | # if error in python | ||
- | |||
- | # close airodump | ||
- | sudo airmon-ng stop wlan2 | ||
- | sudo airmon-ng stop mon0 | ||
- | |||
- | exit | ||
- | </code> |