Android USB Charging Secrets

We all want our Android devices to charge faster. Here we reveal the secrets to maximising charging speeds.

Battery life is always the curse of any portable device, but with USB ports in plentiful supply, finding a power source isn’t usually that difficult. However, Android USB charging is one of those ‘dark arts’ and just because you see the charge light appear on your device is no guarantee you’re getting anywhere near the maximum charge rate.

Recently, we’ve been looking at Android kernel modifications. The kernel is the nerve centre of any operating system that keeps everything ticking over. But the default Android kernel is fairly well tied down by design to ensure you (or anyone else) can’t damage or attack your device. But ‘limitation’ is a dirty word to serious Android users and we’ve looked at a couple of kernel modification options including flashing a new kernel and incorporating the Xposed framework.

‘Fast charge’

We’ve waxed lyrical about how versatile Xposed is but at the time of writing, there’s one feature Xposed doesn’t offer that still requires a new custom kernel – and that’s the idea of ‘fast charging’.

It doesn’t appear in all kernels but it’s the idea of speeding up battery charging via USB when connected to a PC or notebook. If you have root access and the right kernel, there are plenty of free apps on Google Play that will tap in and accelerate your charging speed. How? The custom kernel will have a ‘fast_charge’ command module that can be toggled on or off via Terminal using the command:

echo 1 > /sys/kernel/fast_charge/force_fast_charge

Changing the ‘1’ to ‘0’ toggles it off again. XDA-developer faux123 extended this method by allowing you to also set the charge current. First, you run the above command but with ‘2’ instead of ‘1’, followed by:

echo “900” > /sys/kernel/fast_charge/fast_charge_level

You can replace the ‘900’ with 500, 900, 1200, 1500 or 2000 to represent the milliampere (mA) current level you want the charge level set to. Again, running the first command with ‘0’ toggles the whole thing off and back to original condition.

Understanding the risks

But this hack comes with definite risks and you need to understand how USB charging works and what this hack actually does.

When you plug your Android device into a USB power source, an initial negotiation or ‘handshake’ occurs between the power source and your device – that’s to provide your device with info on how the power source works and the charge current it can provide.

USB ports of PCs and notebooks generally have a more limited capacity to supply current than a dedicated wall charger, so Android has two general charge level settings – ‘USB’ and ‘AC’. The charge voltage is the same – 5VDC – but the initial negotiation tells the device which charge current rate setting to use.

In practice, ‘USB’ typically sets the charge current rate maximum to 500mA, whereas AC can set it anywhere between 500mA and 2000mA. Now obviously, if you can get your device charging at 2000mA, it’s going to charge four times faster than if it’s stuck at the 500mA level – but there’s a lot more again to deciding that maximum rate.

The kernel hack forces Android to use the ‘AC’ charging mode, regardless of what type of port the device is connected to, effectively bypassing the negotiation and saying to the power source ‘I’m taking whatever charge current I want!’ – and that can have consequences.

What actually happens

To understand what’s going down, a bit of ‘electronics 101’ will come in handy. A power source can supply electrical current up to a certain level – like water flowing from a pipe. Water can only flow at the rate determined by the diameter of the pipe and pressure behind the water. In electronics, that pressure is ‘voltage’ and in USB charging, it’s always fixed at 5VDC.

The diameter of the pipe sets the maximum possible water flow rate or in our case, the charger’s internal electronics sets the maximum charge current available. Ultimately, it’s the device to be charged that sets the charge rate – it decides how much current it wants from the power source.

In properly designed tech, this charge level will be perfectly matched to an accompanying power source’s capabilities, so everyone stays happy. But if the device tries to extract more current, that places excessive strain on the power source’s electronics – depending on how excessive the demand is, it may well significantly damage the power source.

That initial negotiation between the device and the USB power source is all about these two working out the maximum available charge current the power source can safely supply without blowing up. How that negotiation happens is a science in itself.

Android charging

USB charge standards

When the USB standard first arrived in the late-1990s, it was simply a serial data connection port – there was little thought for charging portable devices.

The original USB1.0 standard allowed up to 150mA of current to be pulled from the port; USB2.0 pushed that to 500mA and USB3.0 to 900mA – but that’s from standard PC/notebook USB ports.

