power supply questions

The official pyboard running MicroPython.
This is the reference design and main target board for MicroPython.
You can buy one at the store.
Target audience: Users with a pyboard.
Post Reply
miltmobley
Posts: 29
Joined: Mon Mar 07, 2016 11:44 pm

power supply questions

Post by miltmobley » Fri Nov 06, 2020 7:32 pm

I assume this has been asked before, but it might take much time to find the conversation.

If I connect an external 5v power supply to the board, will I also be able to connect usb cable to use repl over usb, etc?
If so, which supply will the cpu actually use?

My reason to do this is to ensure that the pyboard and other devices all get the same supply voltage.

User avatar
pythoncoder
Posts: 4793
Joined: Fri Jul 18, 2014 8:01 am
Location: UK
Contact:

Re: power supply questions

Post by pythoncoder » Sat Nov 07, 2020 7:15 am

Assuming you're talking about the Pyboard 1.1 rather than the D series, the USB power source connects to the Vin pin via a diode. This allows the Vin pin to substantially exceed 5V without putting the USB at risk. Internally the Pyboard regulates Vin down to 3.3V.

If you apply 5V to Vin this will supply the power unless the USB supply exceeds about 5.6V, in which case the diode will start to conduct. Depending on the nature of the circuitry connected to Vin, the voltage could rise. I've not measured USB signals but I'd expect the 5V supply from a connected PC to be properly regulated, so I think this is rather a theoretical possibility.
Peter Hinch

zaord
Posts: 50
Joined: Fri Jan 31, 2020 3:56 pm

Re: power supply questions

Post by zaord » Sun Dec 13, 2020 6:19 pm

Hi,

I still have a problem with the GND.
If I connect the Pyboard avec USB to my computer and If I need to use the DAc 1 (X1) to control alother device supplied with an external power supply, I need to have the same GND I think.

But when I do that, my mouse and all the other usb devices disconnect and reconnect ...

That's I don't understand ...

User avatar
pythoncoder
Posts: 4793
Joined: Fri Jul 18, 2014 8:01 am
Location: UK
Contact:

Eeek.

Post by pythoncoder » Mon Dec 14, 2020 6:47 am

Something is seriously wrong with your electrical connections. I'd review them carefully before you break something. Unfortunately it's hard to diagnose remotely unless you upload a circuit schematic of exactly what you're doing.
Peter Hinch

zaord
Posts: 50
Joined: Fri Jan 31, 2020 3:56 pm

Re: power supply questions

Post by zaord » Mon Dec 14, 2020 3:07 pm

If I connect any power supply and make just the connection between Pyboard connected with USB and just the GND of the PSU, that makes troubles. I Have 230 mV between the GND of the Pyboard and the GND on the PSU when unwired.

Maybe mass loops ? I ordered a usb to usb for isolating my pyboard to my Usb hub. I will see and give back the issue.

zaord
Posts: 50
Joined: Fri Jan 31, 2020 3:56 pm

Re: power supply questions

Post by zaord » Thu Jan 07, 2021 9:08 am

I have the same issue than viewtopic.php?f=6&t=1106&p=6594#p6594

I found that if I power on the psu before the usb, I have no problem at all, but if I connect The usb before the PSU I get problem...

Maybe I should make a OR diode circuit.

How can I do this ?
Do I need to put absolutely a shotty diode or a simple basic diode is ok ?

Which value for the Diode current / voltage I need to take ?

Best and Thanks

User avatar
pythoncoder
Posts: 4793
Joined: Fri Jul 18, 2014 8:01 am
Location: UK
Contact:

Re: power supply questions

Post by pythoncoder » Thu Jan 07, 2021 3:03 pm

There is a diode on the Pyboard 1.1: this will ensure that applying (say) 9V to Vin won't damage the computer's USB port. But it doesn't stop power flowing from the Vin pin when USB is connected.

I suspect that your power source doesn't like a voltage being applied to it when powered down. When USB is connected, Vin acts as an output. If this is being shorted to gnd it will cause the USB port to go into current limit with the sort of knock-on effects you're seeing. A diode in series with Vin will ensure that power can only flow into the pin from the PSU and would fix this. If your PSU is 5V any diode will do.
Peter Hinch

zaord
Posts: 50
Joined: Fri Jan 31, 2020 3:56 pm

Re: power supply questions

Post by zaord » Fri Jan 08, 2021 8:22 pm

But here, I connect only the GND ... I use the DAc to control a 3 phase brushless motor for a fan.
I have nothing on VIN because I just need the reference ..
I have connected the fan drinver ground to AGND of the micropython card.

Should I try something ?

Post Reply