A Python library for controlling older Onkyo/Integra receivers over RS232
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Colin Murphy 6ab44ae2bb volume range is 0-80 not 1-80 4 months ago
.gitignore add gitignore 4 months ago
README.md fix setVolume function 4 months ago
onkyo.py volume range is 0-80 not 1-80 4 months ago
test.py update test.py 4 months ago

README.md

Onkyo-RS232

A python library (and later, utility) for controlling an Onkyo or Integra stereo receiver using the Onkyo RS232 protocol. So far it has only been tested on the Integra DTM-5.9 receiver, but it should work to an extent on all Onkyo/Integra models.

For a general overview of usage, see test.py.

Requirements

Command list

sendRawCMD

Sends a raw command to the receiver. Omit the !1 from the command.

Example:

# turns on the receiver
onkyo.sendRawCMD('PWR01')

powerOn

Turns on the receiver.

powerOff

Turns off the receiver.

setVolume

Sets volume to the desired level. Range is from 0 to 80.

Set volume to 10: setVolume(10)

volUp

Increases the volume by 1.

volDown

Decreases the volume by 1.

setInput

Changes the input on the receiver to the desired input.

Implemented options:

  • VIDEO0 (VCR/DVR)
  • VIDEO1 (CBL/SAT)
  • VIDEO2 (GAME/TV)
  • VIDEO3 (AUX1)
  • VIDEO4 (AUX2)
  • VIDEO5
  • VIDEO6
  • VIDEO7
  • DVD
  • TAPE1
  • TAPE2
  • PHONO
  • CD
  • FM
  • AM
  • TUNER
  • XM
  • SIRIUS

Each receiver model has different inputs that are supported. If the input does not exist, it will not change inputs and will remain on the current input.

tuneFreq

Tunes to the specified frequency. You must specify the band (AM, FM, and in the near future XM and Sirius) and the frequency.

To tune to 93.3 MHz, do tuneFreq('fm', 93.3). Meanwhile, to tune to 540 KHz, do tuneFreq('am', 540).

tunePreset

Tunes to a specific saved preset. The preset range is from 1 to 40.

To tune to preset 1, do tunePreset(1).

sendTrigger

Turns on or off the 12V triggers on Integra receivers.

To turn 12V trigger A to ON: sendTrigger('A', True)

setDimmer

Dims the display on the receiver.

Options:

  • bright
  • dim
  • dark
  • off

To dim the screen, setDimmer('dim')

close

Closes the serial connection to the receiver.