Saturday, June 18, 2011

Programmatically Controlling Pioneer Receivers and BluRay Players

I recently got a new Pioneer Elite SC-35 receiver (http://www.pioneerelectronics.com/PUSA/Products/HomeEntertainment/AV-Receivers/EliteReceivers/ci.SC-35.Kuro).  This receiver has an ethernet plug on the rear and is supported by the iPhone/iPOD app called iControlAV. 
While the receiver has a web interface called "Pioneer Web Control System" I wanted a way to control this receiver via script. The web interface has support for
  • Powering the receiver on/off
  • Changing the Volume including mute
  • Changing the Input (Zones 1-3)
  • Changing the "Listening Mode"
The iControlAV app for iPhone supports the same plus a few more options.
The iControlAV uses SSDP query to find the receiver. Which runs NU-OS 1.13.  You can Browse to http://<Receiver IP>/BasicDevice.xml to get the info on your device. 
My receiver has port 23 (telnet) open along with 80 and 8102 (referenced in BasicDevice.xml)
Basic process:
  • Send command as ASCII on telnet (23) or TCP/8102 (see your BasicDevice.xml)
  • Commands that check status or query the device begin with a ?
  • Commands that perform a command sometimes have parameters (input number) at begining, some at end
  • You can monitor the telnet window to see the "response" for each command sent.  This includes commands sent through IR remote or from the device its self.
Basic Commands (more commands to come in another post):
?P
Is Device powered ON?
PWR0 Device is ON
PWR1 Device is OFF
PF Power Device OFF
PO Power Device ON
?M  Is Zone MAIN muted
MUT1 Zone is NOT Muted
MUT0 Zone is Muted
MO  Mute MAIN zone
MF  unMute MAIN zone
?V Get Current Volume level
VOLxxx Current volume level, xxx is 000-200
VOL121 -20.0db
VOL081 -40.0db
XXXVL Set Volume Level to XXX (000 - 200)
001VL Set Volume Level to -80.0db
081VL Set Volume Level to -40.0db
?RGC Get inputs on device (i think)
RGC111001002 *Unknown*
?RGBxx Get inputs Name (related to above command), available inputs will change based on model
?RGB01 RGB010CD
?RGB02 RGB020TUNER
?RGB03 RGB030CD-R/TAPE
?F Get current input (use ?RGB to get name)
FN19 Input 19
FN15 Input 15
XXFN Set current input (XX = Input number)
XX Input number
19FN Set to input 19
15FN Set to input 15
?BP *UNKNOWN*
BPR1
?AP *UNKNOWN*
APR1
Example
Turn on device, set input to HDMI1 (19 in my case), and volume to -40db

PO

19FN

081VL

(Update: 7/17/2011)
I was able to find a doc that has all the commands (better than what I was able to determine). 
http://dl.dropbox.com/u/3275573/2010%20USA%20AVR%20RS-232C%20%26%20IP%20Commands%20for%20CI.pdf

5 comments:

Chris said...

Hey Mike,

Cool stuff. What does the conversation look like between the iControlAV app and the AVR? (wireshark capture) I'm trying to emulate this for an old pioneer receiver, and haven't managed to get the response correct to the M-SEARCH.

Thanks!
Chris

Mike Poulson said...

It is very chatty. Do you want/need a wireshark capture of it?

You can also check out http://dl.dropbox.com/u/3275573/2010%20USA%20AVR%20RS-232C%20%26%20IP%20Commands%20for%20CI.pdf

John_R said...

Hi

Your discoverings is very interesting! Is it possible to catch the return values from the reciver in the telnet conection? I'm dreaming about making a volumecontrol for the receiver, and place it along with the volumecontrol in the systembar in windows. Do you have any clue if this is possible?

Mike Poulson said...

Yes you could. You would have to leave the Telnet session open to parse incoming text.

From what I have seen the device only allowed a single telnet session to be open. So if you had other IP controls you would not be able to use them at the same time.

If you want help writting some c# code on this let me know. mike a t mikepoulson.com

Javier GM said...

I quickly created a small ugly application to turn volume up and down and mute, but it is very easy to keep adding more commands if you want to...

https://github.com/ndsrf/PioneerDesktop