Ashnook13
Posts: 57
Joined: Wed Sep 26, 2012 3:43 pm

'StayAlive' battery.

Sat Oct 06, 2018 11:24 am

I want to build a pi project that will be autimatically powered down some seconds, say 30 seconds, after power is turned off. It is a car based project powered when the ignition is onand after r the ignition is turned off stays alive to power down gracefully. The battery needs to be topped up when the 12v car supply is on. I don't need much capacity for this time.

Is there anything available to do this or a project that has been done?

many thankx, Brian

Andyroo
Posts: 461
Joined: Sat Jun 16, 2018 12:49 am
Location: Side of the hill in Lincolnshire

Re: 'StayAlive' battery.

Sat Oct 06, 2018 10:25 pm

Would something like this do http://www.allspectrum.com/mopower/

You would need to sort power surges, voltage differences and check if the Pi does not draw power when off (hate to find it flat Monday going to work) but it may be a start point.
Need Pi spray - these things are breeding in my house...

User avatar
thagrol
Posts: 880
Joined: Fri Jan 13, 2012 4:41 pm
Location: Darkest Somerset, UK
Contact: Website

Re: 'StayAlive' battery.

Sun Oct 07, 2018 2:02 pm

Why add an extra battery when there's already a big one under the hood?

According to my research, the circuit I posted here should do what you want. Be aware though that 1. I'm not an eletrical engineer, 2. I'm not an automotive mechanic, and 3. I've yet to build this myself. It does simulate OK.

The idea behind this circuit is that by using the gpiopoweroff device tree overlay the Pi can use the second relay to cut power.

https://www.raspberrypi.org/forums/view ... 4&t=208152
Note to self: don't feed the trolls
If you believe "L'enfer, c'est les autres" (Hell is other people) have you considered that it may be of your own making?

Ashnook13
Posts: 57
Joined: Wed Sep 26, 2012 3:43 pm

Re: 'StayAlive' battery.

Sun Oct 07, 2018 4:30 pm

Thanks for the replies. the battery looks interesting and i will investigate it.
regarding the keep alive circuit [second reply], looks good to me but the problem might be that I may only have power when the ignition is on and i might not be able to find a local 12v supply {at the rear of the car}.

both ansqers look interesting, thanks.

Brian

User avatar
Imperf3kt
Posts: 1383
Joined: Tue Jun 20, 2017 12:16 am
Location: Australia

Re: 'StayAlive' battery.

Sun Oct 07, 2018 8:30 pm

Does your car have a trailer connection? Inside that wire there will be a large +12v connection and ground (or use the car body)
It should be labelled 'aux' if your trailer coupling is labelled.

Note that this 12v is ALWAYS on and not switched with the regular auxiliary power.
Stop plugging your fan directly into the GPIO 5v
https://www.electronics-tutorials.ws/power/transient-suppression.html

User avatar
thagrol
Posts: 880
Joined: Fri Jan 13, 2012 4:41 pm
Location: Darkest Somerset, UK
Contact: Website

Re: 'StayAlive' battery.

Sun Oct 07, 2018 11:26 pm

Ashnook13 wrote:
Sun Oct 07, 2018 4:30 pm
regarding the keep alive circuit [second reply], looks good to me but the problem might be that I may only have power when the ignition is on and i might not be able to find a local 12v supply {at the rear of the car}.
If you don't mind running a cable to the back of your car, there are a couple of easy places to tap an always on +12v and ground in the dash:
  • The back of the radio. you can also tap the ACC live feed here too.
  • The diagnostic port (aka the OBD port)
Other than that, try to get hold of a wiring diagram for your car.
Note to self: don't feed the trolls
If you believe "L'enfer, c'est les autres" (Hell is other people) have you considered that it may be of your own making?

mosespi
Posts: 508
Joined: Mon May 12, 2014 3:35 pm
Location: 34,-118
Contact: Website

Re: 'StayAlive' battery.

Tue Oct 09, 2018 5:21 am

Andyroo wrote:
Sat Oct 06, 2018 10:25 pm
Would something like this do http://www.allspectrum.com/mopower/

You would need to sort power surges, voltage differences and check if the Pi does not draw power when off (hate to find it flat Monday going to work) but it may be a start point.

That is my design linked above. It has an automotive grade TVS for voltage spikes and an operating voltage up to 30v DC.
It draws a super low 0.25mA when the Pi is shut down. You can omit the UPS battery and use it on a constant (not ignition switched) supply, or operate it on a switched ignition with an additional battery (or supercapacitor). I prefer the constant supply since you can also program the UPS to power up your Pi at certain intervals.

If wired to constant power you can also setup the UPS to detect when the car (alternator via voltage) is ON/OFF and turn on and off your Pi without running an additional switched input. Check the "UPS Input Control Settings" section for an example of this.

Regards,
-Moses
Power problems? MoPower UPS for the Pi
http://www.allspectrum.com/mopower/

Ashnook13
Posts: 57
Joined: Wed Sep 26, 2012 3:43 pm

Re: 'StayAlive' battery.

Tue Oct 09, 2018 6:39 am

I suppose I need to look into getting a 12v
constant supply to the rear of the car.

cheers

User avatar
Imperf3kt
Posts: 1383
Joined: Tue Jun 20, 2017 12:16 am
Location: Australia

Re: 'StayAlive' battery.

Tue Oct 09, 2018 6:44 am

Ashnook13 wrote:
Tue Oct 09, 2018 6:39 am
I suppose I need to look into getting a 12v
constant supply to the rear of the car.

cheers
As I mentioned earlier, if your vehicle is fitted with a trailer connection, there is a high possibility it has an "aux" connection, which is a direct 12v supply from the battery and should be good for about 20 amps. You can tap into it, usually from before the rear quarter panel structural support, or the floor below your parcel shelf.
Stop plugging your fan directly into the GPIO 5v
https://www.electronics-tutorials.ws/power/transient-suppression.html

Ashnook13
Posts: 57
Joined: Wed Sep 26, 2012 3:43 pm

Re: 'StayAlive' battery.

Tue Oct 09, 2018 8:24 am

yes, i need to look for that but i suspect it won't be there. I don't have a tow bar either.

Return to “Other projects”