Charging via USB

No, if it is just charging it would not show up in usbconfig.

You should buy a USB powermeter. Very handy and they also answer questions like this one.
 
Depends, if it's a USB power cable, no, because there's no data connected. Also some devices might have a charging only option, even if you used a "full" USB cable there's still no data connection between the host and the device.
 
What kind of device are we talking about? Doesn't the device itself show when it's being charged? Phones all have a battery icon with a special lightning bolt. Same for portable media players. Many earbud cases have a button to check the status (full/empty/charging).
Note that not every USB port on a computer is powered. Power delivery can vary between ports. Some BIOS/UEFI firmware allow you to control that. Long USB cables can also significantly impact power delivery.
 
Depends, if it's a USB power cable, no, because there's no data connected. Also some devices might have a charging only option, even if you used a "full" USB cable there's still no data connection between the host and the device.
Please explain what a FULL usb cable is and how I identify one.
 
What kind of device are we talking about?
1781207039487.png
 
balanga, doesn't it have a LED near the USB connector? It should be blinking while it's charging.
Yes, I can see it now. The problem was that I hadn't used this keyboard for a long time and couldn't establish if was charged up. After trying various cables and USB ports on various computers I can see that it is blinking.

I'm still in the dark about what a full USB cable is and whether some show a presence under lsusb/usbconfig whilst charging.
 
I'm still in the dark about what a full USB cable is and whether some show a presence under lsusb/usbconfig whilst charging.
SirDice is probably referring to the internal wiring of the cable. A typical USB cable has 4 wires: 1 power, 1 ground and 2 data.
Some rare ones only have data wires.
Some only have positive and ground wires; they only charge and can't transfer data.
Most cables out there have the 4 wires and can both charge and transfer data, if, as I already mentioned before, the port it's connected to has power on it (and enough juice to deliver it) and charging hasn't been disabled in the BIOS/UEFI (usually in the southbridge section).
 
I'm still in the dark about what a full USB cable is and whether some show a presence under lsusb/usbconfig whilst charging.

There are charge-only USB cables that you can buy (and that are sometimes included in device sales). You can also buy cables with a switch that always charge but let data through only when you use the switch. That's a security feature in case you want to charge from a device you don't control. I am not sure whether they have those for USB-C, but I have multiple micro-usb examples.

Again, what you might like for questions like this is a USB powermeter.
 
Charging is done by an electronic circuit that controls and adjusts voltage, current and terminates the charging, when the battery is full. Those circuits are part of any charger (not to be confused with power supply units, even if in many cases they look similar), or are part of the according device, but anyway directly attached to the battery.
An USB port only delivers the power as a constant voltage source and cannot tell, what the current is used for, or why there are changes in load. Its voltage regulator simply keeps the voltage constant to the rated level, and depending on the power drawn delivers the asked current up to the rated maximum.

So, no, there is no way looking at any USB port and tell if a battery is charged, if it's full or for wich all devices and loads the power is used the port delivers.

Also the battery states are mostly measured and delivered by a so called fuel gauge. Those circuits are an integrated part of the battery. The device communicates with the battery's fuel gauge over Smart Battery Bus, I2C, 1-Wire-Bus or some other bus. And normally only the manufacturer knows which one. And even if you find out, which one, you cannot have direct access to it easily, unless you have the according rights and tools of the installed OS to get to that bus. And even if so, I doubt you can get anything useful of that data, since it comes in very raw form another software on OS's side translates into readable values.
So, you either have to live, with what the OS delivers you. Or, as cracauer@ said, you need to get a powermeter to watch the power changes. And even so you need to learn to read that information, because besides the battery charging there is other, alternating power used on the device while, before and after charging.

Duck-ai-image-2026-06-12-15-05.jpeg
 
Back
Top