davidjb
Posts: 9
Joined: Tue Jul 22, 2014 12:38 pm

B+ USB 3G dongles OR USB Drive may trip brownout detector

Tue Jul 22, 2014 1:02 pm

I've just purchased myself a model B+ to replace my model B, but am finding my 3G USB dongle trips the current limiter on the B+ model, when it worked fine with the B previously. The power supply is a 1A wall charger.

On my original model B, I have had a K-3571 3G USB dongle attached and the Raspberry Pi has been completely stable, sometimes going for months between being touched or restarted. There have never been any issues with powering this device straight from the Pi with the 1A charger.

However, now that I've tried the B+, plugging the USB dongle in works for a short period, but is disconnected (highlighted in dmesg) after about 10 seconds. The power LED flashes, seemingly indicating the current limiter has been tripped. I'm unsure exactly how much current the USB dongle draws, but obviously enough to affect this. I've also tried allowing the maximum current of 1.2A through the USB via the boot configuration option, but the same thing happens.

I've already put an order in for a higher-current USB power supply as I know 1A isn't enough, but I'm curious to know what the difference is here. Why does the device work with the B and not with the B+? Is the new B+ more sensitive in some way, or have I simply gotten lucky that the original setup worked with the given power draw?

I'm running the latest Raspian and NOOBS, if it makes any difference.

User avatar
mahjongg
Forum Moderator
Forum Moderator
Posts: 13099
Joined: Sun Mar 11, 2012 12:19 am
Location: South Holland, The Netherlands

Re: B vs B+ - USB 3G dongle now trips current limiter

Tue Jul 22, 2014 1:36 pm

The default current limit for the new B+ USB current limiter is 600mA, but can be increased to double that with an entry in config.txt.
It seems your 3G dongle is using in excess of 600mA, that's quite a lot!

I wasn't aware that the new software in the B+ would flash the power LED when the current limiter senses an over-current, but it is quite possible it does! The default is that the LED will be turned off when a brownout detector senses the 5V power dropping below 4.6V, but I knew the PWR LED could both be read out from software, and that the power LED could be taken over in software, so now we now more.

Also I read that in the desktop a rectangle in the top right corner can also indicate a brownout condition, with a rainbow colored square, and over-temperature with a red square. Maybe it will also indicate USB current overloads with yet another color.

davidjb
Posts: 9
Joined: Tue Jul 22, 2014 12:38 pm

Re: B vs B+ - USB 3G dongle now trips current limiter

Tue Jul 22, 2014 1:45 pm

mahjongg wrote:The default current limit for the new B+ USB current limiter is 600mA, but can be increased to double that with an entry in config.txt.
It seems your 3G dongle is using in excess of 600mA, that's quite a lot!
Yep, and I've tried enabling this option in config.txt, without success as of yet with my 1A power supply. It's the same result as when the option isn't present -- the limiter trips and disconnects the USB device. Understandably, the 1A power supply is not overly powerful in this case, but as you say, 600mA+ is a *lot* of current, if it is that much. I'll test it to see what it really is using.

So, this is why I'm confused. The same power supply, USB donle, and configuration (and even same Raspian install!) works just fine on my older model B. No power brownouts, no resetting, etc -- it just works and always has. The power supply isn't hot after days/weeks of usage, either.

davidjb
Posts: 9
Joined: Tue Jul 22, 2014 12:38 pm

Re: B vs B+ - USB 3G dongle now trips current limiter

Tue Jul 22, 2014 1:51 pm

mahjongg wrote: I wasn't aware that the new software in the B+ would flash the power LED when the current limiter senses an over-current, but it is quite possible it does! The default is that the LED will be turned off when a brownout detector senses the 5V power dropping below 4.6V, but I knew the PWR LED could both be read out from software, and that the power LED could be taken over in software, so now we now more.
I'd just gone from this page: https://projects.drogon.net/testing-set ... erry-pi-b/ where it mentioned about the flashing of the power LED.

The whole process is:
  • Pi model B+ is on. Power LED is solid red.
  • Connect USB dongle. Dongle powers up, is detected by Linux.
  • Power LED flashes once, USB dongle stops working
  • USB device is disconnected, according to dmesg.
  • Process repeats several times, according to dmesg.
Unsure why the disconnect/reconnect process happens, but it does. I'll put my power meter against my model B and see what it says with and without the USB dongle.

