Wifi
latests experience first:
Warning:
the WiFi Dongle WRL-11713
is cheap, so dont expect good results
my router with wifi is located in the staircase,
in the next room to it, 5meters away,
i have full connectivity with my laptop containing chipset Intel® PRO/Wireless 3945ABG – Intel 802.11 a/b/g,
one room further, i am working with pcduino..
the laptop still gets good connectivity,
but the pcDuino with WRL-11713 gets no constant connectivity …
sometimes it sees the SSID from the router and sometimes not.. the signal strength isnt contant good..
so i used my Wifi Repeater next to the pcDuino/WRL-11713..
then i got good results..
what does this say?
now, knowing this..
the tools, that are coming with pcDuino are enough to set up WPA2 connection,
wont need a console to set anything.
deprecated stuff:
– adding Wifi-dongle from netgear
and try to use it
https://learn.sparkfun.com/tutorials/getting-started-with-pcduino/wireless-networking
then
console: >lsusb i see my usb-wifi dongle..
but it does not work… seen a driver for this chip,
will be extra work to do
http://wireless.kernel.org/en/users/Devices/USB
so i decided to buy the original suited usb-wifi stick from exp-tech..
so i believed to have not to struggle with drivers
http://www.exp-tech.de/Shields/Wireless/WiFi/pcDuino-WiFi-Dongle.html
pcDuino – WiFi Dongle WRL-11713
> lsusb
Ralink Technology, Corp. RT5370 Wireless Adapter
but it works NOT as easy it should be.. some work to do
install programm „wifi-radar“ via SystemTools > Synaptic Package Manager
and start it from console
> sudo wifi-radar
two windows appear,
in first one, settings window pushing save button,
then we are in second window „WiFi Radar“… seeing visibile? wifi networks
DHCP problem ??? router not visible but the repeater is..hmmm
connecting to router gives output with information about dhcp problem
find MAC address of my router,
using windows7 laptop in same home network:
> arp -a shows all connected network devices with ip and mac address,
#
###
#
http://microcontrollershop.com/product_info.php?products_id=5563
http://pub.ucpros.com/download/wifi_pcduino_spec.pdf
- Ralink RT5370 chip
- Supports 802.11n, 802.11g and 802.11b
- 802.11n: Dynamic data rate up to 150 Mbps — Legacy, Mixed and Green Field modes
- 802.11g: 6/9/12/24/36/48/54 Mbps (auto-sensing)
- 802.11b: 1/2/5.5/11 Mbps (auto-sensing)
- Supports 20 MHz / 40 MHz bandwidth
- Security: 64/138-bit WEP, WPA/WPA2, WPA-PSK/WPA2-PSK (TKIP-AES)
- Reverse direction grant data flow and frame aggregation
- Cisco CCX support
- USB2.0
- Operating Frequency: 2.412 GHz to 2.484 GHz
- Transmit Output Power (802.11g): 15 dBm ±1 dBm
- Receive Sensitivity for 802.11b: -78 dBm @ 11 Mbps (typical)
- Receive Sensitivity for 802.11g: -68 dBm @ 54 Mbps (typical)
- Antenna Port Impedance: 50 Ω
- Operating Voltage: 3.3V
- Current Draw: 200 mA at peak use
#
###
#
http://www.pcduino.com/?page_id=14 listed wifi patch
http://www.pcduino.com/wiki/index.php?title=Release_Note:04042013WiFi_Patch
rt5370sta.ko
/lib/modules/3.4.29+/kernel/drivers/net/wireless/rtxx7x/rt5370sta.ko
others have „same“? problems too
http://pcduino.com/forum/index.php?topic=4095.0
#
###
#
> sudo dmesg
gives interessting things
> init: isc-dhcp-server main process ended, respwaning
> init: isc-dhcp-server main process (631) termineated with status 1
> init: isc-dhcp-server respawning too fast, stopped
DHCP problem ?
use SystemTools > Synaptic Package Manager
to install missing „lshw“, „lshw-gtk“
> sudo lshw -C network
> sudo lsmod
gives list of loaded modules and i find
> rt5370sta
> sudo modinfo rt5370sta
gives info about the driver, driver location,
shows description „RT2870 Wireless Lan Linux Driver“
> sudo modinfo rt5370sta | grep 5370
> filename: /lib/modules/3.4.29+/kernel/drivers/net/wireless/rtxx7x/rt5370sta.ko
> alias: usb:v148Fp5370d*dc*dsc*dp*ic*isc*ip*
unplug the Wifi-dongle, wait and plug in again, then check dmesg again
> sudo dmesg
very nice but
> /hom/ubuntu/sunxi-bsp/linux-sunxi/drivers/net/wireless/rtxx7x/common/cmm_asic.c:3004 assert KeyIdx < 4 failed
what does this mean?
next:
DHCP problem www.google.de/search?q=linux+dhcp+wifi+to+fast
WPA_supplicant http://wiki.ubuntuusers.de/WLAN/wpa_supplicant
SystemTools > Synaptic Package Manager > search for „wpagui“ NOT for „wpa_gui“ !
„wpasupplicant“ not „wpa_supplicant“
installing the wpagui finsihed with errors
starting via
> wpa_gui
> wpa_gui: error while loading shared libraries: libQtGui.so.4: cannot open shared object file: No such file or directory
next try going on without graphical wpa_supplicant tool
> sudo find / -name „*wpa_suppl*“
> /etc/dbus-1/system.d/wpa_supplicant.conf
> /etc/wpa_supplicant
and more
> sudo iwlist scanning << shows wifi networks
http://pcduino.com/forum/index.php?topic=4222.0
http://unix.stackexchange.com/questions/58461/isc-dhcp-server-fails-to-start-at-boot
http://lehwalder.wordpress.com/2013/04/02/wlan-usb-stick-fuer-den-pcduino-rt5370-chipset/
#
###
#
lets try the original ubuntu docu
http://wiki.ubuntuusers.de/WLAN/wpa_supplicant
> sudo -s
> cd /var/run/wpa_supplicant/
> ls
wlan0
> rm -f wlan0 <<– this was very important, after that my tests succeeded !
> ls
now the wlan is gone
> sudo leafpad
File -> Open -> /etc/wpa_supplicant/wpa_supplicant.conf
create that file, if it not exists yet, and set the right permission before you add your data, credentials
> sudo chmod 0600 /etc/wpa_supplicant/wpa_supplicant.conf
content of this wpa_supplicant.conf
for my WPA2 AES (=CCMP) wifi connection
###
#
ctrl_interface=/var/run/wpa_supplicant
eapol_version=1
ap_scan=1
network={
ssid=“xxxx“
id_str=“xxxx“
scan_ssid=1
proto=RSN
key_mgmt=WPA-PSK
pairwise=CCMP
group=CCMP
psk=“your_password“
}
#
###
now we can test that config with the debug option:
> sudo wpa_supplicant -i wlan0 -D wext -c /etc/wpa_supplicant/wpa_supplicant.conf -d
now it can be that your old, previous /var/run/wpa_supplicant/wlan0 is stopping you and a message is given
Delete ‚/var/run/wpa_supplicant/wlan0‘ manually if it is not used anymore
> ls /var/run/wpa_supplicant
ls: cannot open directory /var/run/wpa_supplicant: Permission denied
> sudo ls /var/run/wpa_supplicant
wlan0
> rm -f /var/run/wpa_supplicant/wlan0
… Permission denied
> sudo rm -f /var/run/wpa_supplicant/wlan0
> sudo ls /var/run/wpa_supplicant
SUCCESS
if your interface folder wpa_supplicant in folder /var/run disappears create it new
> cd /
> cd /var/run
> mkdir wpa_supplicant
and then do tests again like:
> sudo wpa_supplicant -i wlan0 -D wext -c /etc/wpa_supplicant/wpa_supplicant.conf -d
now
> cd /
> cd /etc/network
> sudo leafpad interfaces
and add the primary network interface part
# The loopback network interface auto lo iface lo inet loopback # The primary network interface auto wlan0 iface wlan0 inet dhcp wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf
after reboot i have wifi connection working,
but its not stable, after requesting some webpages.. connections gets lost
> sudoi ifdown wlan0 << wlan0 deactivate
> sudo ifup wlan0 << wlan0 start, takes some time
ssh stop/waiting
ssh start/running, process 1216
and the browser can request webpages again
new problem occurs during boot
> init: ureadahead main process ..
so i commented out the # primary network interface in /etc/network/interfaces