BBB File /usr/local/sbin/wifiModeAP

From Wiki
Jump to: navigation, search

When executed, this script will reconfigure the WiFi to be an access point

#!/bin/sh

ifdown wlan0 2>&1 >/dev/null
cp /etc/network/interfaces.ap /etc/network/interfaces
ifup wlan0 2>&1 >/dev/null
/etc/init.d/udhcpd start 2>&1 >/dev/null
/etc/init.d/hostapd start 2>&1 >/dev/null
/usr/local/sbin/settables 2>&1 >/dev/null