User avatar
mikronauts
Posts: 2783
Joined: Sat Jan 05, 2013 7:28 pm
Contact: Website

Re: B vs B+ - USB 3G dongle now trips current limiter

Tue Jul 22, 2014 1:52 pm

Try a different, better, 5V supply that can deliver 2A to your B+

I've been using a Samsung 2A charger with my Model B+ and it has been working VERY well - I can now use three power hungry USB WiFi sticks that on a Model B would only work with a powered USB hub - and this is without even enabling the high current option for the B+!

If interested, see http://www.mikronauts.com/raspberry-pi/ ... ifi-tests/
http://Mikronauts.com - home of EZasPi, RoboPi, Pi Rtc Dio and Pi Jumper @Mikronauts on Twitter
Advanced Robotics, I/O expansion and prototyping boards for the Raspberry Pi

User avatar
Burngate
Posts: 6302
Joined: Thu Sep 29, 2011 4:34 pm
Location: Berkshire UK Tralfamadore
Contact: Website

Re: B vs B+ - USB 3G dongle now trips current limiter

Tue Jul 22, 2014 5:13 pm

I don't believe the firmware/software uses the PWR LED to signal anything - I believe it only reads it, to put the square on the desktop.
(Yes, I know it could, I just don't think it does)

So it's probable that the red flashing really means power-brown-out. So get a better supply.

It's possible that the lower impedance of the B+ supply chain is browning out the supply. Oh, look, there's a straw going by - grab it!

zorch
Posts: 23
Joined: Tue Jul 22, 2014 5:56 pm

Re: B vs B+ - USB 3G dongle now trips current limiter

Tue Jul 22, 2014 6:44 pm

[quote="mahjongg"]The default current limit for the new B+ USB current limiter is 600mA, but can be increased to double that with an entry in config.txt.

I am having trouble powering my external USB derive with a B+. Could you publish the entry that can be added to the config.txt to increase the USB power form 600mA to 1.2A?

User avatar
rpdom
Posts: 17173
Joined: Sun May 06, 2012 5:17 am
Location: Chelmsford, Essex, UK

Re: B vs B+ - USB 3G dongle now trips current limiter

Tue Jul 22, 2014 7:24 pm

zorch wrote:
mahjongg wrote:The default current limit for the new B+ USB current limiter is 600mA, but can be increased to double that with an entry in config.txt.
I am having trouble powering my external USB derive with a B+. Could you publish the entry that can be added to the config.txt to increase the USB power form 600mA to 1.2A?
The entry is either "safe_mode_gpio=4" or in newer firmware (not sure is that is out yet) "max_usb_current=1". Use both to be certain :)

User avatar
mahjongg
Forum Moderator
Forum Moderator
Posts: 13099
Joined: Sun Mar 11, 2012 12:19 am
Location: South Holland, The Netherlands

Re: B vs B+ - USB 3G dongle now trips current limiter

Tue Jul 22, 2014 7:43 pm

A small correction, the PWR LED blinking is simply due to the brownout detector detecting multiple repeated undervoltage conditions (<4.6Volt). So the LED blinking is NOT a software controlled effect!

So what is detected is NOT USB overcurrent, but a drop of the 5V below the brownout level.

MrEngman
Posts: 4032
Joined: Fri Feb 03, 2012 2:17 pm
Location: Southampton, UK

Re: B vs B+ - USB 3G dongle now trips current limiter

Tue Jul 22, 2014 8:39 pm

The device detecting low voltage could trip anywhere between a max of 4.70V and a min of 4.56V depending on the device on your B+, but the typical value is specified as 4.63V. These are at an ambient temperature of 25 degrees C. The trip voltage rises but only very very slightly as the temperature increases.


MrEngman
Simplicity is a prerequisite for reliability. Edsger W. Dijkstra

Please post ALL technical questions on the forum. Please Do Not send private messages.

zorch
Posts: 23
Joined: Tue Jul 22, 2014 5:56 pm

Re: B vs B+ - USB 3G dongle now trips current limiter

Tue Jul 22, 2014 9:24 pm

by zorch » Tue Jul 22, 2014 10:44 am
[quote="mahjongg"]The default current limit for the new B+ USB current limiter is 600mA, but can be increased to double that with an entry in config.txt.

