A couple of questions on the remote

Wow! you are right, the test that you indicated fails, but I believe that this is a Kodi/LibCEC bug, not a TV problem. I’m telling this because, the TV still sends the CEC volume commands to the receiver just fine. It is just Kodi that can’t receive CEC anymore.

Actually I restarted kodi from command line with:

sudo systemctl restart mediacenter

and then the CEC connection with the TV is restored and the TV remote can command kodi, without actually rebooting the TV…

Oh, so close… It is not perfect and there are a couple of cases that I need to debug, but I 99% achieved what I wanted.

first I changed this line in .kodi/userdata/peripheral_data/cec_CEC_Adapter.xml:

<setting id="standby_pc_on_tv_standby" value="13011" />

with this, turning off the TV with the TV remote control puts the Vero in standby (led red).
Then with Kodi callbacks, I intercept this event (from the kodi log) and force immediately a screensaver and then a CECStandby command
I also changed the “soft button” in kodi to ‘suspend()’. In this way, no matter how I shutdown the system (TV remote or soft button in Kodi) I end up in the same state (standby and screensaver)

When I press any button from the remote, screensaver is exited and I use callbacks to generate a “RestartApp” command. This restarts kodi and restores the CEC connection with the TV so the TV remote works on kodi.

While trying this I found a case in which the TV would turn on but kodi was still in screensaver mode, I need to look into it, but I think this hack will do until long press is available.

Thanks for all the help!

1 Like

After some testing, I found that even though Kodi debug log shows that a key ends up executing “ActivateWindow(Home)”, it doesn’t always work.

If you are on a screen that is like what GUI designers call a “modal dialog”, then jumping out to another window doesn’t work. Pages like the “Info” on a movie, or the shortcut editor for the home screen are examples where it doesn’t work. In some cases, once you back out of the page normally (using the “Back” or “OK” button), you are returned to the home screen instead of the previous screen, like the home screen was activated in the background.

Thanks for clarifying. That definitely explains the recent change in behaviour.

Do I understand what you achieved correctly?

  1. Using a button on the Vero 4K remote, you can now call a CEC command to put the connected devices (receiver, which is connected to TV) in standby.
  2. Not only that, but you put your Vero in screensaver/standby mode and stop the mediacenter/Kodi process.
  3. If another remote like the TV remote is used to put the TV in standby, you catch that and put the Vero in screensaver/standby mode and stop the mediacenter/Kodi.
  4. When your remote activates Vero, you start the mediacenter service again.

All I want is to map the Vero 4K remote home button to turn off the TV. In my case, I now use the TV remote to do that, which automatically puts my receiver in stand by (Vero—hdmi in—receiver—hdmi out—tv).

It seems you are able to do so, and even disable the mediacenter service. I don’t need the latter, because I need Kodi to accept library update events from Flexget. But the former, how did you achieve that exactly?

Hi Sam,

Do you have an update on the longpress support for the vero 4k remote?

Thanks,
Bernard

Not at this time

Sam

I also would be really happy if an "extended shutdown options " could be added.

In an options menu just enable/disable if TV and/or receiver should be shutdown when Vero shutdown/standby option is selected (or when it’s switched on, though I personally would only use those to switch off, not to switch on). I can’t suggests if it should/could be added/implemented trough MyOSMC or by another means.

The knowledge and the CEC code is already there it’s just about giving it some shape. I see it as really practical value added feature.