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?
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 5V MCU (Arduino). Just connect data signal to some output pin and connect GND between each other. In case of stereo jack, connect tip to DATA, sleeve and ring to GND.
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.
There are two Onkyo-RI library:
- blocking - send() method blocks other program execution until whole command is sent. It takes up to 61 ms.
- non-blocking - send() method only start command sending. The execution is handled by processing() function. This function must be called periodically with maximum 1 ms period. Function return bool value about sending status (true - data is being sent, false - nothing to sent/sending is done). Before the command is completely sent other functions can be executed. Library use internaly Arduino micros() function, so no other timer is not blocked.
At mentioned sites are also listed codes for Onkyo devices. Unfortunnately none of the codes is not valid for my receiver TX-8020. To determine the valid codes I wrote a simple loop for Arduino (more below) that goes through the whole 12bit code range (0x0-0xFFF). Results are listed below commands.
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. |
Thanks to lonejeeper
Action | Command | Notes |
Input CD | 0x20 | Switch input to CD channel |
Input TAPE | 0x70 | Switch input to TAPE channel |
Input BD/DVD | 0x120 | Switch input to BD/DVD channel |
Input HDD | 0x170 | Switch input to HDD channel |
Input Video2 | 0x1A0 | Switch input to Video2 channel |
Vol Up | 0x1A2 | Volume Up |
Vol Down | 0x1A3 | Volume Down |
Mute | 0x1A4 | Mute |
Power OFF | 0x1AE | Power OFF |
Power ON | 0x1AF | Power ON |
Dim | 0x2B0 | Set dimmer brightness to highest level |
Dimer | 0x2B1 | Set dimmer brightness to mid level |
Dimmest | 0x2B2 | Set dimmer brightness to lowest level |
Dimmer Daytime | 0x2B8 | Set daytime brightness |
Dimmer Nighttime | 0x2BF | Set nighttime brightness |
Test mode | 0x421 - 0x423, 0x430 | RDS TEST |
Thanks to wongcz
Action | Command | Notes |
Input Aux | 0x20 | Switch input to AUX channel |
Turn ON + AUX | 0x2F | Turn ON receiver and select AUX as input channel |
Input TV(/CD) | 0x70 | Switch input to TV(/CD) channel |
Turn ON + input TV(/CD) | 0x7F | Turn ON receiver and select TV(/CD) as input channel |
Input BD/DVD | 0x120 | Switch input to BD/DVD channel |
Turn ON + input BD/DVD | 0x12F | Turn ON receiver and select BD/DVD as input channel |
Turn ON + input DOCK | 0x17F | Turn ON receiver and select DOCK as input channel |
Dim | 0x2B0 | Set dimmer brightness to highest level |
Dimer | 0x2B1 | Set dimmer brightness to mid level |
Dimmest | 0x2B2 | Set dimmer brightness to lowest level |
Dimmer Daytime | 0x2B8 | Set daytime brightness |
Dimmer Nighttime | 0x2BF | Set nighttime brightness |
Test mode | 0x421 - 0x423, 0x430 | RDS TEST |
Thanks to ogrady
Action | Command | Notes |
Input TV/CD | 0x20 | Switch input to TV/CD channel |
Input BD/DVD | 0x120 | Switch input to BD/DVD channel |
Dim | 0x2B0 | Set dimmer brightness to highest level |
Dimer | 0x2B1 | Set dimmer brightness to mid level |
Dimmest | 0x2B2 | Set dimmer brightness to lowest level |
Test mode set | 0x421 - 0x424 | Test 1-00,2-00,3-00,4-00 |
Test | 0x425 | Test x-01 |
Test | 0x426 | Test x-02 |
Test | 0x427 | WiFi test |
Test | 0x428 | Route test |
Test | 0x42a | Key Test Mode |
Test | 0x42b | Test x-07 |
Test | 0x42c | Test x-08 |
Test | 0x42d | Test x-09 |
Test | 0x42e | Test x-00 |
Test mode set | 0x43e | Test 5-00 |
Test | 0x43f | CEC test |
Thanks to kelvinlaw
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 Video3 | 0x1A0 | Switch input to Video3 channel |
Turn On + Input Video3 | 0x1AF | Turn ON receiver and select Video3 as input channel |
Power Off | 0x1AE | Power OFF (only works if you are currently in Video 3!!) |
Thanks to jimtng
Action | Command | Notes |
Input Video3 | 0x1A0 | Switch input to Video3 channel |
Vol Up | 0x1A2 | Volume Up (only when input is set to Video 3) |
Vol Down | 0x1A3 | Volume Down (only when input is set to Video 3) |
Mute | 0x1A4 | Mute (only when input is set to Video 3) |
Unmute | 0x1A5 | Unmute (only when input is set to Video 3) |
Power Off | 0x1AE | Power OFF (only works if you are currently in Video 3!!) |
Turn On + Input Video3 | 0x1AF | Turn ON receiver and select Video3 as input channel |
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 DVD | 0x120 | Switch input to DVD channel |
Turn On + DVD | 0x12F | Turn ON receiver and select DVD as input channel |
Input GAME/TV | 0x1A0 | Switch input to GAME/TV channel |
Vol Up | 0x1A2 | Volume Up (only when input is set to GAME/TV) |
Vol Down | 0x1A3 | Volume Down (only when input is set to GAME/TV) |
Mute | 0x1A4 | Mute (only when input is set to GAME/TV) |
Unmute | 0x1A5 | Unmute (only when input is set to GAME/TV) |
Power Off | 0x1AE | Power OFF (only when input is set to GAME/TV) |
Turn On + GAME/TV | 0x1AF | Turn ON receiver and select GAME/TV as input channel |
Setup | 0x420-0x424 | Displayed: SETUP. Playing loud noisy sounds |
CEC test | 0x43E | Displayed: CEC TEST OK |
TEST 5-00 | 0x43F | Displayed: TEST 5-00 |
Action | Command | Notes |
Volume + | 0x2 | See notes on volume |
Volume - | 0x3 | See notes on volume |
Power On/Power Off | 0x4 | The receiver actually enters/exits standby since the only way to properly shut it down is through the power switch located on the front of the receiver itself. |
Mute | 0x5 | |
Input Aux/Video | 0x6 | |
Input Tape-2 Monitor | 0x7 | |
Input Tape-1/DAT | 0x8 | Alternative code: 0x70. |
Input CD | 0x9 | Alternative code: 0x20. |
Input Phono | 0xA | Alternative code: 0x30. |
Input Tuner | 0xB | Alternative code: 0xE0. |
Source direct | 0x13 | |
OFF | 0xEA | This code will switch the receiver into stanby mode, but it will not switch it back on. |
Thanks to Aaron G
Action | Command | Notes |
Vol Up | 0x2 | Volume Up |
Vol Down | 0x3 | Volume Down |
Turn ON/OFF | 0x4 | Turn receiver ON and OFF |
Mute/Unmute | 0x5 | Toggle Mute |
Input Line 1 | 0x20 | Select Line 1 as input channel |
Turn ON + Input Line 1 | 0x2F | Turn ON and select Line 1 as input channel |
Input Next | 0xD5 | Select next input channel |
Input Prev | 0xD6 | Select previous input channel |
Mute | 0xD7 | Mute |
Unmute | 0xD8 | Unmute |
Turn ON | 0xD9 | Turn ON |
Turn OFF | 0xDA | Turn OFF |
Input Line 2 | 0xE0 | Select Line 2 as input channel |
Turn ON + Input Line 2 | 0xFB | Turn ON and select Line 2 as input channel |
Input Line 3 | 0x170 | Select Line 3 as input channel |
Turn ON + Input Line 3 | 0x17F | Turn ON and select Line 3 as input channel |
Test | 0x421 | Test Mode? |
Test | 0x422 | Test Mode? |
Test | 0x423 | Test Mode? |
Volume control codes shown in the table are sent by the receiver out of its RI ports when adjusting the volume using a remote control (they can be found using an oscilloscope). However, the receiver will not react to these codes when they are sent from an external device, effectively making impossible to control its volume through RI signals.
Program is located in repo folder Onkyo_test. It serves for check all codes (0x0 - 0xFFF) on target device in 500ms interval. For data line pin 10 is used as default.
Actual checked code is sent as ASCII through serial port and can be displayed in terminal. For serial port 9600b/s is set. Using terminal test program can be stopped, reset or user defined code could be used.
Terminal commands:
- p - pause/run command sending
- r - reset loop (program start from 0)
- hexadecimal number - number in hexadecimal format represents code that user want to test on target device. From this code automatical procedure will continue.