I am having trouble powering my external USB derive with a B+. Could you publish the entry that can be added to the config.txt to increase the USB power form 600mA to 1.2A?
Posts: 2
Joined: Tue Jul 22, 2014 9:56 am
Report this postReply with quotePermalink
by rpdom » Tue Jul 22, 2014 11:24 am
zorch wrote:
mahjongg wrote:
The default current limit for the new B+ USB current limiter is 600mA, but can be increased to double that with an entry in config.txt.


I am having trouble powering my external USB derive with a B+. Could you publish the entry that can be added to the config.txt to increase the USB power form 600mA to 1.2A?


The entry is either "safe_mode_gpio=4" or in newer firmware (not sure is that is out yet) "max_usb_current=1". Use both to be certain :)

Unfortunately neither of these lines of code worked however now the USB drive is continually trying to start instead of starting and stopping. I increased the max_usb_current=1.2 but nothing changed. Any other ideas? Thanks in advance!

zorch
Posts: 23
Joined: Tue Jul 22, 2014 5:56 pm

Re: B vs B+ - USB 3G dongle now trips current limiter

Tue Jul 22, 2014 9:26 pm

By the way, I am using a 2A power supply.

User avatar
mikronauts
Posts: 2783
Joined: Sat Jan 05, 2013 7:28 pm
Contact: Website

Re: B vs B+ - USB 3G dongle now trips current limiter

Tue Jul 22, 2014 9:43 pm

All 2A power supplies are not created equal. I suggest testing the voltage coming out of the adapter under your load, and possibly even putting a scope on it to see how clean the power is.

The low voltage indication suggests your supply is not able to supply enough current.
zorch wrote:By the way, I am using a 2A power supply.
http://Mikronauts.com - home of EZasPi, RoboPi, Pi Rtc Dio and Pi Jumper @Mikronauts on Twitter
Advanced Robotics, I/O expansion and prototyping boards for the Raspberry Pi

User avatar
Jim JKla
Posts: 2218
Joined: Sun Jan 29, 2012 11:15 pm
Location: Newcastle upon Tyne UK

Re: B vs B+ - USB 3G dongle now trips current limiter

Tue Jul 22, 2014 10:02 pm

I think we need to consider that we have issues both related to power thruput where the B+ has an issue over the original B particularly with the OP saying the identical setup works with the B and not the B+ so there's obviously some change.

It would be useful if we could find another user in the same situation It is worth considering there may be a faulty component on the OP's new B+ when you consider how new the B+ is in the scheme of things we may have just found it's first undocumented feature. ;)
Noob is not derogatory the noob is just the lower end of the noob--geek spectrum being a noob is just your first step towards being an uber-geek ;)

If you find a solution please post it in the wiki the forum dies too quick

zorch
Posts: 23
Joined: Tue Jul 22, 2014 5:56 pm

Re: B vs B+ - USB 3G dongle now trips current limiter

Tue Jul 22, 2014 11:58 pm

I actually have tried 2 power adapters 1 is a 1.5A and the other is a 2.0 A adapter. I have a Kill A Watt meter that shows both of them only go up to ..08A under load. USB memory sticks up to 64GB work fine and so do HD movies with omxplayer. I have tried 3 different USB HDs that work perfectly on a powered USB hub. Two of them give me a continuous clicking sound as if they are trying to spool up. The third lights up then shuts down. Originally none of the drives would get past the initial startup. As I mentioned earlier when I increased the max_usb_current=1 or 1.2 in config.txt the drives continue trying to startup as if there is almost enough power.

User avatar
Jim JKla
Posts: 2218
Joined: Sun Jan 29, 2012 11:15 pm
Location: Newcastle upon Tyne UK

Re: B vs B+ - USB 3G dongle now trips current limiter

Wed Jul 23, 2014 7:14 am

NP Zorch and it does look like you problem has some commonality with the OP but you are talking about a USB HD

In a perfect world your post should have been in a new thread with it's own heading with a link here.

So as it stands technically this is off topic but I will approach the Mods to see if we can get "& USB Hard drives" added to the thread title
Noob is not derogatory the noob is just the lower end of the noob--geek spectrum being a noob is just your first step towards being an uber-geek ;)

If you find a solution please post it in the wiki the forum dies too quick

User avatar
mahjongg
Forum Moderator
Forum Moderator
Posts: 13099
Joined: Sun Mar 11, 2012 12:19 am
Location: South Holland, The Netherlands

