djbriane's mintyPi's with 500c and Safe Shutdown

Show off your completed mintyPi, or post your build logs here!
Post Reply
User avatar
djbriane
Posts: 61
Joined: Mon Sep 12, 2016 10:34 am
Has thanked: 92 times
Been thanked: 59 times

djbriane's mintyPi's with 500c and Safe Shutdown

Post by djbriane » Thu Aug 03, 2017 9:21 pm

Wanted to show off my two mintyPi builds - Peppermint and Spearmint. I had a few challenges along the way but in the end they turned out great and I think I love them more than my GBZ!
SpoilerShow
IMG_0534.jpg
IMG_0534.jpg (2.25 MiB) Viewed 8197 times
SpoilerShow
IMG_0530.jpg
IMG_0530.jpg (2.08 MiB) Viewed 8197 times
SpoilerShow
IMG_0467.jpg
IMG_0467.jpg (1.94 MiB) Viewed 8197 times
In one of my builds I decided to use the PowerBoost 500c instead of the microLiPo, initially because the micro USB socket kept getting pushed into the case as I plugged it in to charge. However, I discovered that I could wire the LBO (low battery) pin on the 500c to an unused GPIO pin to safely shutdown the Pi when the battery is out of juice. Then I combined this with HoolyHoo's library for showing an indicator on the screen so I get a little warning before the Pi shuts itself down (about 2 minutes seems to be the sweet spot).

Here's a pic of the insides with the 500c in place (yes, I had to jumper one of the pins on the Pi as I couldn't get a reliable connection for ground :oops:):
SpoilerShow
IMG_0522.jpg
IMG_0522.jpg (2.74 MiB) Viewed 8197 times
This is the wiring I used to connect everything up:
SpoilerShow
mintypi-wiring-v2-500c_bb.jpg
mintypi-wiring-v2-500c_bb.jpg (317.77 KiB) Viewed 8197 times
Here's the code I'm using in case anyone wants to try the same (I forked the Pimoroni library as I liked how cleanly it installs):
https://github.com/djbriane/clean-shutdown

User avatar
Lphillimore
Posts: 993
Joined: Sat Jan 07, 2017 7:03 pm
Location: Perth, WA
Has thanked: 796 times
Been thanked: 527 times

Re: djbriane's mintyPi's with 500c and Safe Shutdown

Post by Lphillimore » Thu Aug 03, 2017 9:27 pm

Awesome builds!

Great work on that safe shutdown,too. Nicely done! :D

User avatar
wermy
Site Admin
Posts: 1346
Joined: Tue May 03, 2016 8:51 pm
Has thanked: 620 times
Been thanked: 1322 times
Contact:

Re: djbriane's mintyPi's with 500c and Safe Shutdown

Post by wermy » Fri Aug 04, 2017 9:14 am

NICE! Thanks for sharing - I've wondered about using the low battery LED pads on a powerboost for safe shutdown. :)
ImageImageImageImage

User avatar
rodocop
Posts: 1723
Joined: Mon Aug 22, 2016 3:14 pm
Location: Saskatchewan
Has thanked: 606 times
Been thanked: 608 times

Re: djbriane's mintyPi's with 500c and Safe Shutdown

Post by rodocop » Fri Aug 04, 2017 9:45 am

Thanks for sharing! Once I open my first one up to add the speaker I will add in the low battery warning like you mentioned.

User avatar
djbriane
Posts: 61
Joined: Mon Sep 12, 2016 10:34 am
Has thanked: 92 times
Been thanked: 59 times

Re: djbriane's mintyPi's with 500c and Safe Shutdown

Post by djbriane » Fri Aug 04, 2017 11:43 am

Made a short video showing the shutdown in action:


PocketSand
Posts: 1
Joined: Thu May 25, 2017 2:43 am
Has thanked: 3 times

Re: djbriane's mintyPi's with 500c and Safe Shutdown

Post by PocketSand » Fri Aug 04, 2017 10:04 pm

Nice, thanks for sharing the vid!

User avatar
rodocop
Posts: 1723
Joined: Mon Aug 22, 2016 3:14 pm
Location: Saskatchewan
Has thanked: 606 times
Been thanked: 608 times

Re: djbriane's mintyPi's with 500c and Safe Shutdown

Post by rodocop » Thu Aug 31, 2017 8:59 pm

djbriane wrote:
Fri Aug 04, 2017 11:43 am
Made a short video showing the shutdown in action:

So im in the process of installing your script and have an issue, I see in the video you have a battery icon, I do not see that after installation, please see the image for what I see when I try to install, is this normal? ( I ran the setup.sh again after I installed so I could copy the text again). Other than waiting till the battery dies, is there a way to test if it is working? Do i need to install HoolyHoo's battery monitor script separately?

I have placed the clean-shutdown-master folder into /home/pi/RetroPie/ directory, it would not let me copy it to /boot or /root
SpoilerShow
Image
oops, cut one line off in the image, after the installing indicator it shows:
mkdir: cannot creat directory '/usr/local/share/icons': File exists

User avatar
Camble
Posts: 885
Joined: Thu May 05, 2016 2:31 am
Location: Scotland
Has thanked: 269 times
Been thanked: 488 times

Re: djbriane's mintyPi's with 500c and Safe Shutdown

Post by Camble » Sat Sep 02, 2017 4:45 am

These look awesome! I must have been living under a rock lately. Not sure if you're too bothered, but you might want to measure the voltage at the LBO pin when charging. With the PowerBoost 1000C, the voltage can be as high as 5v. At the very least, you'd want to have a 10K resistor in there, but there's still a risk of damaging the GPIO pin. As well as the resistor, you can connect a diode from the GPIO pin to the 5v supply to clamp the voltage to a tolerable level.

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest