RPi - Acting as an IR receiver, translator, emitter

Okay, more of a general RPi question here, but since you have all been so helpful in the past and are more media oriented, I am hoping someone has come up with a solution to this issue.

Long story short, I am in the process of a sports bar build out in my mancave. Part of this includes 4 TVs, all of which are being driven by a RPi running OSMC. The TVs are basically one large one, flanked by 3 smaller sets (all of the same brand model).

Issue I am running into is that there is no way to use my Logitech Harmony 665 to uniquely control the three smaller TVs that are of the same brand/model (I want to go this way so everything looks nice and seamless). If I power one of them on, they all turn on etc.

I have been building my own IR receivers on the Pi’s using the GPIO on the Pis to create custom remote profiles which are controlled from the Harmony remote. I know I can create an IR blaster using similar methods to get the Pi to send IR Commands.

My question is this: Is there any way to essentially “translate” IR input signals to a different IR output signal. For simplicities sake, say can I program my Harmony remote to control three different make/model tvs, then have the Pi receive these IR commands, translate them to the appropriate ones for the identical tvs and then output the correct IR code to the blaster LED which would be taped over each TV’s IR input area. In this way, it would be like pressing the original remote right up against each TV when sending commands via IR.

Does this make sense, any ideas for those who may have tried something similar?

I think if I was going to tackle this problem I would approach it slightly different way. I think I would use IR eyes that were visible so they could all take a ir command like power from just a basic remote. For control I think I would lower the signal to the LED’s so you could trigger on one TV without it being bright enough to bleed over to the other TV’s. I would then find/build a switch that would cycle through the LED’s connected to a single GPIO connection. It seems to me that having redundant controls on the remote would just turn into a royal pain in the butt. If this switch was built such that it could take an ir command then it would be possible to setup scripts on the harmony so it send a command, switch ir, send a command, switch ir, etc.

all take a ir command like power from just a basic remote.

What do you mean by this? Why would I use a basic remote? The basic remotes for the TV would be all the same since they are all the same make model. Pressing a button on that remote would control all 3 tvs.

Or are you saying the “switch” proposed here would essentially handle routing that remote’s output to the appropriate IR led that is blocking the IR receiver on each TV?

Something to add: each TV will have its own unique Pi. In my idea, each Pi would be responsible for receiving and translating each IR command for its own TV.

Another Idea: Can CEC control the functions of the TV when the Pi running OSMC is not the input that is displaying? Ie: if I am hooked up to basic cable (no STB), will the CEC function to control the TV tuner changing channel UP/Down etc?

Keeping in mind that i’m just spitballing from what I think your trying to accomplish. I was thinking if you use those ir transmitters that stick over the top of an ir port that have the ability to both send signals but are translucent enough to take an external signal, as opposed to blocking the TV’s IR. The thought being that you send a ‘power on/off’ command with a remote then all tv’s pick it up without involving the other control system (to keep things simple). These might bleed off and if so you should be able to use a dropping resistor to keep commands strong enough to trigger the TV they are attached to, but not strong enough for them to signal the other TV’s.

I didn’t flesh out in my head how your control system would work on the Pi side but my thought is that you have two options. You have either a way to switch what is receiving the commands and have single '‘device’ in harmony, or you have different devices on the harmony and deal with separating things on the Pi side. My thought was to get to where the harmony profile basically just had a single command to switch what was receiving the commands as opposed to having to keep hitting ‘device’, selecting the ‘device’ and then rinse and repeat every time you wanted to change what TV your messing with.

Are you planning on playing from the Pi’s exclusively? I had assuming you were planning on setting up some kind of a control system on a Pi to be able to tune in the TV for OTA as well. I think the details of the constraints you are going to operate in would be necessary.


Now keeping in mind that i’m just throwing ideas out here, perhaps you could scrape the IR control entirely. If you could get a system where you were doing a PVR on the Pi for your cable then you could just use a web browser or iOS/Android app to switch around your video.

Having said all that I would hope you already looked for a commercial solution. I would assume there is some kind of solution that most sports bars are already using.

So I’d say about 90% off the Pi’s exclusively (or via IPTV, YT TV, PS Vue etc) through Kodi. I do have a FiOS subscription and will pick up basic cable channels without the need for a cable box. Realistically, I’d only ever use the built in TV tuners for maybe Fox, CBS, NBC, ABC.

There are commercial solutions out there Crestron etc, but are super expensive and really not practical considering this is a bonus room/mancave project. The closest solution I had found was the Harmony Hub/Elite remotes, but these still only use 2 IR blasters. I’d need 3. I also absolutely hate the harmony elite remotes. I was being hopeful here that someone might have DIY’d one of the commercial offerings here.

I think scrapping IR is ultimately going to be the way to go. Some of the LG Tvs and other Smart TVs use magic/non-IR remotes that can be paired with their own TV. I was originally avoiding these TVs as they are obviously more $$.

I did find out some more info that some basic functionality might be accomplished using CEC, but it does not seem straightforward and seems to be a huge amount of trial/error to get things to maybe work. I am going to be doing some digging into LibCEC and CEC-O-MATIC and see if I can get a POC working for controlling TV Input, Channels, Power via CEC.

I would probably slap something like a HDHomeRun on my network and keep everything inside Kodi. You wouldn’t need an IR solution as the only thing you would be controlling on the TV’s is power on/off.

This forum is fairly focused, and primarily support based. I’ve never hung out there but I would think this would be more in line with a place like avsforum.

I highly doubt this is going to lead to anything but a dead end. I have limited CEC knowledge but I think you will find that almost all TV’s have a very limited set of commands that they will accept from a connected device. I think support for TV’s receiving much more than power and input is sparse (volume is hit and miss). The manufacturers seem to have mainly stuck with a TV controls your other devices and not the other way around approach.

If you hadn’t already I would check out some Kodi app remotes and maybe a couple of the web interfaces (the differences there are more than visual).

This would be a much more elegant way to go IF the TVs actually support the commands you want to send them. CEC seems to be a snake pit, though.

I have been waiting for the PRIME 6 for this reason and because the PRIME 6 will supposedly support DRM channels. This is my holy grail, but until SD actually announce a release date I am trying to figure out alternative ways.

Regarding use of the TVs, in reality, the only time I anticipate having to utilize all TVs at once will be during March Madness. Other times in the year, I can only envision using one or two of these satellite TVs at a time. From this exercise it seems that there might not be a practical way to do something like I desire in the DIY/cheap world. The small inconvenience of having to be more directional with my remote I guess will just be a reality of this setup if I want to have all of the TVs be identical.

This is a great idea, thanks! Ill do some searching over there too.

Did some experimenting with my LG tv (bedroom) and RPi which is currently running OSMC, and you are both right. The support for commands back to the TV from the Pi is atrocious and while I could get the TV to acknowledge the commands, in reality they did not do anything practical (change channel, change input, power off). I think CEC in this regard is a dead end.

1 Like