Re: B vs B+ - USB 3G dongle (+USB Drive) trips current limit

Wed Jul 23, 2014 9:42 am

when with a "perfect power supply" there is still a large voltage drop at the receiving end, it invariably means that there is considerable resistance somewhere between the PSU and the HD, the only question is where?

Evil tongues used to claim the problem lies in the polyfuse, but with a 2A polyfuse the resistance is something like 0.02 Ohm, (20 milliohm) and so an 1A current would only cause a 0.02 Volt (20 mV) drop, and we are looking for a drop in the range of 400mV (0.4V).
One might thing that (micro)USB connectors, when dirty might accumulate some resistance, but in practice (with gold plated contacts) such resistances are in the milliohm range. What does happen that there are often USB to microUSB cables sold as "charger cables", made by Chinese manufacturers that try to spare even a fraction of a cent, because when you make a million of them that fraction of a cent matters. They start with removing the expensive stuff, the goldplating of the connectors is reduced to a minimum, and because copper is expensive they reduce the diameter of the wires, to sub human hair diameters, sometimes even using aluminum instead of copper. They can get away with it, because for charging a phone it doesn't matter, a drop of half a volt will only make the charging process a bit slower, and most people wouldn't notice.

but that same half volt drop is fatal for USB device as many of them can only tolerate a 250mV drop, (0.25V) .

One solution is to take both a normal USB cable, and such a charger cable, and cut of the microUSB cable close to the micro USB connector, so only a short part of the bad cable is used, then solder the end to the probably much thicker standard USB cable, but be very careful to connect the wires in the correct way, Fortunately the B+ now has an "ideal diode" that protects against polarity reversals, because without that the PI when powered with -5V instead of +5V would be destroyed instantly! Now when you make a mistake the worst that can happen is that the PI won't get any power!

Obviously better still you could use a real USB to microUSB power cable, instead of a cheap charger cable.
Especially when the cable is long and thin, one should start to wonder if the cable is suitable

P.S. [Moderated] changed subject line to better reflect the actual issue.

zorch
Posts: 23
Joined: Tue Jul 22, 2014 5:56 pm

Re: B vs B+ - USB 3G dongle now trips current limiter

Thu Jul 24, 2014 2:38 pm

Jim JKla wrote:NP Zorch and it does look like you problem has some commonality with the OP but you are talking about a USB HD

In a perfect world your post should have been in a new thread with it's own heading with a link here.

So as it stands technically this is off topic but I will approach the Mods to see if we can get "& USB Hard drives" added to the thread title
Thank you. I will try that avenue. I am learning!

davidjb
Posts: 9
Joined: Tue Jul 22, 2014 12:38 pm

Re: B+ USB 3G dongles OR USB Drive may trip brownout detecto

Sat Sep 06, 2014 1:33 pm

I've just upgraded my power supply to a 2.4A supply (designed for iPad and tablet charging) and the issue still persists. My config.txt consists of both options as mentioned above, and there's no difference with or without these settings.

With my USB 3G dongle, the device is detected and works, but trips the brownout detector around 5 seconds or so after physically connecting it to the B+. This coincides exactly when the USB 3G dongle attempts to automatically connect to the cellular network, so this action must be drawing power in such a way that trips the brownout detector.

As mentioned before, the most confusing thing is that my model Bs work fine with lower current power supplies (<=1A) and have never had a problem. No power issues, even when using 2 of the same USB 3G dongle on an unpowered hub!

Is this potentially a faulty B+ or something else I should be trying?

superman
Posts: 14
Joined: Sun Aug 24, 2014 4:10 pm

Re: B+ USB 3G dongles OR USB Drive may trip brownout detecto

Sat Sep 06, 2014 6:42 pm

Just did a quick but lazy test by plugging my Huawei E160 3G dongle in B+ and keeping an eye on the PWD LED. The red PWD led blinked just once and remained solid afterwards. The dongle also registered to the network successfully. The only thing I didn't check is whether accessing 3G broadband will cause brown-out simply because the feature of 3G broadband hasn't been activated yet. The wee problem you share here does worry me a bit as I am running the Raspbian on the flash drive and will soon add the 3G dongle to turn my B+ into a GSM-VoIP gateway.

By any chance, does your USB 3G dongle have a buit-in SD card reader?

