Thanks for the quick reply @ccoupe . So I take it you are also recommending Ubuntu as the OS on the RPi? Would it work on the full version (albeit vanilla) Rasbian?
No. Use Raspbian (Raspberry OS is the new name). It is close enough to ubuntu that the instructions should work (when prefixed with sudo
as needed) I would use Raspberry OS 64 bit for a new install. Older instructions will work except for some older video camera information
Ok, thanks a bunch! Really appreciate your help!
After looking into implementing NUT, came to the conclusion that it was indeed “nuts” for a new linux person (me) to try and configure it. Ended up going with a very simple solution similar to the one I use for my Hubitat Hub.
I wired a normally open miniature relay with a 5vdc coil so it would be activated (closed) when powered by a USB power adapter providing 5vdc plugged into a Zigbee power outlet plug. The Sonoff Zigbee power outlet plug is plugged into my UPS (as is my Hubitat Hub and my RPi400). When mains power goes out (sensed by Ring Extender), Hubitat RM rule starts a timer (time based on estimated runtime determined by past experience) which after a delay (in my case about 20 minutes based on my UPS), powers on the Zibgee outlet momentarily inching the relay closed. This momentarily connects GPIO3 on the RPi to ground, thus initiating a soft (and safe) shutdown of the RPi. Hubitat also sends out a Pushover Notification and then performs a soft shutdown of the Hubitat Hub, hopefully preventing data corruption on the Hub and RPi. If the power outage is long enough such that the UPS also loses power, when power is restored, Hubitat and the RPi automatically restart.
After trying to do all this utilizing software and power monitoring of my UPS via NUT, APCUPSD, etc, I went “old school” and rigged up a simple relay. Tested it out by throwing the breaker to where the Ring Extender and UPS are plugged in an everything seems to work. Did not know if there would be any interest in this so did not post any pics to keep this post short. Let me know if anyone wants me to post pics and I can add some pics of the device I made for my RPi400. Thanks BTW to all that tried to patiently help me out with USB monitoring, etc. though. It was greatly appreciated.
I have a theory why all the NUT guides are incomplete. By the time someone gets it working they no longer care enough about it to fix the guide. And the person who wrote the guide stop working on it years ago.