Jump to content

irTrans remote in linux?


Recommended Posts

Does anyone have irTrans working in linux for Emby Theater?


I have a living room htpc running emby server in a Zalman HD160 case that has IrTrans receiver remote built into it.


IrTrans with the MCE remote has worked well for me in Windows 7 Media Center and Emby Media Center Classic, but it is time to retire Win7 MCE. IrTrans and the remote does work for Emby Theater for Windows, but I'm trying to avoid Win 10 bloat and its random rebooting for forced upgrades. 


So I'd like to shift to a Ubuntu htpc using Emby Theater to replace MCE in the living room, then possibly Docker after I get things debugged. Biggest stumbling block so far has been getting irTrans and the MCE remote to work in Emby Theater for linux.


I downloaded the linux IrTrans drivers and installed them. Irtrans' irserver works in test mode, recognizing the MCE remote button presses. I then installed it as a service and made sure it starts. 


I configured a apps.cfg [*] section to translate buttons to keypress for emby-theater, as I had done in windows and as suggested elsewhere here. However, it does not work; no keypresses seem to be forwarded to the emby-server process [of which there are many]. File permissions on apps.cfg are set to a+r, so that shouldn't be the issue.


Any chance anyone can help solve this Ubuntu/irTrans/remote issue? 

Edited by trmb
Link to comment
Share on other sites

Hi, that might be tricky as the process that should receive the keypress is actually the electron process that theater launches.


But why do you have to configure the process? Can't it just send it to whatever window currently has focus?

Link to comment
Share on other sites

I am attempting to use irtrans to forward the keypresses to any process [App]* but apparently the button presses [which are recognized] aren't being translated into keypresses at all. 


What I am wondering is if I am missing something about how irtrans should be generating keypresses in ubuntu, ie "Do I need to be configuring LIRC somehow?"


Details: I run irserver as follows:

sudo /usr/local/irtrans/irserver64 -loglevel 4 -codedump -debug_code -daemon /dev/ttyUSB0

The irserver.log looks like this: 

Init Server Socket done
IRServer64 Version 6.10.23
Init Events done
Opening Device: /dev/ttyUSB0
IRTRans Send Done: 1
Name   : 
Version: D5.03.08
FW SNo : 15768
Capab  : Power On; 
FW Cap : 0x3c8019
Node   : /dev/ttyUSB0

Init communication ...
[ 0]:                      D5.03.08     SN: 15768
Chdir to DB OK
Read routing OK
Read Switches OK
Open DIR: 0
Get Dirent: 272
Remote mce-keyboard         compiled:     1 Timings -     77 Commands
Remote mediacenter          compiled:     1 Timings -     49 Commands
Remote mce-mouse            compiled:     1 Timings -      1 Commands
Get Dirent: 0
Total:   3 Remotes  -   3 Timings -  127 Commands -    0 Calib. Commands
         0 Togglec. -   0 CCF Data -   0 CCF RAW  -    0 CCF Error
IRTRans Send status: 0 - 0  SEQ:122  TO:500
IRTRans Send status: 1 - 69  SEQ:122  TO:500
IRTRans Send Done: 3
IRTRans Send Done: 1
Select Return: 1
[0.0] up mediacenter
Select Return: 1
[0.0] down mediacenter
Select Return: 1
[0.0] left mediacenter
Select Return: 1
[0.0] 2 mediacenter
Select Return: 1
[0.0] 3 mediacenter
Select Return: 1
[0.0] 6 mediacenter
Select Return: 1
[0.0] 9 mediacenter
Select Return: 1
[0.0] 5 mediacenter
Select Return: 0

So, I can see that my remote [.rem] files are being read and the button presses are understood by irtrans. What I don't have working or understand is the next step, getting those button presses translated into keypresses. 


On Windows this is configured by the apps.cfg file--and apparently for linux too looking into the kodi/xmbc info in the sample linux apps.cfg. Here is my apps.cfg file:

    1        [KEY]1
    2        [KEY]2[KEY]a[KEY]b[KEY]c
    3        [KEY]3[KEY]d[KEY]e[KEY]f
    4        [KEY]4[KEY]g[KEY]h[KEY]i
    5        [KEY]5[KEY]j[KEY]k[KEY]l
    6        [KEY]6[KEY]m[KEY]n[KEY]o
    7        [KEY]7[KEY]p[KEY]q[KEY]r[KEY]s
    8        [KEY]8[KEY]t[KEY]u[KEY]v
    9        [KEY]9[KEY]w[KEY]x[KEY]y[KEY]z
    0        [KEY]0[KEY]\SPACE
    OK       [KEY]\ENTER
    LEFT     [KEY]\LEFT
    DOWN     [KEY]\DOWN
    UP       [KEY]\UP
    INFO     [KEY]\CTRLD
    REC      [KEY]

    FWD      [KEY]
    REW      [KEY]
    MUTE     [KEY]\F8
    RECTV    [KEY]
    EPG      [KEY]
    LIVETV   [KEY]
    RED      [KEY]\ALT1
    BLUE     [KEY]\ALT\CTRL2



That's a simplified version of the same apps.cfg I use successfully in win 7 for emby-theater.


What I am wondering is if I am missing something about how irtrans should be generating keypresses in ubuntu, ie "Do I need to be configuring LIRC somehow?"

Edited by trmb
Link to comment
Share on other sites


Sorry I never used irTrans and as for Lirc that I been under SageTV with USB-UIRT or Hauppauge IR but with Emby with my Phone a Unified Remote and it been some being that Emby Theater had issuse with playback 

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Create New...