In 2007, a new USB Battery Charging Specification standard appeared, defining two new port types. While the standard USB port is known as a ‘Standard Downstream Port’ (SDP), the two new types were the ‘Charging Downstream Port’ (CDP) and the ‘Dedicated Charging Port’ (DCP).

A CDP transfers data like an SDP but can also supply up to 1500mA of current with standard negotiation. A DCP doesn’t transfer data, but unlike other ports, can deliver 1500mA (or more) output without the hassle of negotiation.

How it works

Now here’s where we get into device design – the USB ports on Android devices are typically handled by special-purpose chips made by brands such as Texas Instruments, Maxim, Microchip and ST Microelectronics.

Because there are now multiple power source specifications just in the USB standard alone, these chips have plenty of work to do. But it’s further complicated by the negotiation techniques implemented by the various device manufacturers.

The basic USB port has four connections – Vcc (5VDC), GND (0VDC), Data+ (D+) and Data- (D-). These last two connections carry the data to and from your device to your PC, external storage or whatever you connect up.

Electrically, they form what’s known as a ‘complementary pair’ – whatever digital signal is on one line, the opposite appears on the other. This is to help reduce electrical interference and maintain maximum data speed. But they’re also the primary location for charge rate negotiations.

Different manufacturer standards

But device makers being a competitive lot, there’s no one standard negotiation – it’s a bit like having to speak six languages.

Apple started it with the iPhone – since the original USB specification had no standard for high-speed battery charging, Apple came up with its own ‘electrical signature’.

It decided that if an iPhone or iPad came up against a USB port with 2.0VDC on the D+ line and 2.7VDC on the D- line, that port would be an Apple iPhone (DCP) charger that could supply 1000mA of current. If the voltages were reverse (2.7V/2.0V on the D+/D- lines), it’d be an iPad charger with 2000mA maximum supply.

But it didn’t end there. While the USB forum released a generic ‘signature’ standard, other manufacturers came up with their own signatures and in the end, there are at least six D+/D- signatures in the wild:

  • 2.0V/2.0V – low power (500mA)
  • 2.0V/2.7V – Apple iPhone (1000mA/5-watt)
  • 2.7V/2.0V – Apple iPad (2100mA/10-watt)
  • 2.7V/2.7V – 12-watt (2400mA, possibly used by Blackberry)
  • D+/D- shorted together – USB-IF BC 1.2 standard
  • 1.2V/1.2V – Samsung devices

These days, resistance-based voltage sensing options like the first four are described as ‘legacy’ modes and all new devices we believe use chip-based detection.

However, with millions of ‘legacy’ devices (and even more AC chargers) in the wild, they still have to be accounted for. Chips like Texas Instruments’ TSP2514 and TSP2543, Microchip’s USB2534 and ST Microelectronics STCC5011 all handle these various signature combos.

In practice

Hopefully, you can see there is this ‘nightmare of negotiation’ that has to be navigated in order to reach the highest charge rates.

As we said before, it’s your device that practically determines the charge rate, even if the power source has more to give.

That’s why for example, an iPhone will only charge at 1000mA even if it’s connected to a 2100mA iPad charger. But it’s also why an iPad will only take 1000mA from an Apple iPhone charger instead of its preferred 2100mA.

But while Apple devices have specific cables and chargers to help ensure those rates, Android devices typically use the generic microUSB port connection and connect to a myriad of USB chargers.

The secret

And this is where the whole idea of maximum charge rates tends to come crashing down in a screaming heap.

Unless the third-party charger has a proper controller chip or at least the right basic signature, there can be no negotiation between the device and power source, which means the device must fall back to a default charge current, typically 500mA – even if the power source can supply more.

What’s more, the signature voltage specifications are typically quite tight so if they’re a little bit out of spec, the signature won’t be detected and again, a lower fall-back charge current used. And this is where USB cable quality now comes into play.

You might well be able to find a cheap replacement USB cable online, but there can be two major problems. The first is by using light-gauge wire, a cheap cable may alter signature voltage, possibly enough to push it outside of specification and detection. The other issue is the light wire gauge will also see greater power losses, meaning your device can’t charge up at maximum speed anyway.

