If you have not already, we suggest setting your Plex username to something else rather than email which is displayed on your posts in forum. You can change the username at https://app.plex.tv/desktop#!/account
Welcome to our forums! Please take a few moments to read through our Community Guidelines (also conveniently linked in the header at the top of each page). There, you'll find guidelines on conduct, tips on getting the help you may be searching for, and more!

Keymap.xml to perform CEC-Client function

kooadminkooadmin Posts: 5Members, Plex Pass Plex Pass
edited September 2016 in Rasplex

Hi, I have seen many posts about the keymapping for remote.xml however I am trying to control the CEC-Client (Pulse Eight) in RasPlex from the Keymap.xml remap file. So rather than the CEC-Client receiving the signals it would be sending them and this would enable me to use a Flirc receiver to use a non programmable remote of my choice (QNAP RM-IR002) for both navigating Plex and controlling the TV (Samsung) and volume (Onkyo TX L-50).

I can successfully turn on and off the TV with these commands in SSH:
echo "on 0" | cec-client -s
echo "standby 0" | cec-client -s

I had a wild unsuccessful stab at this Keyboard.xml keymap with t and v as arbitrary letters that i could later program in Flirc to buttons, w and g were simply put in to prove my .xml file was working:

file1

Results - w and g were remapped correctly and worked, t and v however had no effect.

In this article ( http://kodi.wiki/view/Keyboard.xml ) in section 6.2 Functions, were the following functions:
CECActivateSource - Wake up playing device via a CEC peripheral v13 Addition
CECStandby - Put playing device on standby via a CEC peripheral v13 Addition
CECToggleState - Toggle state of playing device via a CEC peripheral v13 Addition
these looked promising so i tried the following keyboard.xml remap:

file 2

Unfortunately t and v again had no effect.

If there is anyone that has any advice on how to remap the Keyboard.xml file to utilise the CEC-Client in Rasplex to control the tv and receiver I would really appreciate the guidance. The best case would be a toggle function like Kodi seems to have above however i could possibly work around separate buttons using a Longpress in Flirc if i had to. Unfortunately I am not familiar with how to debug as i am really new to this however i am sure there are tutorials on this and i will learn if it is required.

Thanks for any help

Answers

  • kooadminkooadmin Posts: 5Members, Plex Pass Plex Pass

    http://forum.kodi.tv/showthread.php?tid=136130

    Kornhole was onto something here in xmbc as a work around a few years ago but i cant see any solution since. In this way activating the screen saver would turn off the tv and any button on the controller would wake it if you were to make the CEC settings right.

    I really hope i am missing something here but after literally days of searching it seems there is no simple way to control the CEC-Client in Plex even though it obviously easily has the capacity to, an example of this is if you select the screensaver preview in the preferences menu it does exactly what i want but there seems to be no way to get this to happen on command through a keyboard.xml file.

    It blows my mind that this seems to be such a useful yet unobtainable (please prove me wrong) thing to do.

  • jpaytoncfdjpaytoncfd Posts: 63Members, Plex Pass Plex Pass

    I know this is old but I am trying to do the same thing. Your 2 commands can be put into bash files and then you can map the keys to run those files. I need to figure out the command for toggle.

Sign In or Register to comment.