Quote:
Originally Posted by Sunset
OP - You don't seem too concerned over losing power for an extended time, so I guess no worries if the place is without electricity for a week ?
Since power outages don't seem to bother you, I'm wondering why you want to know how many and how long ?
|
I have perhaps miscommunicated somewhere along the way then --- I am definitely concerned about losing power for an extended time. Logging over a couple of winters will give me a better sense for what I need to be prepared for.
Quote:
However, in the spirit of the thought, here is one idea and can use any old computer (or I guess a PI).
One simple thing would be a cheap old computer, and write a simple script to output to a file each day every X minutes.
When the computer goes off, and turns back on, it would write a special file name so you know it restarted just by the file name. It write a line into each file while logging giving the time, so when a file stops having entries you know the time it stopped.
The "Started Up" file would flag where to look for a power failure time.
Personally I'd have it write a new directory each month, and put all the files for that month in that directory. (Later if keen , one would write a script to parse the directories and summarize the power status per month).
The files would look like this:
Started Up 2022-12-10 12-02-42.txt --- computer started up
Logging Up Time 2022-12-10 12-02-42.txt --- now is logging to file each minute after starting
Logging Up Time 2022-12-11 00-00-01.txt --- continuing to log next day
Logging Up Time 2022-12-12 00-00-01.txt --- continuing to log next day
Logging Up Time 2022-12-13 00-00-01.txt --- continuing to log next day and power failure hits
Started Up 2022-12-13 05-22-33.txt --- computer started up few hours later
Logging Up Time 2022-12-13 05-22-33.txt --- now is logging to file each minute after starting
etc..
|
Right, an old computer or pi or arduino could do this, just need your script/program to automatically execute on device startup.
I don't have an old computer laying around, however, nor am I keen to dedicate the space in a small cabin to something like that, and it's now starting to seem like quite a project for a limited use case. I guess if I were to go this route I might get a "mini PC" (such can be had for under $200) --- connect up with any sort of keyboard and mouse but I would want some sort of screen for this to check status and deal with any issues --- hmm, maybe a tablet could be used as a temporary display device ... this route is still an option I guess.
I started this thread with the tenuous hope of getting some other idea(s) for just an outage logging approach that would fit my situation (and fit my personal biases and limits
). Along the way, thanks to some great input, I'm now thinking about incrementally building up a modest remote access approach that can do multiple things for me. Lots of moving parts to all of this. And I'm sure that with an unlimited budget I could come up with something amazing (and disproportunate), but I am looking to keep both up-front and monthly costs down to something I can comfortable sell to my wife !