I am working with a sensor connected to the USB hub in my arduino board. The sensor uses a serial-to-usb converter (pl2303) and I have some code on the OpenWRT side that is launched at booting. The only thing that this piece of code is doing is to monitor the outputs from the sensor and store the data on a text file in the sd card.
When the Wifi connection is lost and then is back on, I no longer receive data from my sensor. I wonder if any of you have seen a similar problem? Below is my following setup:
-
I installed the latest OpenWRT release (I think is the november 14 built)
-
I disabled wifi-live-or-reset from the booting.
-
I installed the driver for my usb to serial converter and as well I installed kmod-input-core and kmod-input-evdev.
-
I can see my device connected on /dev/ttyUSB0
-
When the wifi is on, my code works with no trouble. Once the wifi is disconnected and back on, I no longer get data from the USB hub. Even when on /dev I can still see TTYUSB0
-
If the wifi is not ON at startup, the USB hub will never get any data.
Any idea about this issue? Thanks in advance!
One possibility;-
Hardware bug, AR9331's usb stability issue.
http://forum.arduino.cc/index.php?topic=193540.msg1532112#msg1532112
Actually, the chip has a hardware bug where spurious RF ( WIFI reset ) emissions affect the USB PLL.
Of course, Qualcomm Atheros will not aknowledge it as a critical bug as they found a software workaround for it. The new revision chipset fixed this problem?
The newer version of Yun firmware has Qualcomm software workaround included. Please upgrade (re-upgrade)!!!
Please upgrade your Yún - latest is 1.5.3
http://forum.arduino.cc/index.php?topic=279008.0
My Yun's version:
uname -a
Linux Arduino 3.3.8 #1 Fri Nov 14 08:57:34 CET 2014 mips GNU/Linux
Thanks a lot Sonnyu. I'll try some of the workarounds and will post an update soon
Well, I re-installed everything again and still the same issue. Would it help if I remove Hotplug2 and install udev?
If I were you, I will start to disable wireless and connect ethernet cable for testing.
nano /etc/config/wireless
config wifi-device 'radio0'
...
list ht_capab 'DSSS_CCK-40'
option disabled '1'
If problem despair then start with an other Yun (AR9331 at first one might be deep fried).
victoratreides:
::::SNIP::::
Any idea about this issue? Thanks in advance!
@victoratreides,
are you using a sketch to move this data around?
Jesse
Hi Jesse.
I have several things running on my yun. While there is some communication between the two micros using bridge, the small program (coded in c) that manages the data acquisition from my USB sensor does not communicate with the 32u4 micro.
The data retrieved from the USB sensor is stored in a file. Then I have a python script that implements a UDP server that transmits the data from said USB sensor and other devices connected to the 32u4.
At the moment I disabled all the other pieces of software and I am focused on the USB sensor only. But still the USB hub keeps "dying".
Since Yun has hardware bug- USB only has only ~4.5v. Use powered USB hub please.
@victoratreides,
at this point, I think SonnyYu's suggestion sounds the best. I was thinking that when you lost the wifi, the sketch broke, but not enough power on the USB hub is a common problem.
Jesse
Hi Jesse, Sonnyyu.
I will try the powered usb hub solution later today and I will let you know what happened. I have to buy one first.
Thanks again for the suggestions!
Sorry for the very delayed reply guys. It's been a couple of crazy days here in the lab.
INDEED, CONNECTING A POWERED USB HUB SOLVES THE ISSUE.
Once again, thanks a lot for the support