Turn USB power off

Hello everyone,

I got a BPI-M2 Zero connected via OTG to a device that recognises power levels of the USB port.

I would like to be able to turn off the USB power of the port. Is there any way to achieve this? All attempts using the generic “uhubctl” or /sys/devices/usb “level” “power” etc. attempts failed. This turns of the USB in the linux system but the port is still powered.

Im open for any solution. Could be also a wiring from the GPIO ports to the USB port, as long it’s controllable from Linux.

Thx & Best, ksh

anyone? ideas? hints?


Igor, this is nothing valuable. All of the standard solutions tried.

Did you check the schematic if this is at all possible?

Otherwise you need an USB hub that can switch the power, of which there are very few…

I am 100% sure this issue was discussed. This is another quick search https://github.com/mvp/uhubctl Don’t know if this is usable …

This works partially on a M5 with some /proc entries set. However, nothing work on the M2-Zero. Not uhubctl, no proc entries with “unbind” und “authorized” settings in procfs. Like mentioned the USB device disappears, that means he bus internals are toggled, HOWEVER the power is still there!

I’m rather looking on any insides from the manufacturer like toggling GPIOs or getting access to some DTB of the SoC that allows to cut the power.

I ve found this assessory:

Still an ugly solution for a petite device to blow it up