Hey I'm looking to calculated battery lifetime but searches didn't really bring up much help

so ill explain the consumption and times

60mA for 10 min
3mA for 120ms
1.23mA for 120ms
11ma sleep for 1 hour 36min
the process repeats itself continuously

battery is 12v 3.4Ah

id like to understand how to tackle this, so any information is grateful
thanks

Battery lifetime in hours is roughly given by

(battery capacity in mAh)/(average current consumption in mA)

Your numbers don't make any sense, especially the "11 mA sleep".

battery is 12v 3.4Ah

You are using a buck converter, not a linear?

Convert each section to watt hours, add them up and you now have the watt hour requirement for 1 cycle. Use that with your battery specifications and you will come out close. Battery life changes with discharge rate.

The battery datasheet should give the capacity versus discharge rate (often in a graph).

jremington:
Battery lifetime in hours is roughly given by

(battery capacity in mAh)/(average current consumption in mA)

Your numbers don't make any sense, especially the "11 mA sleep".

I dont know what part of 11mA sleep doesn't make any sense
all my numbers make sense, the sensors are being switched off when not in use - not constant

TheMemberFormerlyKnownAsAWOL:
You are using a buck converter, not a linear?

not quite sure what this has to do with the calculations in regards to a battery?

Tparry:
not quite sure what this has to do with the calculations in regards to a battery?

Well, how much can you afford to burn-off?

I dont know what part of 11mA sleep doesn't make any sense

All of it.

If you implement sleep mode correctly, the microprocessor consumes about 100,000 times less than that. See this excellent tutorial: https://www.gammon.com.au/power

Let's get this clear. Are you saying your consumption figures are all measured at the battery i.e. at 12V?

If so then just do the calculations in mAh. 60mA for 1/6th hour = 10mAh. 11mA for 1.6 hour = 17.6mAh. The other bits are negligible. So in 1.76 hours you use 27.6 mAh. And your battery has 3400mAh. It's not difficult from there.

Of course you still need to guess how much of that 3.4Ah you can actually use. Batteries never practically deliver everything they promise. How much you get will depend on what type of battery you're talking about. They're definitely NOT all the same.

Steve

Battery is 12v 3.4Ah

When new, under the ideal conditions that the manufacturer no doubt used when testing it.

All batteries of whatever chemistry lose capacity as they age, my personal rule of thumb is to at least double the capacity I calculate that I need.