circuitpython
circuitpython copied to clipboard
Badger 2040 - freezes or errors out when reset with battery power.
Thank you for creating this Circuitpython port of the BadgerOS!!
I have been trying for the past few days to run the Badger 2040 using external power, a few things I have noticed:
- If I power ON with USB BadgerOS runs.
- If I power ON the board from the external power supply, BadgerOS does not run.
- if I keep the battery plugged in while powering with USB BadgerOS runs.
- If I remove the USB while the battery is plugged in, BadgerOS continues to operate.
- If I reset or power cycle the board, BadgerOS does not run.
Any idea on how I can go about resolving this?
Thank you!!
Hello, Indeed starting on the battery is a bit tricky. I had the same problems with mine to the point that I thought it had a problem but it is not. I've been talking for a while with Chris Parrott (in charge of the circuitpython port on the badger2040 at Pimoroni among others) and together we found a temporary solution.
In fact you have to leave one of the 5 buttons (whatever) pressed for 10 to 20 seconds (I didn't count). We press, we note that the led flashes 3 times from memory, then will turn on again and at this moment we release and the device starts. Pimoroni (Chris Parrott) try to find a solution for this problem.
I also have to look with the lib alarm if on the battery we can put the RP2040 in deep sleep and then wake it up with the button (like in the micropython version).
I will also try in the next few days to note how to boot on battery as I just explained.
personally I choose the badge etc and when I'm on battery, I press reset to "turn off" the device
Thank you, @beboxos! your solution worked perfectly. Putting the RP2040 into deep sleep on battery would be a nice solution to have.
I look forward to your updates!!
Just converted my Badger2040 to CircuitPython, but I'm getting an error when code.py starts. The error is in line 51 that GPIO10 is already in use. There is a #hack comment line just above it, so I'm wondering if it wasn't intended to be a permanent part of the code. Thanks.
When I commented out that line and the two others that were part of that section, it continued OK. I'm checking it now to verify proper operation of the rest of the system.
#hack set pin10 3V3 to high #pin3v3 = digitalio.DigitalInOut(microcontroller.pin.GPIO10) #pin3v3.direction = digitalio.Direction.OUTPUT #pin3v3.value = True
Just converted my Badger2040 to CircuitPython, but I'm getting an error when code.py starts. The error is in line 51 that GPIO10 is already in use. There is a #hack comment line just above it, so I'm wondering if it wasn't intended to be a permanent part of the code. Thanks.
When I commented out that line and the two others that were part of that section, it continued OK. I'm checking it now to verify proper operation of the rest of the system.
#hack set pin10 3V3 to high #pin3v3 = digitalio.DigitalInOut(microcontroller.pin.GPIO10) #pin3v3.direction = digitalio.Direction.OUTPUT #pin3v3.value = True
Thank you for sharing. I had the same issue and this fix worked for me :)