*** This document is based on docbender's work (based on Arduino), full credit to him. *** Control Onkyo devices is possible among others through Remote Interactive port. This port is normally used for direct communication between two Onkyo devices (ex. receiver and CD player). But why not turn on the receiver automatically when you start your own player?
This is based on docbender's work: Onkyo-RI library.
Thanks a lot to zatrax for helping me in converting docbender's Onkyo-RI to using WiringPi instead of the Arduino library. A makefile has also been created for compiling the code with g++. Please compile on your Raspberry pi using the makefile (modify to your taste). Please also modify the main.cpp to the code you want to send.
Please be sure to have WiringPi installed: http://wiringpi.com
To connect to the RI port is used 3.5mm mono jack. Tip is for data signal and sleeve is ground (GND). Data are sent via TTL logic. So it is easy to connect RI device to 3.3v serial (RPi). Just connect data signal to some output pin and connect GND between each other.
Protocol description could be found at:
or with grafical representation at:
Protocol is pretty simple for implementation. In one message is transfered 12 bit code. This code represents action for target device. Most significant bit is send first.
- blocking - send() method blocks other program execution until whole command is sent. It takes up to 61 ms.
Codes are valid for TX-8020 receiver. With a high probability it will work with other Onkyo receivers.
Action | Command | Notes |
Input CD | 0x20 | Switch input to CD channel |
Turn On + CD | 0x2F | Turn on receiver and select CD as input channel |
Input TAPE | 0x70 | Switch input to TAPE channel |
Turn On + TAPE | 0x7F | Turn on receiver and select TAPE as input channel |
Input BD/DVD | 0x120 | Switch input to BD/DVD channel |
Turn On + BD/DVD | 0x12F | Turn on receiver and select BD/DVD as input channel |
Input DOCK | 0x170 | Switch input to DOCK channel |
Turn On + DOCK | 0x17F | Turn on receiver and select DOCK as input channel |
Dimmer Hi | 0x2B0 | Set dimmer brightness to highest level |
Dimmer Mid | 0x2B1 | Set dimmer brightness to mid level |
Dimmer Lo | 0x2B2 | Set dimmer brightness to lowest level |
Dimmer Hi | 0x2B8 | Set dimmer brightness to highest level |
Dimmer Lo | 0x2BF | Set dimmer brightness to lowest level |
Turn Off | 0x420 | Turn off(set into standby) receiver |
Test mode | 0x421 - 0x424 | Some kind of test modes. Leave test mode is possible by code 0x420 (Turn Off). Test modes provides clear of receiver setting. |
Radio search next | 0x430 | Tune next radio station when radio is selected. |
Radio search previous | 0x431 | Tune previous radio station when radio is selected. |
Radio Stereo/Mono | 0x432 | Switch between Stereo and Mono when FM radio is selected. |
Radio station next | 0x433 | Jump to next stored radio station when radio is selected. |
Radio station previous | 0x434 | Jump to previous stored radio station when radio is selected. |