PINE64
Powering up and down USB - Printable Version

+- PINE64 (https://forum.pine64.org)
+-- Forum: PINE A64(+) (https://forum.pine64.org/forumdisplay.php?fid=4)
+--- Forum: General Discussion on PINE A64(+) (https://forum.pine64.org/forumdisplay.php?fid=3)
+--- Thread: Powering up and down USB (/showthread.php?tid=4955)



Powering up and down USB - reverend_t - 08-17-2017

Hi all

I have a project that needs a USB device to be power-cycled remotely. Is there any way of doing this on the Pine A64/+?


RE: Powering up and down USB - MarkHaysHarris777 - 08-17-2017

There are many ways of doing this; some complicated and expensive, some less complicated and reasonably economical, and lot of options in-between.

The question really is too vague, and open ended. In general everything may be controlled remotely, over the web, with a phone app, and almost every way you can imagine; literally, if you can imagine it, it is probably possible in some context.


RE: Powering up and down USB - reverend_t - 08-17-2017

Sorry for the vagueness Smile Let me be clearer. There are some boards that allow the power to the USB ports to be cycled through the use of appropriate GPIO interfaces. Wondering if this were possible on the Pine64.

It appears that this is possible on the Rock64 https://forum.pine64.org/showthread.php?tid=4848 but I'm very very new to schematics Smile


RE: Powering up and down USB - MarkHaysHarris777 - 08-17-2017

(08-17-2017, 01:04 PM)reverend_t Wrote: Sorry for the vagueness Smile Let me be clearer. There are some boards that allow the power to the USB ports to be cycled through the use of appropriate GPIO interfaces. Wondering if this were possible on the Pine64.

It appears that this is possible on the Rock64 https://forum.pine64.org/showthread.php?tid=4848 but I'm very very new to schematics Smile


Well, we'd have to look at the schematics again;  I know this is possible on the Rock64 because the usb power is tied to gpio(s) via regulators !   

Let's take a look at the schematics ...


RE: Powering up and down USB - reverend_t - 08-17-2017

(08-17-2017, 03:03 PM)MarkHaysHarris777 Wrote:
(08-17-2017, 01:04 PM)reverend_t Wrote: Sorry for the vagueness Smile Let me be clearer. There are some boards that allow the power to the USB ports to be cycled through the use of appropriate GPIO interfaces. Wondering if this were possible on the Pine64.

It appears that this is possible on the Rock64 https://forum.pine64.org/showthread.php?tid=4848 but I'm very very new to schematics Smile


Well, we'd have to look at the schematics again;  I know this is possible on the Rock64 because the usb power is tied to gpio(s) via regulators !   

Let's take a look at the schematics ...

Thank you! And I want to learn quickly so if you point me there with some tips then I'd be hugelier(?) grateful Big Grin


RE: Powering up and down USB - MarkHaysHarris777 - 08-17-2017

Please see this schematic, page 9 of 19


You will notice that the two regulators EN line(s) ( similar to the Rock64 regulators ) are tied directly to Vcc-5v|usb-5v;  consequently the regulators are ON all the time.

If you look at the PMIC page ( power management integrated circuit ) you will see on the left bottom that the usb-5v is tied directly to Vcc-5v;  and you will further notice that the Vcc-5v is tied either directly to DCIN ( 5v ) or the 5v regulator from battery based on the  DC5v-Batt power jumper ( PMIC page top left ).  

So the bottom line is that the usb 5v is always ON based on a physical jumper setting;  however,  this is where it gets interesting !

... because the jumper doesn't have to be a physical jumper connector;  it can also be a relay ( or electronic switch of some kind ) that is activated via gpio(s) !   So, although the board is not wired internally for this support ( like the Rock64 is ) it is wired to be allowed via external control because of the DC5v-Batt power jumper !

Shy


RE: Powering up and down USB - reverend_t - 08-21-2017

Ah OK, I see where you're pointing at Smile

So if I get this straight, this jumper controls whether the vcc-5v is connected directly to the microusb 5v power supply or an upconverted 3.7V supply from the battery. So if I was powering this from DC, cutting the connection J9, 1, 2 would cut power to the 5V power rail, and so the USB devices.

I'm still not sure I understand completely, but staring at it helps. Thank you.

One further question (that makes me suspect I do not understand). The schematic also says "Note: When using DC 5V and battery supply together, Disconnect J9 1, 2, 3, 4" How in this case is the right voltage supplied to the USB power rail?