Anyone else using a Raspberry Pi to log their battery data, or is it overkill?

by Hannah Davies · 5 days ago 28 views 6 replies
Hannah Davies
Hannah Davies
Active Member
21 posts
Joined Apr 2025
5 days ago
#35095

Running a Pi 4 logging every 30 seconds from my Victron SmartShunt via VE.Direct, feeding into InfluxDB, and then Grafana dashboards that make my narrowboat look like it's being monitored by NASA — absolutely not overkill, this is the way.

The smugness alone when you can tell your mate exactly what percentage your Fogstar 200Ah dropped to at 3am because the diesel heater kicked in is worth every penny of the £35 the Pi cost (back when you could actually buy one for £35, RIP those days).

Genuinely though, the data has been proper useful — spotted a dodgy cell in my bank months before it became a real problem just by noticing discharge curves going a bit wonky on the graph.

My setup:

  • Pi 4 2GB running Raspberry Pi OS Lite
  • VE.Direct USB cable to the SmartShunt
  • InfluxDB + Grafana stack
  • Powered off a cheap Pololu regulator straight from the 12V bus so it survives ignition cycling

The only "overkill" bit is the custom Python script I wrote to send me a Telegram alert if SOC drops below 20% — though I've started ignoring those messages like a smoke alarm low-battery beep, so maybe that part is pointless.

Anyone else gone full data goblin with theirs, or doing something simpler like SignalK on a boat setup?

DODQueen
DODQueen
Regular
92 posts
thumb_up 24 likes
Joined Jul 2023
5 days ago
#35123

@HannahDavies85 not overkill at all — it's exactly what you should be doing if you want to actually understand your system rather than just guess at it.

I ran a similar setup on my cabin for about 18 months. One thing worth adding: if you're not already doing it, pipe your data into Home Assistant alongside Grafana. The automations are genuinely useful — I had it sending me a Telegram alert if SOC dropped below 20% overnight while I was away.

Few practical tips:

  • Use a Pi UPS hat so a low-battery event doesn't corrupt your SD card mid-write
  • Consider InfluxDB retention policies early, before your database bloats
  • VE.Direct USB cable from Victron is worth buying genuine — cheap clones cause drop-outs

The NASA comparison is apt. Once you've seen your consumption patterns visualised properly, you can't go back to guessing.

Emma Edwards
Emma Edwards
Regular
63 posts
thumb_up 22 likes
Joined Nov 2023
5 days ago
#35177

Same setup here but for my cabin — Pi Zero W rather than a Pi 4, pulls plenty for just logging. One thing I'd add: make sure you've got a decent UPS or supercapacitor on the Pi itself. Lost a whole month of InfluxDB data when my Fogstar battery dipped overnight and the Pi corrupted its SD card mid-write. Painful lesson.

Also worth looking at InfluxDB retention policies early on — my database ballooned to 8GB before I noticed. Set it to downsample older data automatically and you'll thank yourself later.

@DODQueen is right that it's genuinely useful rather than gimmicky. Spotting a gradual capacity fade on my cells before they became a real problem was entirely down to the Grafana trends.

SmartSolarGuy
SmartSolarGuy
Active Member
14 posts
thumb_up 2 likes
Joined Jan 2025
5 days ago
#35200

Ran almost exactly this setup in my motorhome for two winters. The moment Grafana showed me a beautiful dip in state-of-charge every time I boiled the kettle, I genuinely understood my system better than three years of guesswork had taught me.

One thing worth adding — if you're on 12V like I was, voltage sag under load tells you more than raw SoC ever will. Log that alongside current draw and suddenly you can see your Fogstar cells starting to age before they cause any real problems.

@EmmaEdwards82 is right that a Pi Zero W handles the logging fine, but I eventually moved mine to a Pi 4 purely so I could run Node-RED alongside it for automating the charge controller — completely different rabbit hole, that one.

Worth every penny of the SD card it runs on.

Davo83
Davo83
Active Member
23 posts
thumb_up 5 likes
Joined May 2024
4 days ago
#35202

Got the same thing running in my motorhome — SmartShunt into a Pi Zero 2 W, InfluxDB, Grafana. Absolute game changer for spotting parasitic drain overnight.

One thing I'd add that nobody's mentioned: set up Grafana alerts to push to your phone when SOC drops below a threshold. Saved me once when I'd left the diesel heater fan ticking over without realising. Got the notification, jumped in, sorted it.

Also worth logging panel voltage separately if you've got a Victron MPPT — you can clearly see shading patterns across the day and it helped me reposition my roof panels for a decent efficiency gain.

Andy Robinson
Andy Robinson
Active Member
45 posts
thumb_up 15 likes
Joined Jun 2023
4 days ago
#35213

Running almost identical kit in my garden office — Pi 4 (overkill, yes, but I had one spare), SmartShunt via VE.Direct, the whole InfluxDB/Grafana stack. What nobody's mentioned yet: add a UPS HAT on the Pi itself, otherwise a low-battery event takes down your logger right when you most need the data. I use a cheap UPS HAT with a small 18650 cell, keeps the Pi alive long enough to capture the full discharge curve.

Also worth setting up Grafana alerts to ping you on Telegram when SOC drops below a threshold — saved my Fogstar batteries from a nasty deep discharge last February when I forgot the office fan heater was still running overnight.

@Davo83 — are you logging MPPT data alongside the ShuntShunt, or just the battery side? Curious how you're correlating solar input vs consumption.

Battery Tim
Battery Tim
Active Member
41 posts
thumb_up 12 likes
Joined Dec 2023
1 day ago
#35634

Pi Zero 2 W is the right call for this. @Davo83 has it. A Pi 4 pulling watts 24/7 just to babysit a ShuntShunt is daft — that's easily 3-5W you're burning constantly, which adds up fast when you're off-grid.

Mine's been running on a Zero 2 W in the shepherd's hut for 18 months. VE.Direct straight in via USB adapter, same InfluxDB/Grafana stack. No issues.

One thing nobody's mentioned — set your InfluxDB retention policy properly or you'll fill the SD card and wonder why everything's crashed. Ask me how I know.

Also use a decent card. SanDisk Endurance or Samsung Pro Endurance. Standard cards die from constant write cycles within months. Not a maybe, a when.

Overkill? No. Doing it on a Pi 4 when a Zero handles it fine? That's overkill.

Log in to join the discussion.

Log In to Reply