Page 1 of 1

Slow and Troublesome WiFi

Posted: Sat Dec 05, 2015 1:59 pm
by JonnyAlpha
Hi;

I am building and testing a WiFi controlled robot and am having some WiFi problems.

The WiFi dongle is a generic one that came with the Maplins raspberry Pi Kit (No name on the dongle).

Output of iwconfig is here:

Code: Select all

wlan0     IEEE 802.11bgn  ESSID:"BTHub4-HKG2"  
          Mode:Managed  Frequency:2.462 GHz  Access Point: CC:33:BB:F4:D8:FC   
          Bit Rate=6.5 Mb/s   Tx-Power=20 dBm   
          Retry short limit:7   RTS thr:off   Fragment thr:off
          Power Management:off
          Link Quality=29/70  Signal level=-81 dBm  
          Rx invalid nwid:0  Rx invalid crypt:0  Rx invalid frag:0
          Tx excessive retries:0  Invalid misc:2   Missed beacon:0

lo        no wireless extensions.

eth0      no wireless extensions.


The bit rate says 6.5mbs which seems painfully slow.

I am using mjpg-streamer to stream a video feed from a web camera mounted on the robot it started having problems with an update of Raspbian but this was fixed by patching mjpg-streamer but the problems have come back.

When the Pi is connected via Ethernet the stream is fine?

I have tried changing channel to channel 1 from 11 on my BT Home Hub Router initially I was getting about 38mbs but then when I ran mjpg-streamer it dropped to 7mbs again?

Do I need to update the firmware in the dongle?

Re: Slow and Troublesome WiFi

Posted: Sat Dec 05, 2015 2:14 pm
by fruitoftheloom
JonnyAlpha wrote:Hi;

I am building and testing a WiFi controlled robot and am having some WiFi problems.

The WiFi dongle is a generic one that came with the Maplins raspberry Pi Kit (No name on the dongle).

Output of iwconfig is here:

Code: Select all

wlan0     IEEE 802.11bgn  ESSID:"BTHub4-HKG2"  
          Mode:Managed  Frequency:2.462 GHz  Access Point: CC:33:BB:F4:D8:FC   
          Bit Rate=6.5 Mb/s   Tx-Power=20 dBm   
          Retry short limit:7   RTS thr:off   Fragment thr:off
          Power Management:off
          Link Quality=29/70  Signal level=-81 dBm  
          Rx invalid nwid:0  Rx invalid crypt:0  Rx invalid frag:0
          Tx excessive retries:0  Invalid misc:2   Missed beacon:0

lo        no wireless extensions.

eth0      no wireless extensions.


The bit rate says 6.5mbs which seems painfully slow.

I am using mjpg-streamer to stream a video feed from a web camera mounted on the robot it started having problems with an update of Raspbian but this was fixed by patching mjpg-streamer but the problems have come back.

When the Pi is connected via Ethernet the stream is fine?

I have tried changing channel to channel 1 from 11 on my BT Home Hub Router initially I was getting about 38mbs but then when I ran mjpg-streamer it dropped to 7mbs again?

Do I need to update the firmware in the dongle?
Could you post the output of:

Code: Select all

lsusb

Code: Select all

uname -a

Re: Slow and Troublesome WiFi

Posted: Sat Dec 05, 2015 2:19 pm
by JonnyAlpha
Just doing and update and upgrade but will do :-)

Oh and its a Ralink RT5370.

Re: Slow and Troublesome WiFi

Posted: Sat Dec 05, 2015 2:39 pm
by JonnyAlpha
Here is the output of lsusb:

Code: Select all

pi@raspberrypi ~ $ lsusb
Bus 001 Device 002: ID 0424:9512 Standard Microsystems Corp. 
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 003: ID 0424:ec00 Standard Microsystems Corp. 
Bus 001 Device 004: ID 148f:5370 Ralink Technology, Corp. RT5370 Wireless Adapter
Bus 001 Device 005: ID 046d:0825 Logitech, Inc. Webcam C270
and uname -a:

Code: Select all

pi@raspberrypi ~ $ uname -a
Linux raspberrypi 3.18.11+ #781 PREEMPT Tue Apr 21 18:02:18 BST 2015 armv6l GNU/Linux

Re: Slow and Troublesome WiFi

Posted: Sat Dec 05, 2015 2:54 pm
by fruitoftheloom
JonnyAlpha wrote:Here is the output of lsusb:

Code: Select all

pi@raspberrypi ~ $ lsusb
Bus 001 Device 002: ID 0424:9512 Standard Microsystems Corp. 
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 003: ID 0424:ec00 Standard Microsystems Corp. 
Bus 001 Device 004: ID 148f:5370 Ralink Technology, Corp. RT5370 Wireless Adapter
Bus 001 Device 005: ID 046d:0825 Logitech, Inc. Webcam C270
and uname -a:

Code: Select all

pi@raspberrypi ~ $ uname -a
Linux raspberrypi 3.18.11+ #781 PREEMPT Tue Apr 21 18:02:18 BST 2015 armv6l GNU/Linux
The RT5370 has always been supported under Raspbian and this blog includes speed comparisions between WiFi and Ethernet

http://www.midwesternmac.com/blogs/jeff ... networking

Re: Slow and Troublesome WiFi

Posted: Sat Dec 05, 2015 3:03 pm
by JonnyAlpha
fruitoftheloom wrote:
JonnyAlpha wrote:Here is the output of lsusb:

Code: Select all

pi@raspberrypi ~ $ lsusb
Bus 001 Device 002: ID 0424:9512 Standard Microsystems Corp. 
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 003: ID 0424:ec00 Standard Microsystems Corp. 
Bus 001 Device 004: ID 148f:5370 Ralink Technology, Corp. RT5370 Wireless Adapter
Bus 001 Device 005: ID 046d:0825 Logitech, Inc. Webcam C270
and uname -a:

Code: Select all

pi@raspberrypi ~ $ uname -a
Linux raspberrypi 3.18.11+ #781 PREEMPT Tue Apr 21 18:02:18 BST 2015 armv6l GNU/Linux
The RT5370 has always been supported under Raspbian and this blog includes speed comparisions between WiFi and Ethernet

http://www.midwesternmac.com/blogs/jeff ... networking
Thanks for the link but not sure how this helps me? I am using WiFi on a mobile platform so USB to Ethernet is not possible?

Re: Slow and Troublesome WiFi

Posted: Sat Dec 05, 2015 3:10 pm
by gregeric
-81dBm ain't lighting up too many bars on the signal strength meter. Maybe worth trying a short USB extension cable to bring the dongle out into fresh air if it's buried in lots of metal on the robot.

Re: Slow and Troublesome WiFi

Posted: Sat Dec 05, 2015 3:37 pm
by JonnyAlpha
gregeric wrote:-81dBm ain't lighting up too many bars on the signal strength meter. Maybe worth trying a short USB extension cable to bring the dongle out into fresh air if it's buried in lots of metal on the robot.
Mmm - funny that was my thinking too (although I could not remember whether -81dBm was any good :-)

I ran a USB extension lead and had a little higher but just now I tried out my Mobile Phone Portable Hotspot which I use when its out and about and I get a nice 65Mb/s compared to 24Mb/s using my Home WiFi and USB Extension :-)

Maybe try another channel?

Re: Slow and Troublesome WiFi

Posted: Sat Dec 05, 2015 3:39 pm
by gregeric
Nice :D

Yeah worth a shot if it's crowded on the existing.