Reboot Raspberry Pi 4 when turning TV off via HDMI-CEC using Samsung TV Remote

  • I've been using LibreELEC 9.02 on a RPi 4 with no significant problems-it's actually amazingly good-except for an occasional loss of full remote control of the Pi. This requires SSHing into the Pi and rebooting-so the Pi is still running. I plan on running the Pi at full power, but would like to use the Samsung TV remote to reboot the Pi when the TV is turned off. I've tried various CEC settings, but find it difficult to understand what each does. Is it possible to reboot the Pi via CEC when turning off the TV?

    Some additional information, I can turn the Pi off with the following changes to the default settings: settings->system->input->peripherals->CEC Adapter->"Devices to power off during shutdown"="Amplifier/AVR device"="When the TV is switched off"->Shutdown. I've tried all the other "When the TV is switched off" settings with no luck. A control signal is getting to the Pi, but I'd like to reboot not shutdown.

    Edited once, last by TomHardy1975 (October 2, 2019 at 6:29 PM).

  • I am having a related problem with my first LibreELEC installation... a Pi 4B with a UN7000 series Samsung TV connected through a Denon AV receiver.

    Enabling Samsung's Anynet+ is required to turn on CEC for the television. There is also a TV configuration setting, which I have enabled for 'Power Off' over CEC.

    LibreELEC navigation works well with the TV remote, so communication appears to work... with the exception that LibreELEC does not shut down as the TV is powered off.

    This creates problems since there are multiple devices connected to the AV receiver. I use a Logitech remote that configures and controls the TV, AV receiver, and devices. Things are fine as long is everything is off to start with. If not, Anynet+ will attempt to find and connect any CEC enabled interfaces that are active (trying to reconfigure the TV and AV inputs) once the TV is turned on. That means nothing else works as long as the Pi 4B is on.

    Manually shutting down LibreELEC does not resolve the problem, apparently the HDMI interface is still active. While I am not familiar with the protocol, I assume that 'power off system' would place the HDMI interface into a standby state where it would only respond to a CEC request to power on. It is in fact necessary to manually disconnect power from the Pi 4B to avoid this Anynet+ reconfiguration.

    Am I missing some configuration?

    I have ordered a Kodi remote with dongle for now. However, I have other devices attached to the TV and AV receiver that use CEC.