Powering electronics over VUSB / VCOM
Posted: Wed Jul 15, 2020 12:13 pm
Hi Folks,
Hoping you might be able to help me out, I'm looking to make sure there isn't a simple way to do what I am trying to do. This a bit long, so the TLDR is - How do I power 5V electronics safely from the 'flie on a deck if the pin I need to connect to can have 5V external USB applied to it? Is there a configuration where I can use this external 5V to charge a battery connected to the flie? Do I need a voltage regulator? Is it safe to plug VCOM into external USB power?
I think the answers are - Use VCOM for getting power and use a voltage regulator, charge via VUSB. Don't short them, and don't put 5V external USB power into VCOM.
A search of the forum gets me close to an answer to my questions, particularly arnaud's answer on this thread, but I haven't found anything which specifically addressed what I'm trying to do (it might be there, but in that case I missed it, sorry!).
I'm trying to power a Teensy (model 4.0 and model 4.1 attached to a Crazyflie (model 2.0 and a Bolt). I want to be able to plug in the Teensy to external USB so I can reprogram it and pull data off of its SD card. My concern is how to do this safely. It would also be nice if I could charge the battery on the 'flie while the Teensy is attached to my computer via USB. It would be even nicer if I could not cook the 'flie when I plug the Teensy in.
My assumption was that I could connect this via the VUSB line. However if I do this with battery power with the Teensy attached the drone becomes unresponsive and does not pass the self test. Both blue indicator LEDs are on, but no other LEDs blink and the motor self test does not occur. Checking via multimeter the voltage on VUSB is about 1.2V with the Teensy attached. The only other pins I am currently attaching is the ground. I can power this set-up successfully via VCOM, but I don't know if it is safe to plug in the Teensy into USB in this configuration (I'm assuming no, since the 5V pin on the Teensy is just the 5V from USB on my computer, so this is basically the same as plugging VCOM directly into the USB which looking at the schematics has 'nope' written all over it).
The Teensy will is pretty tolerant as far as input voltage goes (3.6V-5.5V). I've consulted the REVC schematics to see how VCOM_EXP (just VCOM and on the actual board), and VUSB (CHG on the board), pins 9 and 10 on the right connector, are hooked up. Now VUSB just seems to be directly connected to the USB 5V line, while VCOM_EXP is connected via a SiP32431 load switch. When the 'flie is using a battery the path between +BATT and VUSB goes via a BQ24075 linear charger. Looking at the schematics I don't see any reason to expect 5V on VUSB unless external USB is attached, unless my understanding of the BQ24075 is flawed (which is entirely likely).
I think this gels with my observations. If I plug the 'flie or Teensy in via USB, the 'flie properly boots and the battery starts charging when the Teensy is connected via VUSB. Unplug the external USB and no dice.
Another concern I have is that VCOM seems to me as though it will sit at the battery voltage when not plugged into external USB power. Is that the case? Because if so, I'll probably need to find some new batteries if I power the Teensy over VCOM, or add a voltage regulator. Probably the latter since I'd need to charge the batteries over the BQ24075 which charges at 4.2V.
My suspicion is that I will need a voltage regulator and maybe some additional circuitry between the 5V pin on the Teensy, and VUSB and VCOM on the 'flie so that when the Teensy is plugged in it puts 5V on VUSB, and when it isn't it draws power from VCOM, and never directly connects VCOM to external USB power (or VUSB for that matter). Is that inference correct?
Hoping you might be able to help me out, I'm looking to make sure there isn't a simple way to do what I am trying to do. This a bit long, so the TLDR is - How do I power 5V electronics safely from the 'flie on a deck if the pin I need to connect to can have 5V external USB applied to it? Is there a configuration where I can use this external 5V to charge a battery connected to the flie? Do I need a voltage regulator? Is it safe to plug VCOM into external USB power?
I think the answers are - Use VCOM for getting power and use a voltage regulator, charge via VUSB. Don't short them, and don't put 5V external USB power into VCOM.
A search of the forum gets me close to an answer to my questions, particularly arnaud's answer on this thread, but I haven't found anything which specifically addressed what I'm trying to do (it might be there, but in that case I missed it, sorry!).
I'm trying to power a Teensy (model 4.0 and model 4.1 attached to a Crazyflie (model 2.0 and a Bolt). I want to be able to plug in the Teensy to external USB so I can reprogram it and pull data off of its SD card. My concern is how to do this safely. It would also be nice if I could charge the battery on the 'flie while the Teensy is attached to my computer via USB. It would be even nicer if I could not cook the 'flie when I plug the Teensy in.
My assumption was that I could connect this via the VUSB line. However if I do this with battery power with the Teensy attached the drone becomes unresponsive and does not pass the self test. Both blue indicator LEDs are on, but no other LEDs blink and the motor self test does not occur. Checking via multimeter the voltage on VUSB is about 1.2V with the Teensy attached. The only other pins I am currently attaching is the ground. I can power this set-up successfully via VCOM, but I don't know if it is safe to plug in the Teensy into USB in this configuration (I'm assuming no, since the 5V pin on the Teensy is just the 5V from USB on my computer, so this is basically the same as plugging VCOM directly into the USB which looking at the schematics has 'nope' written all over it).
The Teensy will is pretty tolerant as far as input voltage goes (3.6V-5.5V). I've consulted the REVC schematics to see how VCOM_EXP (just VCOM and on the actual board), and VUSB (CHG on the board), pins 9 and 10 on the right connector, are hooked up. Now VUSB just seems to be directly connected to the USB 5V line, while VCOM_EXP is connected via a SiP32431 load switch. When the 'flie is using a battery the path between +BATT and VUSB goes via a BQ24075 linear charger. Looking at the schematics I don't see any reason to expect 5V on VUSB unless external USB is attached, unless my understanding of the BQ24075 is flawed (which is entirely likely).
I think this gels with my observations. If I plug the 'flie or Teensy in via USB, the 'flie properly boots and the battery starts charging when the Teensy is connected via VUSB. Unplug the external USB and no dice.
Another concern I have is that VCOM seems to me as though it will sit at the battery voltage when not plugged into external USB power. Is that the case? Because if so, I'll probably need to find some new batteries if I power the Teensy over VCOM, or add a voltage regulator. Probably the latter since I'd need to charge the batteries over the BQ24075 which charges at 4.2V.
My suspicion is that I will need a voltage regulator and maybe some additional circuitry between the 5V pin on the Teensy, and VUSB and VCOM on the 'flie so that when the Teensy is plugged in it puts 5V on VUSB, and when it isn't it draws power from VCOM, and never directly connects VCOM to external USB power (or VUSB for that matter). Is that inference correct?