So, in the end, there are three areas where USB charging can be adversely affected – the USB port standard used (SDP, CDP or DCP), electrical signature mismatching and the quality of the USB cable being used.

And since not all USB chargers are built to the same standards, mixing and matching your chargers with different devices could well result in slower charge rates, requiring more time for your device to charge.

Bottom line, unless you get all three areas sorted out, you cannot reach maximum charging speeds.

Android charging 2

Testing charge currents

While there are software ways of monitoring power draw through SDP USB ports (Windows, for example, can display this in Device Manager), the only way you can test DCP chargers is with what’s called ‘inline testing’ and there are two ways you can do it.

The first is by building your own test rig that enables you to insert a digital multimeter with a high current range in series with the Vcc supply rail – and that’s what I’ve done.

The other is a dedicated USB power monitoring device – you can find cheap models for under $3 on eBay that measure volts between 3-7VDC and current between 0-3000mA (3-amps).

Now you’re probably thinking you can’t expect brilliant accuracy for just $3, but you just need something good enough to show you which charge mode you’re in, whether it’s nominally 500mA, 1000mA or 2100mA depending on your charge port and your Android device.

It’ll also show you the difference between a good and poor-quality USB charge cable. These monitoring devices are easy to use too – you plug your charge cable into one side and the other side plugs into the USB charge port or charger. The display alternates every few seconds between voltage and current, measured in volts and amps, respectively.

It’s up to you

USB charging is a minefield of official and proprietary standards, all mashed up together with a mind-blowing array of ports, chargers and cables.

Ultimately, you cannot make your device charge up any faster than the maximum rate it supports – whether you have the correct charger or a small nuclear power station, your Android device will have its own limit and that’s that.

However, you can positively affect the charge rate by ensuring you understand how USB charging works and making sure you’re using the right gear.

  • Have heard of this product before,but today know much ,thanks!

  • lenad ondex

    Very good article with awesome details . Though I know much about USB charging, got to learn a number of new things. Thanks.

  • Adam

    Very nice.
    Thank you

  • Daniel von Calabrese

    I think there must be hardware/elecronics job to be done, not only software(tweaking the kernel)…

  • Paccy

    very nice article…. appriciate…. thanks

  • Shawn Gehani

    Awesome article. Takes the charging discussion from 101 level to 401.

  • Radek Bokuvka

    Very informative article, thanks for posting.

  • 88BlueKeys4U .

    Thank you for this very good collection of information! About the most comprehensive I found so far.

    It sort of explains (but does not really solve) the odd behavior of my smartphone, an older NEO 003 with a beefy 3000mAh battery.
    The phone is usually charged in its off-state by AC.
    After years of reliable charging the phone began to select the LOW current mode when charging its battery (i.e. pulling 450mA instead of the 810mA possible). This would typically double the charge time – I was pissed.
    I suspected bad USB cables or a bad AC chargers, switched both numerous times, with no luck: randomly the phone would pick the higher charge current, usually it would not, regardless of cable/charger combinations used.

    Interestingly I could force it to accept the 800mA current if switching the phone ON during the charge process. It would then jump to the higher charge rate and KEEP it, even if the phone was now switched off while still connected to the AC charger,.
    This is currently my ONLY reliable method to enforce acceptable charge times with the higher current: charge, if current is low power phone on, watch charge current jump to high and turn phone off. Stupid, but works like a charm!

    So far I have refrained from prepping a unique USB ‘charge’ cable with hardwired shorts between the center data pins. It would probably be worth a try to see how the phone reacts to such a cable, no?

    Now what exactly is the root cause? Given that any cable or power supply can be used with the same results it must be the USB detection chip inside the phone that somehow has shifted its sensitivity to the data line resistance.
    The phone works fine as a USB device, i.e. it communicates on the USB bus without any flaws. All four USB pins on the phone’a connector are clean and straight anyways; they are most likely not responsible for the odd behavior.

    So this is my own story about USB charge currents, Hi/Lo states and their detection woes.
    If anyone has a better explanation or solution – thanks!!

    • anonymous

      I had the same issue – my phone kept switching to the low charge current mode no matter what I did. I tried 5 different chargers. Turned out the 5-year-old battery was dying. Once I replaced the battery with a new one the problem went away.