The code for expled
used in the help desk article is here https://github.com/OnionIoT/fast-gpio/blob/master/scripts/expled.sh in case someone is looking.
Posts made by faulty lee
-
RE: RGB LED on Expansion Dock
-
RE: Setting up Onion with network that needs an Account
I think using commandline browser like
elinks
orlynx
might be possible to authenticate manually, though I can't seems to find the package on Omega or in the openwrt list. -
RE: Wifi - WPA2-EAP (PEAP;MSCHAPv2)
At last, got it working after reading http://superuser.com/questions/756438/openwrt-wpa2-enterprise-radius-config-is-not-applied and https://wiki.openwrt.org/doc/howto/wireless.utilities#hostapd-mini_and_wpad-mini
Basically we need to replace wpad-mini with wpad which have support for 802.1x and EAP. In order to do that, we must first have access to internet via another non EAP wifi AP. Then do this
opkg update opkg remove wpad-mini opkg install wpad
Tested with the above configuration and it works, though sacrificing another 0.3MB of space. I'll give it a try to add this into
wifisetup.sh
-
RE: Wifi - WPA2-EAP (PEAP;MSCHAPv2)
I tried configured it manually by calling
uci set wireless.@wifi-iface[1].ssid
etc... following what's insidewifisetup.sh
and referring to https://wiki.openwrt.org/doc/uci/wireless#wpa_enterprise_client it just won't even attempt to connect. After executingwifi
, I'm only getting.IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready IPv6: ADDRCONF(NETDEV_UP): wlan0-1: link is not ready
It only works if I'm connecting to psk/psk2 SSID.
IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready IPv6: ADDRCONF(NETDEV_UP): wlan0-1: link is not ready wlan0-1: authenticate with xx:xx:xx:xx:xx:xx wlan0-1: send auth to xx:xx:xx:xx:xx:xx (try 1/3) wlan0-1: authenticated
If I set the encryption to
psk2
for an WPA2-EAP SSID, it won't even try to connect, or at least that's what I get from the console.Below is the output from my
cat /etc/config/wireless
config wifi-device 'radio0' option type 'mac80211' option hwmode '11g' option path 'platform/ar933x_wmac' option htmode 'HT20' option disabled '0' option channel '9' option txpower '30' option country 'US' config wifi-iface option device 'radio0' option encryption 'none' option ssid 'Omega-1678' option network 'wlan' option mode 'sta' config wifi-iface option device 'radio0' option mode 'sta' option auth 'auth=MSCHAPV2' option network 'wwan' option password 'xxxxxxxx' option eap_type 'peap' option identity 'xxxxxx\xxxxxxxxxxx' option encryption 'wpa+tkip' option ssid 'xxxxxxxx'
Executing
ubus call iwinfo scan '{"device":"wlan0"}'
gets me{ "ssid": "XXXXXXX", "bssid": "xx:xx:xx:xx:xx:xx", "mode": "Master", "channel": 8, "signal": -76, "quality": 34, "quality_max": 70, "encryption": { "enabled": true, "wpa": [ 1, 2 ], "authentication": [ "802.1x" ], "ciphers": [ "tkip", "ccmp" ] } },
-
RE: RGB LED on Expansion Dock
Lol, I was searching for RGB LED, no wonder I didn't find anything here and at the help desk. That's what I've been thinking, you guys wouldn't have missed such a simple thing.
-
RE: Arch Linux
I'm on Arch as well, it works out of box. I'm guessing it's because I've got Arduino installed.
Regarding the error you posted, might be good to post it in Arch's forum as well.
-
RGB LED on Expansion Dock
I was looking around for information on the GPIO connected to the RGB LED on the expansion dock, didn't find any, so I tried to traced back using a multimeter. Below is the connection, please correct me if I'm wrong, otherwise at least this should help the next guy looking for it.
1kOhm current limiting resistors are connected to each pin
LED R - GPIO17 LED G - GPIO16 LED B - GPIO15
Set GPIO to 0 to turn on and 1 to turn off. I'm guessing the invert is because most GPIO have better sinking capability than sourcing. I would have expect a slightly different resistor value, especially for Red as each color have different luminosity and to achieve a better "white" when all are turned on.
Below is some code to get started
#Setup export and GPIO direction echo 17 > /sys/class/gpio/gpiochip0/subsystem/export echo 16 > /sys/class/gpio/gpiochip0/subsystem/export echo 15 > /sys/class/gpio/gpiochip0/subsystem/export echo out > /sys/class/gpio/gpio17/direction echo out > /sys/class/gpio/gpio16/direction echo out > /sys/class/gpio/gpio15/direction #turn off RGB LED echo 1 > /sys/class/gpio/gpio17/value echo 1 > /sys/class/gpio/gpio16/value echo 1 > /sys/class/gpio/gpio15/value #turn on R echo 0 > /sys/class/gpio/gpio17/value #turn on G echo 0 > /sys/class/gpio/gpio16/value #turn on B echo 0 > /sys/class/gpio/gpio15/value