Well, I didnâ€™t receive any help but I did get it working. Un-said in my first post, I wanted to do this in a script. I wanted to keep my regular configs when the router was at home and script the â€œrouted client modeï¿½ when at the cottage. My failing was not dropping the firewall and restarting it.
I think this method is simpler then what ctl or duon is using if your trying to setup â€œrouted client modeï¿½ within a script. The reason, no switch changes are necessary, the lan side stays static and if connected via ssh, you can run the script without being disconnected or the necessity of rebooting.
So, here goes;
if test $# -eq 0
then echo ""
echo "Select Wireless Network to Join"
echo "Option: Enter Network ESSID"
uci set wireless.cfg2.ssid=$1
uci set wireless.cfg2.mode=sta
uci set wireless.cfg2.encryption=none
uci set wireless.cfg2.network=wan
uci set network.wan.proto=dhcp
uci set network.wan.type=bridge
This sets up a bridge (br-wan) between eth0.1 & wl0 and sets the IP on the bridge. The script also assumes you have the wireless running as an access point and your connecting to an open access point. You will need more wireless settings if your connecting to an encrypted network. Probably some of these;
option encryption wep, psk, psk2, wpa, wpa2
option key encryption key
option key1 key 1
option key2 key 2
option key3 key 3
option key4 key 4
The basic script, gives the same rip-off features to join a network, as Blue Box.
I hope this helps others.
P.S. - please note, I don't "uci commit" anywhere in the script. That way the changes only exist between reboots and only when the script is run.
(Last edited by nuke12 on 13 May 2008, 00:37)