I tried to replicate your issue but I didn’t get any Wi-Fi problem. I tested it with a USB Flash Drive. I ran a ping command and then connected the USB Flash Drive. The Edison recognized it but the ping command didn't show any change in its output. The ping delay was always the same.
Then I tried to scan the Wi-Fi networks and I was able to connect the Edison to the network again. I did it with the USB Flash Drive connected.
I tested it with the version 159 and with the previous one which is the 146. Both versions didn't have any issues. I recommend you to re-flash your Edison and check if the issue is still happening.
- The 159 version can be downloaded from here: http://downloadmirror.intel.com/25028/eng/edison-image-ww25.5-15.zip
- The 146 version can be downloaded from here: Intel® Download Center
Thanks very much for taking the time to test it for me - you have it working as I would expect. I am having lots of difficulties.
* I Re-Flashed the Edison as you suggest - the only thing I have changed now from default is the WiFi setup.
* I added an antennae from a Galileo in case it was signal issue.
* I have two usb cables and 12V 5A external power
My hope was to have an Arduino sketch - calling a python script which would do some network calls and do some audio.
My problems: I have my Python code almost complete - however I cannot get both Audio and Wifi to work - only one of the other - also, Is it
not possible to use USB0 and Arduino at the same time?
So I have two questions
Q1) Is there anything else I need to do to stop wifi from stopping when one of the two center usbs are in use? Better USB0 disable? Routing?
Q2) Is it possible to access a USB sound card and have arduino running?
Currently - Switching SW1 to Host mode (so I can access audio) - causes the Arduino code to stop running - no blinking leds (is this normal ?)
Big plans for this board - but its not working as I expected it to so far.
(steps to reproduce- same as before - just little more detail)
1. With the Switch SW1 set to Host Mode (towards power connector) I can upload a sketch - OK (simple blink loaded)
With a PC attached to the center mini-usb - I can see there is no wifi . Using terminal - I can see that wifi is not
functioning correctly - ping failing to resolve host - I can scan though, but It appears to be a shorter list of AccessPoints.
64 bytes from 126.96.36.199: seq=3 ttl=51 time=36.945 ms (switch pointing to empty USB0)
64 bytes from 188.8.131.52: seq=4 ttl=51 time=26.012 ms
64 bytes from 184.108.40.206: seq=16 ttl=51 time=13818.058 ms (As soon as one of the center USB is used)
64 bytes from 220.127.116.11: seq=14 ttl=51 time=15842.396 ms
64 bytes from 18.104.22.168: seq=18 ttl=51 time=12039.725 ms
2. With SW1 set to HOST mode and, using terminal - I can now ping google.com
After a few seconds - internet is back.
But now I have No Arduino and as soon as I plug in USB or Headphones - alll wifi stops again
wlan0 IEEE 802.11abgn ESSID:"Ax******"
Mode:Managed Frequency:2.412 GHz Access Point: E8:40:**:**:**:**
Bit Rate=5.5 Mb/s Tx-Power=31 dBm
Retry long limit:7 RTS thr:off Fragment thr:off
Link Quality=51/70 Signal level=-59 dBm
Rx invalid nwid:0 Rx invalid crypt:0 Rx invalid frag:0
Tx excessive retries:650 Invalid misc:1 Missed beacon:0
sit0 no wireless extensions.
lo no wireless extensions.
usb0 no wireless extensions.
You can use the USB Host port while an Arduino sketch is running. It shouldn't stop when you switch to the USB Host port. Did you have any Arduino sketch or Python script or any other program running during the test? I ran the test with no other scripts running, so it might be possible that the issue is caused by the script.
Try testing only the Wi-Fi connection by plugging the USB Flash Drive. Make sure there aren't sketches or scripts running. Just to check if the Wi-Fi issue is still happening.
>You can use the USB Host port while an Arduino sketch is running. It shouldn't stop when you switch to the USB Host port.
Just started the board there - recently defaulted - no jumpers changed - nothing running
- uploaded "Blink without Delay" Arduino sample with switch in device mode.
When I switch the SW1 to HOST - the led stops blinking.
When I switch it back - the Arduino sketch does not resume - I have to upload it again.
Also - when I reset the Arduino sketch does not run automatically - I need re-upload it after each power up.
The issue you are reporting is a known issue with the latest image. When the Arduino sketch is reset, it doesn't start again. There are two options that you can try:
- Another user posted a workaround for the Arduino sketch issue: Run Arduino sketch on boot Workaround. The steps are explained in that thread. Basically you have to copy some files from the previous image to the latest one.
- The other option is simply re-flashing the Edison with the previous image version since it doesn't have those issues.
The issue is related to the Arduino side, but it might be causing the Wi-Fi issue as well. Please try one of the suggestions above. I haven't tested copying the files needed from the previous image so I would suggest you the second option, re-flashing the Edison with the previous image which is available here: Intel® Download Center
Ok - so reflashed with the previous version (thanks for the link)
configure_edison --version gives 146
And the Arduino does indeed keep running
However it does not help the WIFI
* If the SW1 is pointing to the MiniUSB and this MiniUSB is connected to the PC - then no WIFI
* or if the SW1 is pointing to the HOST USB and this USB has something inserted - then no WIFI.
With the SW1 pointing to an un-populated USB socket - it works ?
----so I've gone and borrowed a friends Edison - who hasn't used it yet. So brand new out of the box...
And Exactly the same behavior. (his version is a much deeper blue circuit board colour - so not the same batch)
configure_edison --version gives no result - so must be quite old.
Powered it up - two micro USB cables and one Intel supplied 12V switch mode psu (2A)
Uploaded Blink without delay - and this indeed works with SW1 set to either direction.
root@edison:~# configure_edison --wifi - failed to complete - just froze.
So I set SW1 to HOST
Configure Edison: WiFi Connection
Scanning: 1 seconds left
0 : Rescan for networks
1 : Manually input a hidden SSID
2 : Horizon Wi-Free
3 : UP*****
4 : Ax****
Initiating connection to AX...
Done. Network access should be available shortly, please check 'wpa_cli status'.
Connected. Please go to 192.168.1.40 in your browser to check if this is correct.
root@edison:~# ifconfig usb0 down
root@edison:~# ping google.com
PING google.com (22.214.171.124): 56 data bytes
64 bytes from 126.96.36.199: seq=0 ttl=57 time=11.682 ms
64 bytes from 188.8.131.52: seq=1 ttl=57 time=26.664 ms
64 bytes from 184.108.40.206: seq=2 ttl=57 time=34.500 ms
64 bytes from 220.127.116.11: seq=3 ttl=57 time=34.797 ms
64 bytes from 18.104.22.168: seq=4 ttl=57 time=28.947 ms
64 bytes from 22.214.171.124: seq=5 ttl=57 time=43.630 ms (at this point I plugged in my USB Audio Device - also tried setting the SW1 to DEVICE for same result)
ping: sendto: Network is unreachable (and it just pauses ping - no more wifi - Arduino sketch is still blinking)
root@edison:~# ping google.com
ping: bad address 'google.com' (no wifi at all)
On this new board - I tried various USB devices - one cheap usb flash drive didnt completely kill it immediately but caused pings to go from 20ms to 250ms for a short while - but all devices eventually killed the wifi within 15 seconds.
is there anything else i can try? I have tried two boards and three versions of the firmware? Is there any test I can run that might help find the issue.
Thanks very much for any help.
Could you explain how the Wi-Fi is being setup and what type of network protection and specs (WPA/WPA2, WEP, etc.) does the network have?
The ping command is not the best way to test network speed. I recommend you to follow the following guide to test the network: Intel® Edison Boards — Measure Wi-Fi Bandwidth. Please post the results before and after plugging in the USB Flash Drive.
Wish I could give you more information - but over the weekend - I have re-flashed the devices(yet again) and rebooted the routers - and now after hours of trying... its suddenly working....
The only thing that is really different - is
1. I rebooted the WiFi routers - no other devices were having issues, but did it anyway.
2. And this time I flashed via the dos command line tool provided in the flash download (flashall.bat) - and Not through the Intel Windows Phone Flash tool I was using last time.
Nothing else has changed - the router is still the same and in same place.
I can now plug in a USB device (tried USB sound card and a Headset) and the ping does not alter at all and data transfer commands like wsget work at expected fast speed.
1. might be of interest - but Doing the Command Line flash I did Not get any Warning Messages displayed - however when Flashing via the Phone flash tool, I was getting some timeout warnings in orange.)
2. Router is WPA2 - one ISP provided router and one in bridge mode to increase wifi coverage.
3. I have tried 146 and one the latest 159 software - both ok.
4. When I was having issued - attaching the USB I was noticing about a 15% loss in WiFi signal strength reported.
5. Switching SW1 from Device to Python mode does end the Arduino code in fw 159 - the \opt\ workaround worked sometimes but not always, so I'm probably going to have to stick with older fw146 for now until there is an official fix.
Sorry I cannot reproduce the problem anymore - but thanks for all the suggestions.