. ${rc_functions}
CHANNEL="05"
+COUNTRY="00"
TXPOWER="auto"
INTERFACE="blue0"
MACMODE="0"
fi
fi
- /usr/sbin/iwconfig $INTERFACE channel $CHANNEL
+ # First set to any country then reset to World (00)
+ # and then set new country because the card is only
+ # reprogrammed if the region was changed.
+ /usr/sbin/iw reg set DE
+ /usr/sbin/iw reg set 00
+ /usr/sbin/iw reg set $COUNTRY
+
+ /usr/sbin/iwconfig $INTERFACE channel $CHANNEL 2>/dev/null
/usr/sbin/iwconfig $INTERFACE txpower $TXPOWER
/usr/bin/hostapd -P /var/run/hostapd /etc/hostapd.conf >/dev/null 2>&1 &