CEC-like Power Features with Non-CEC-Equipment
With a Raspberry Pico, I monitor my Sony amplifier from the 90s and my 2013 Dell monitor, and switch on my NUC-based media center if any of these devices are switched on. This is comparable to the CEC functionality that more modern devices provide via the HDMI port. I also utilize the USB/serial interface of the Pico to check if any of the two devices is still on to include this into my auto-shutdown script logic.
As a result, my media center boots up as soon as I switch on my amplifier or my monitor, and only auto-shuts down if both are off.
Continue reading “CEC-like Power Features with Non-CEC-Equipment”
Media Center Auto Shutdown and RTC Wakeup Based on tvheadend Recording Schedule
I created a script that runs via cron job that will power off my media center if it is not in use, but will program the real time clock (RTC) on the motherboard to wake up the system in time to run a scheduled recording, and/or to update the EPG data, and from that derive potential new or changed auto-recordings. To determine if the system is currently not in use, I
- Check if the monitor is off
- Check if any audio is playing, e.g., Spotify or KODI is playing anything
- Check if the wireless keyboard is connected
- Check if tvheadend is currently recording something
Also, the shutdown processing can be blocked by creating a flag file. If that file exists, no shutdown will happen.
The wake-up time is either the next recording time plus some allowance for boot time, or every 24 hours, whatever comes first. This makes sure that at least once a day the EPG is updated and tvheadend can update its auto-recording-schedule.
As a result, I reduce power consumption of the media center considerably.
Continue reading “Media Center Auto Shutdown and RTC Wakeup Based on tvheadend Recording Schedule”