Short-bus / pilomar

RaspberryPi based miniature observatory
https://shortbus.blog/
GNU General Public License v3.0
63 stars 14 forks source link

Improve handling of USB & GPIO connections to microcontroller at the same time. #24

Closed Short-bus closed 9 months ago

Short-bus commented 9 months ago

Normally the RPi -> Microcontroller connection is entirely via the GPIO header. Both POWER and UART comms are handled through that. When updating the software on the Microcontroller a USB connection is required. There is an electrical risk that having both GPIO and USB connected at the same time provides two conflicting power sources to the microcontroller. This may cause problems/damage. The microcontroller board can be protected with an appropriate diode on the GPIO power circuit, but for additional safety it's possible to recognise that the USB connection exists and prevent the RPi enabling the power signal pin in the GPIO header too.

Short-bus commented 9 months ago

Testing new version of pilomardisc.py and pilomar.py. When it searches USB for potential memory stick it now also recognises any CIRCUITPY labelled device and disables the GPIO Power (aka 'reset') pin so that power ONLY comes from the USB connection.

Short-bus commented 9 months ago

Summer2023 update includes this functionality.