Shutdown with Power Button

  • Ok, I contacted you earlier in this thread regarding my PC with Libreelec on, where I wanted the power button to restart instead of shutting down. It's fixed as long as Kodi runs smoothly, but when Kodi hangs, the button doesn't work as intended. Kind regards, Thore

  • Hello!
    I have a normal Logitech Harmony 600 and a Official Microsoft MCE receiver connected to my N100 Intel LibreELEC (official): 12.0.2 (Generic.x86_64).

    nano /storage/.kodi/userdata/keymaps/keyboard.xml

    Code
    <keymap>
        <global>
            <keyboard>
                <power>Shutdown()</power>
            </keyboard>
        </global>
    </keymap>

    Variants like <power2> or Shutdown also do not work (after saving i reboot before testing).

    It still just opens the Shutdown Menu.

    What do i miss?

  • Thank you very very very much!

    LibreELEC:~ # nano /storage/.kodi/userdata/keymaps/remote.xml

    Code
    <keymap>
        <global>
            <remote>
                <power>Shutdown()</power>
                <power2>Shutdown()</power2>
            </remote>
        </global>
    </keymap>

    works like it should

  • Ok, I contacted you earlier in this thread regarding my PC with Libreelec on, where I wanted the power button to restart instead of shutting down. It's fixed as long as Kodi runs smoothly, but when Kodi hangs, the button doesn't work as intended. Kind regards, Thore

    Howdy, as Chewitt has told, since kodi is stuck it will not process any button presses, the setting thou is configured correctly because when kodi is running it will trigger the reset when the button is pressed.

    In this case maybe having a dedicated reset button connected to the motherboard would be the best choice. That way your wife can manually press the button and give the system a hard reboot without you needing to connect via ssh.