davidjb
Posts: 9
Joined: Tue Jul 22, 2014 12:38 pm

Re: B+ USB 3G dongles OR USB Drive may trip brownout detecto

Sat Sep 06, 2014 10:00 pm

superman wrote:Just did a quick but lazy test by plugging my Huawei E160 3G dongle in B+ and keeping an eye on the PWD LED. The red PWD led blinked just once and remained solid afterwards. The dongle also registered to the network successfully. The only thing I didn't check is whether accessing 3G broadband will cause brown-out simply because the feature of 3G broadband hasn't been activated yet. The wee problem you share here does worry me a bit as I am running the Raspbian on the flash drive and will soon add the 3G dongle to turn my B+ into a GSM-VoIP gateway.

By any chance, does your USB 3G dongle have a buit-in SD card reader?
No SD card reader, just a seemingly plain 3G dongle -- ZTE K3571-Z. The modem attempting to register the GSM network trips the brownout detector.

superman
Posts: 14
Joined: Sun Aug 24, 2014 4:10 pm

Re: B+ USB 3G dongles OR USB Drive may trip brownout detecto

Sun Sep 07, 2014 1:37 am

The reason why I asked the above question is that the Huawei E160 has a SD card slot and a small storage space as a virtual CD to store its Windows driver and communication program. These two features did confuse my Linux box on the PC when the dongle was hot-plugged in. After turning off these features, there is no more problem whether the dongle is plugged in before or after booting. I am not sure if this is the reason why my 3G dongle doesn't cause the PWR LED to blink.

Just did a quick check on the net, and have learnt that the K3571-Z also has a small storage space. I just wonder if this can be the problem. Besides, no offence, do your B and B+ run exactly the same OS?

RSvedman
Posts: 24
Joined: Sun Dec 29, 2013 12:24 pm

Re: B+ USB 3G dongles OR USB Drive may trip brownout detecto

Sun Sep 07, 2014 9:51 pm

I got my B+ earlier this week, and had similar problems: I used to "backpower" my model B from a 2 amp supply driving a cheap 7 port hub + a passive 4 port hub. On the system I have two printers, one usb powered flatbed scanner, KVM switch (with mouse and kbd), DVB-T stick, serial dongle, parallel dongle. Since the B+ can't be backpowered I had to add a usb A to microusb cable to the pi, I used the one that came with my Xperia cellphone. This would work, but blinked the power led and showed the rainbow square in the corner once in a while. I plugged the B+ into its own supply using the same cable (850mA xperia phone charger) and had no more brownouts. I like to think the hub will put full power out the uplink socket (backpower) but try to negotiate the power on the downlink ports. This will of course not work since the PI has no data leads in the power connector, and thus the hub will only give minimal power to the pi..

how would I confirm if this is the case? and how would I work around it? It really sucks needing two power outlets, my desk is using more than 10^H^H17 already... (3 screens, pc, 2 printers, 2 external harddrives, plotter, speakers, 2 powered usb hubs (with a pi model B each), active tv antenna, external DVD writer, battery charger, router, switch, various experiments...)

davidjb
Posts: 9
Joined: Tue Jul 22, 2014 12:38 pm

Re: B+ USB 3G dongles OR USB Drive may trip brownout detecto

Wed Sep 10, 2014 12:47 am

superman wrote:Just did a quick check on the net, and have learnt that the K3571-Z also has a small storage space. I just wonder if this can be the problem. Besides, no offence, do your B and B+ run exactly the same OS?
I'll try and disable the virtual CD functionality and see if that makes any difference. I'll report back!

My two Pis run exactly the same SD card image (and thus the same OS, Raspian) -- the B+ was duplicated from the B using dd to directly copy the SD card bit for bit. Both thus have the latest Pi firmware and OS updates from the date of my last post.

Cheers.

Aydan
Posts: 727
Joined: Fri Apr 13, 2012 11:48 am
Location: Germany, near Lake Constance

Re: B vs B+ - USB 3G dongle now trips current limiter

Wed Sep 10, 2014 11:14 am

zorch wrote:By the way, I am using a 2A power supply.
Is that a supply with a fixed USB cable or one with a USB socked and an extra USB cable?
If the cable is detachable, try a shorter cable or one with thicker power leads.
The best supply is no use if your cable drops the voltage under load.

Regards
Aydan

Return to “Troubleshooting”