Adventures In Consumer Electronics Control (CEC)

[Valkyrie-MT] was frustrated by the inability to control TrueHD audio volume from his computer. That’s because digital audio passes through the cable to the receiver where the volume adjustments are done. This meant that his RF computer remote was no good because the receiver uses an IR remote. He set out to find a way to get around this and ended up working with the Consumer Electronics Control (CEC) protocol.

The CEC protocol is a 1-wire serial bus built into the HDMI standard. The solution he settled up required one solder connection on the motherboard as well as the internal USB translator module seen above. That translator box, called the RainShadow, is a PIC 18F87J50 controlled board that translates incoming commands from the USB connection and sends them out as CEC hex codes. A bit of code writing and [Valkyrie-MT] is in business. You can see in the video after the break that it’s not just controlling audio, he can now control the entire entertainment center including turning on the TV and setting it to the appropriate input.

[youtube=http://www.youtube.com/watch?v=kE47CxD5xrQ]

15 thoughts on “Adventures In Consumer Electronics Control (CEC)

  1. Does anyone have a good source for cec hex codes? I built something like this last year to control a one-off video display for a client. I had to sniff codes off a bluray player. It took forever doing trial and error.

  2. Apologies accepted Rogan. Yes it was a combined effort. The Rainshadow HDMI-USB Bridge is a solid device. It does all the hard work here reading the CEC bus. I just wrote the software to work with the Media Center Remote Control and “hacked it” by installing it in the computer. But you don’t have to put it inside the computer like I did. It works perfectly fine by plugging it in to any available HDMI port like in an AV receiver or TV. It works because the CEC pin in HDMI is a bus, which means that they are all connected, so you should be able to plug in the bridge almost anywhere.

    At this point, it’s been in use on my primary TV/Media Center for months and it works great. My wife doesn’t even know she is using it. Everything just works together “magically”. There are a ton of other features that can be implemented in the software, but I just have not gotten around to it…

    Thanks to everyone for all the positive feedback.

    -Valkyrie-MT

Leave a Reply

Please be kind and respectful to help make the comments section excellent. (Comment Policy)

This site uses Akismet to reduce spam. Learn how your comment data is processed.