Python Plugin: Pioneer AVR
Moderator: leecollings
-
- Posts: 331
- Joined: Monday 03 July 2017 19:58
- Target OS: NAS (Synology & others)
- Domoticz version:
- Contact:
Python Plugin: Pioneer AVR
Hi all,
This is my first attempt on Pioneer AVR plugin, it is written for my VSX-921 unit. Please note that it is probably full of bugs, and at its best it is a beta. For those who would like to test it and inform me of the outcome, or just fork it and use it for their own purpose please welcome to do so. It will probably work for SC-37, SC-35, VSX-32, VSX-33, VSX 900, VSX 1120. For other models you can just test it. I tested it on Domoticz Beta with VSX-921K. Then i got bored since i am using Harmony remote with the unit and honestly will not be using this. But if there is any request for it, i might force myself a little bit more...
Good Luck;
https://github.com/febalci/DomoticzPioneerAVR
This is my first attempt on Pioneer AVR plugin, it is written for my VSX-921 unit. Please note that it is probably full of bugs, and at its best it is a beta. For those who would like to test it and inform me of the outcome, or just fork it and use it for their own purpose please welcome to do so. It will probably work for SC-37, SC-35, VSX-32, VSX-33, VSX 900, VSX 1120. For other models you can just test it. I tested it on Domoticz Beta with VSX-921K. Then i got bored since i am using Harmony remote with the unit and honestly will not be using this. But if there is any request for it, i might force myself a little bit more...
Good Luck;
https://github.com/febalci/DomoticzPioneerAVR
Re: Python Plugin: Pioneer AVR
I started working on a plugin for the Pioneer VSX528. Unfortunately the VSX528 only uses VU and VD, and NOT nnnVL for volume control
. Can you also implement that?

-
- Posts: 331
- Joined: Monday 03 July 2017 19:58
- Target OS: NAS (Synology & others)
- Domoticz version:
- Contact:
Re: Python Plugin: Pioneer AVR
Well for starters, domoticz doesn't have up down button for device. We either have to implement 2 seperate push buttons or a blinds device. I do not know if blinds device icons are customizable because as far as i know most of the device icons are non-customizable. If you can live with that...

UPDATE: On second thought, maybe i can convert slider values in a for loop. Like send 15 VU commands in a row. I'll try it, which version is better for you push-buttons or slider?
Re: Python Plugin: Pioneer AVR
That is what I did. I created a slider and the code:
So I request the current volume and store it in self.mainVolume. If the slider is moved up or down, I calculate the difference and send multiple VU or VD ( be aware that VU or VD goes in steps of 2. self.VOLUMESTEP = 2
It is working not that bad
.
The main question is then: how to identify which command is supported by a Pioneer AVR: nnnVL or VU/VD?
Code: Select all
if (Unit == self.MAINVOLUME):
if str(Command) == "Set Level":
level = int(str(Level))
delta = level - self.mainVolume
Domoticz.Debug("delta: "+str(delta))
for i in range(0, abs(delta), self.VOLUMESTEP):
if delta < 0:
self.mainVolume -= self.VOLUMESTEP
self.avrConn.Send(Message='VD\r')
Domoticz.Debug("VD")
elif delta > 0:
self.mainVolume += self.VOLUMESTEP
self.avrConn.Send(Message='VU\r')
Domoticz.Debug("VU")
It is working not that bad

The main question is then: how to identify which command is supported by a Pioneer AVR: nnnVL or VU/VD?
Re: Python Plugin: Pioneer AVR
I opened a telnet session. Approx. every minute I get an 'R'. Also when I give eg. '060VL' (or any other invalid command) I get an 'R'. When I enter VD it gives me the current volume level:
Perhaps that can be used? Perhaps you need to send a sequence of commands to change the volume a little and check whether the volume is changed.
Code: Select all
R
R
R
R
R
VOL060
R
061VL
R
XXX
R
R
R
R
VD
VOL059
VU
VOL061
?V
VOL061
Re: Python Plugin: Pioneer AVR
Woooow, what a very good worked out plan... Just the plugin that i was looking for!!! Very good work !!!
To contribute to this plugin, i added some lines to the input_modes in pioneerapi.py (to support the inputs on my vsx-922)...
I also put them in order to help me finding the missing ones:
(and maybe it's an idea, to complete all the numbers to the list, with unknown for those we don't know)
Secondly it's an idea to put the InputIdx string from plugin.py in a device parameter inputs ????
Since the input device wasn't supported to the home app through homebridge i made some several dummy switches which through blockly set the right input
So now i can talk to siri and control my vsx-922...
Keep up this good work !!!!!!
To contribute to this plugin, i added some lines to the input_modes in pioneerapi.py (to support the inputs on my vsx-922)...
I also put them in order to help me finding the missing ones:
(and maybe it's an idea, to complete all the numbers to the list, with unknown for those we don't know)
Code: Select all
INPUT_MODES= {
'00' : 'PHONO',
'01' : 'CD',
'02' : 'TUNER',
'03' : 'CD-R/TAPE',
'04' : 'DVD',
'05' : 'TV/SAT',
'06' : 'SAT/CBL',
'10' : 'VIDEO 1',
'12' : 'MULTI CH IN',
'14' : 'VIDEO 2',
'15' : 'DVR/BDR',
'17' : 'iPod/USB',
'18' : 'XM RADIO',
'19' : 'HDMI 1',
'20' : 'HDMI 2',
'21' : 'HDMI 3',
'22' : 'HDMI 4',
'23' : 'HDMI 5',
'24' : 'HDMI 6',
'25' : 'BD',
'26' : 'H.M.G.',
'27' : 'SIRIUS',
'31' : 'HDMI (cyclic)',
'33' : 'ADAPTER PORT',
'38' : 'INTERNET RADIO',
'40' : 'SiriusXM',
'41' : 'PANDORA',
'44' : 'MEDIA SERVER',
'45' : 'FAVORITES'
}
Since the input device wasn't supported to the home app through homebridge i made some several dummy switches which through blockly set the right input

So now i can talk to siri and control my vsx-922...
Keep up this good work !!!!!!
-
- Posts: 331
- Joined: Monday 03 July 2017 19:58
- Target OS: NAS (Synology & others)
- Domoticz version:
- Contact:
Re: Python Plugin: Pioneer AVR
Thanks Korrel, i am happy that the plugin worked out for you. Also thanks for the correction of the list, i committed the changes to the pioneer.py on github.
Can you please explain your comment above, about the InputIdx, maybe with an example?
-
- Posts: 7
- Joined: Wednesday 02 August 2017 5:40
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Python Plugin: Pioneer AVR
I just added the plugin and it looks pretty awesome!
On my system i use the zone 2 heaps and would like to control that. Has any one done it?
I have been duplicating the code and i think i have ot pretty sorted but cant get it to add the aditional devices, it this a limitation to domoticz or an error with my code? I suspect im in over my head with it all.
On my system i use the zone 2 heaps and would like to control that. Has any one done it?
I have been duplicating the code and i think i have ot pretty sorted but cant get it to add the aditional devices, it this a limitation to domoticz or an error with my code? I suspect im in over my head with it all.
-
- Posts: 331
- Joined: Monday 03 July 2017 19:58
- Target OS: NAS (Synology & others)
- Domoticz version:
- Contact:
Re: Python Plugin: Pioneer AVR
If you can send me your code, i might check it out
-
- Posts: 331
- Joined: Monday 03 July 2017 19:58
- Target OS: NAS (Synology & others)
- Domoticz version:
- Contact:
Re: Python Plugin: Pioneer AVR
Dear biggav,
It's all about python errors; typos and a forgotten OnCommand:
Use these; I cannot test it since my dumb old avr is only one Zone (or at least i am using only 1); But you can test and send me the results to solve it.
pioneerapi.py:
Change section:
Code: Select all
#Zone 2 Input
def Z2F_decode(self,z2f_text):
decoded_z2f = ''
try:
decoded_z2f = Z2_INPUT_MODES[z2f_text]
except KeyError:
decoded_z2f = "ZONE 2 INPUT KEY ERROR"
return decoded_z2f
Code: Select all
#Zone 2 Input
def Z2F_decode(self,z2f_text):
decoded_z2f = ''
try:
decoded_z2f = INPUT_MODES[z2f_text]
except KeyError:
decoded_z2f = "ZONE 2 INPUT KEY ERROR"
return decoded_z2f
and in plugin.py; there are more typos and errors, so use this instead:
Code: Select all
"""
<plugin key="PioneerAVR" name="Pioneer AVR" author="febalci" version="0.9.0">
<params>
<param field="Address" label="IP Address" width="250px" required="true" default="192.168.1.60"/>
<param field="Port" label="Port" width="50px" required="true" default="8102"/>
<param field="Mode6" label="Debug" width="75px">
<options>
<option label="True" value="Debug"/>
<option label="False" value="Normal" default="true" />
</options>
</param>
</params>
</plugin>
"""
import Domoticz
import pioneerapi
class BasePlugin:
nextConnect = 3
oustandingPings = 0
UNITS = {
'power': 1,
'input': 2,
'display': 3,
'listening_mode': 4,
'playing_mode': 5,
'main_volume': 6,
'z2_power': 7,
'z2_input': 8,
'z2_volume': 9
}
PioneerConn = None
power_on = False
volume_level = None
mute = None
input_rgb_name = None
input_mode = "0"
listening_mode = None
playing_mode = None
display_text = None
InputIdx = ("01","02","03","04","05","10","14","15","17","25","26")
#Zone 2
Z2_power_on = False
Z2_volume_level = None
Z2_mute = None
Z2_input_rgb_name = None
Z2_input_mode = "0"
Z2_InputIdx = ("01","02","03","04","05","10","14","15","17","25","26")
def __init__(self):
#self.var = 123
return
def onStart(self):
Domoticz.Debug("onStart called")
if Parameters["Mode6"] == "Debug":
Domoticz.Debugging(1)
InputSelections = 'Off'
for a in self.InputIdx:
InputSelections = InputSelections+'|'+pioneerapi.INPUT_MODES[a]
Domoticz.Debug('LIST:'+InputSelections)
SourceOptions = {'LevelActions': '|'*InputSelections.count('|'),
'LevelNames': InputSelections,
'LevelOffHidden': 'false',
'SelectorStyle': '1'}
if self.UNITS['power'] not in Devices:
Domoticz.Device(Name="Power", Unit=self.UNITS['power'], TypeName="Switch", Image=5, Used=1).Create()
if self.UNITS['input'] not in Devices:
Domoticz.Device(Name="Input", Unit=self.UNITS['input'], TypeName="Selector Switch", Switchtype=18, Image=5, Options=SourceOptions, Used=1).Create()
if self.UNITS['display'] not in Devices:
Domoticz.Device(Name="Display", Unit=self.UNITS['display'], TypeName="Text", Image=5, Used=1).Create()
if self.UNITS['listening_mode'] not in Devices:
Domoticz.Device(Name="Listening Mode", Unit=self.UNITS['listening_mode'], TypeName="Text", Used=1).Create()
if self.UNITS['playing_mode'] not in Devices:
Domoticz.Device(Name="Playing Mode", Unit=self.UNITS['playing_mode'], TypeName="Text", Used=1).Create()
if self.UNITS['main_volume'] not in Devices:
Domoticz.Device(Name="Volume Main Zone", Unit=self.UNITS['main_volume'], Type=244, Subtype=73, Switchtype=7, Image=8, Used=1).Create()
#Zone 2
Z2InputSelections = 'Off'
for a in self.Z2_InputIdx:
Z2InputSelections = Z2InputSelections+'|'+pioneerapi.INPUT_MODES[a]
Domoticz.Debug('LIST:'+Z2InputSelections)
Z2SourceOptions = {'LevelActions': '|'*Z2InputSelections.count('|'),
'LevelNames': Z2InputSelections,
'LevelOffHidden': 'false',
'SelectorStyle': '1'}
if self.UNITS['z2_power'] not in Devices:
Domoticz.Device(Name="Zone 2 Power", Unit=self.UNITS['z2_power'], TypeName="Switch", Image=5, Used=1).Create()
if self.UNITS['z2_input'] not in Devices:
Domoticz.Device(Name="Zone 2 Input", Unit=self.UNITS['z2_input'], TypeName="Selector Switch", Switchtype=18, Image=5, Options=Z2SourceOptions, Used=1).Create()
if self.UNITS['z2_volume'] not in Devices:
Domoticz.Device(Name="Volume Zone 2", Unit=self.UNITS['z2_volume'], Type=244, Subtype=73, Switchtype=7, Image=8, Used=1).Create()
DumpConfigToLog()
self.SyncDevices(1)
self.PioneerConn = Domoticz.Connection(Name="Telnet", Transport="TCP/IP", Protocol="Line", Address=Parameters["Address"], Port=Parameters["Port"])
self.PioneerConn.Connect()
Domoticz.Heartbeat(30)
def onStop(self):
Domoticz.Log("onStop called")
def onConnect(self, Connection, Status, Description):
global api
Domoticz.Debug("onConnect called")
if Status == 0:
self.isConnected = True
Domoticz.Debug("Connected successfully to: "+Parameters["Address"]+":"+Parameters["Port"])
api = pioneerapi.pioneerapi()
self.PioneerConn.Send('\r') #Send <CR> to wake unit from stanby
self.PioneerConn.Send(api.qry_PowerStatus, Delay=1)
self.PioneerConn.Send(api.qry_InputStatus, Delay=2)
self.PioneerConn.Send(api.qry_VolumeStatus, Delay=3)
self.PioneerConn.Send(api.qry_ListeningModeStatus, Delay=4)
self.PioneerConn.Send(api.qry_Z2_PowerStatus, Delay=5)
self.PioneerConn.Send(api.qry_Z2_InputStatus, Delay=6)
self.PioneerConn.Send(api.qry_Z2_VolumeStatus, Delay=7)
wait=8
for key in self.InputIdx:
wait += 1
self.PioneerConn.Send("?RGB"+str(key)+"\r", Delay=wait)
else:
self.isConnected = False
self.power_on = False
self.SyncDevices(1)
Domoticz.Debug("Failed to connect ("+str(Status)+") to: "+Parameters["Address"]+":"+Parameters["Port"]+" with error: "+Description)
return
def onMessage(self, Connection, Data):
Domoticz.Debug("onMessage called")
self.oustandingPings = self.oustandingPings - 1
strData = Data.decode("utf-8", "ignore")
Domoticz.Debug("onMessage called with Data: '"+str(strData)+"'")
strData = strData.strip()
shaction = strData[0:2]
shdetail = strData[2:]
loaction = strData[0:3]
lodetail = strData[3:]
if loaction == 'PWR': #POWER
if lodetail == '0': #PWR0
self.power_on = True
self.PioneerConn.Send(api.qry_VolumeStatus, Delay=0)
else: #PWR1
self.power_on = False
elif loaction == 'VOL': #VOLUME
self.volume_level = str(round((int(str(lodetail))*100)/185))
elif loaction == 'MUT': #MUTE
if lodetail == '0': #MUT0
self.mute = 'On'
else: #MUT1
self.mute = 'Off'
elif loaction == 'RGB': #INPUT NAME
self.input_rgb_name = api.RGB_decode(str(lodetail))
if self.input_rgb_name != None:
Domoticz.Debug('RGB:'+self.input_rgb_name)
InputSelections = 'Off'
for a in self.InputIdx:
InputSelections = InputSelections+'|'+pioneerapi.INPUT_MODES[a]
Domoticz.Debug('LIST:'+InputSelections)
SourceOptions = {'LevelActions': '|'*InputSelections.count('|'),
'LevelNames': InputSelections,
'LevelOffHidden': 'false',
'SelectorStyle': '1'}
Devices[self.UNITS['input']].Update(nValue = 0, sValue = "Off", Options = SourceOptions)
elif shaction == 'FN': #INPUT
self.input_mode = self.selector_find(str(shdetail), 0)
Domoticz.Debug('FN:'+str(self.input_mode))
elif shaction == 'Z2F': #Zone 2 INPUT
self.input_mode = self.selector_find(str(shdetail), 0)
Domoticz.Debug('Z2F:'+str(self.input_mode))
elif shaction == 'SR': #LISTENING MODE
self.listening_mode = api.SR_decode(str(shdetail))
Domoticz.Debug('SR:'+self.listening_mode)
elif shaction == 'LM': #PLAYING LISTENING MODE
self.playing_mode = api.LM_decode(str(shdetail))
Domoticz.Debug('LM:'+self.playing_mode)
elif shaction == 'FL': #DISPLAY TEXT
self.display_text = api.FL_decode(str(shdetail))
Domoticz.Debug('FL:'+self.display_text)
self.SyncDevices(0)
return
def onCommand(self, Unit, Command, Level, Hue):
Domoticz.Debug("onCommand called for Unit " + str(Unit) + ": Parameter '" + str(Command) + "', Level: " + str(Level))
action, sep, params = Command.partition(' ')
action = action.capitalize()
params = params.capitalize()
if Unit == self.UNITS['power']:
if Command=='Off':
Domoticz.Debug("Unit Power Off")
self.PioneerConn.Send(Message=api.cmd_PowerOff, Delay=0)
self.power_on = False
elif Command=='On':
Domoticz.Debug("Unit Power On")
self.PioneerConn.Send(Message=api.cmd_PowerOn, Delay=0)
self.power_on = True
elif Unit == self.UNITS['main_volume']:
if (action == "On"):
self.PioneerConn.Send(Message='MF\r', Delay=0)
elif (action == "Set"):
self.volume_level = str(round((int(Level)*185)/100)).rjust(3,'0')
self.PioneerConn.Send(Message=self.volume_level+'VL\r', Delay=0)
elif (action == "Off"):
self.PioneerConn.Send(Message='MO\r', Delay=0)
Domoticz.Debug('Level:'+str(Level))
elif Unit == self.UNITS['input']:
if (action == "Set"):
if Level != "0":
self.input_mode = self.selector_find(Level,1)
self.PioneerConn.Send(Message=self.input_mode+'FN\r', Delay=0)
else:
self.power_on = False
self.PioneerConn.Send(Message=api.cmd_PowerOff, Delay=0)
#Zone 2
if Unit == self.UNITS['z2_power']:
if Command=='Off':
Domoticz.Debug("Unit Power Off")
self.PioneerConn.Send(Message=api.cmd_Z2_PowerOff, Delay=0)
self.power_on = False
elif Command=='On':
Domoticz.Debug("Unit Power On")
self.PioneerConn.Send(Message=api.cmd_Z2_PowerOn, Delay=0)
self.power_on = True
elif Unit == self.UNITS['z2_volume']:
if (action == "On"):
self.PioneerConn.Send(Message='Z2MF\r', Delay=0) #mute on function
elif (action == "Set"):
self.volume_level = str(round((int(Level)*185)/100)).rjust(3,'0')
self.PioneerConn.Send(Message=self.volume_level+'ZV\r', Delay=0)
elif (action == "Off"):
self.PioneerConn.Send(Message='Z2MO\r', Delay=0) #mute off function
Domoticz.Debug('Level:'+str(Level))
elif Unit == self.UNITS['z2_input']:
if (action == "Set"):
if Level != "0":
self.input_mode = self.selector_find(Level,1)
self.PioneerConn.Send(Message=self.z2_input_mode+'ZS\r', Delay=0)
else:
self.power_on = False
self.PioneerConn.Send(Message=api.cmd_Z2_PowerOff, Delay=0)
def onNotification(self, Name, Subject, Text, Status, Priority, Sound, ImageFile):
Domoticz.Log("Notification: " + Name + "," + Subject + "," + Text + "," + Status + "," + str(Priority) + "," + Sound + "," + ImageFile)
def onDisconnect(self, Connection):
Domoticz.Log("onDisconnect called")
self.isConnected = False
def onHeartbeat(self):
if (self.PioneerConn.Connected() == True):
if (self.oustandingPings > 3):
Domoticz.Debug("Ping Timeout, Disconnect")
self.PioneerConn.Disconnect()
self.nextConnect = 0
else:
self.PioneerConn.Send(Message=api.qry_PowerStatus,Delay=0)
Domoticz.Debug("POWER STATUS Message Sent")
self.oustandingPings = self.oustandingPings + 1
else:
# if not connected try and reconnected every 2 heartbeats
self.oustandingPings = 0
self.nextConnect = self.nextConnect - 1
if (self.nextConnect <= 0):
self.nextConnect = 3
self.PioneerConn.Connect()
return
def SyncDevices(self, TimedOut):
if (self.power_on == False):
UpdateDevice(self.UNITS['power'], 0, "Off", TimedOut)
UpdateDevice(self.UNITS['input'], 0, "0", TimedOut)
UpdateDevice(self.UNITS['display'], 0, "", TimedOut)
UpdateDevice(self.UNITS['listening_mode'], 0, "", TimedOut)
UpdateDevice(self.UNITS['playing_mode'], 0, "", TimedOut)
UpdateDevice(self.UNITS['main_volume'], 0, self.volume_level, TimedOut)
else:
UpdateDevice(self.UNITS['power'], 1 , "On", TimedOut)
UpdateDevice(self.UNITS['input'], int(self.input_mode), str(self.input_mode), TimedOut)
UpdateDevice(self.UNITS['display'], 0, self.display_text, TimedOut)
UpdateDevice(self.UNITS['listening_mode'], 0, self.listening_mode, TimedOut)
UpdateDevice(self.UNITS['playing_mode'], 0, self.playing_mode, TimedOut)
UpdateDevice(self.UNITS['main_volume'],2,self.volume_level, TimedOut)
return
def selector_find(self, query, ctype):
if ctype == 0:
sel = (self.InputIdx.index(str(query))+1)*10 #Off olduğu için +1 var
Domoticz.Debug('INDEX:'+str(sel))
else:
sel = self.InputIdx[int((query/10)-1)] #Off olduğu için -1 var
return sel
global _plugin
_plugin = BasePlugin()
def onStart():
global _plugin
_plugin.onStart()
def onStop():
global _plugin
_plugin.onStop()
def onConnect(Connection, Status, Description):
global _plugin
_plugin.onConnect(Connection, Status, Description)
def onMessage(Connection, Data):
global _plugin
_plugin.onMessage(Connection, Data)
def onCommand(Unit, Command, Level, Hue):
global _plugin
_plugin.onCommand(Unit, Command, Level, Hue)
def onNotification(Name, Subject, Text, Status, Priority, Sound, ImageFile):
global _plugin
_plugin.onNotification(Name, Subject, Text, Status, Priority, Sound, ImageFile)
def onDisconnect(Connection):
global _plugin
_plugin.onDisconnect(Connection)
def onHeartbeat():
global _plugin
_plugin.onHeartbeat()
# Generic helper functions
def UpdateDevice(Unit, nValue, sValue, TimedOut):
# Make sure that the Domoticz device still exists (they can be deleted) before updating it
if (Unit in Devices):
if (Devices[Unit].nValue != nValue) or (Devices[Unit].sValue != sValue) or (Devices[Unit].TimedOut != TimedOut):
Devices[Unit].Update(nValue=nValue, sValue=str(sValue), TimedOut=TimedOut)
Domoticz.Log("Update "+str(nValue)+":'"+str(sValue)+"' ("+Devices[Unit].Name+")")
return
def DumpConfigToLog():
for x in Parameters:
if Parameters[x] != "":
Domoticz.Debug( "'" + x + "':'" + str(Parameters[x]) + "'")
Domoticz.Debug("Device count: " + str(len(Devices)))
for x in Devices:
Domoticz.Debug("Device: " + str(x) + " - " + str(Devices[x]))
Domoticz.Debug("Device ID: '" + str(Devices[x].ID) + "'")
Domoticz.Debug("Device Name: '" + Devices[x].Name + "'")
Domoticz.Debug("Device nValue: " + str(Devices[x].nValue))
Domoticz.Debug("Device sValue: '" + Devices[x].sValue + "'")
Domoticz.Debug("Device LastLevel: " + str(Devices[x].LastLevel))
return
-
- Posts: 7
- Joined: Wednesday 02 August 2017 5:40
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Python Plugin: Pioneer AVR
Thanks heaps febalci,
that worked straight up nice work. the only bug i found is the zone 2 power feedback and input feedback are not working. do you have any ideas about this one?
that worked straight up nice work. the only bug i found is the zone 2 power feedback and input feedback are not working. do you have any ideas about this one?
-
- Posts: 1
- Joined: Saturday 23 June 2018 8:40
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Python Plugin: Pioneer AVR
Firstly, let me thank you for putting time and ressources into this project.
I would like to try out your plugin.
Domoticz run on Raspberry PI 3
AVR: Pioneer VSX-922K
AVR IP: 10.0.1.15
AVR Port: 8102 (this is the default for the script, not sure if I should use another one)
I've tried connecting to the AVR through telnet, this works fine.
In the past, the AVR have been connected to the standard Pioneer App, and through openHAB, with great success, so I'm pretty sure it is possible. Not sure if the problem lies within the model of my AVR or possible the port number.
I've added the plugin to domoticz and tried to connect it to my AVR. I'm note sure if the port number is correct, but it looks like it can't connect to the avr. the debug is as follows:
I would like to try out your plugin.
Domoticz run on Raspberry PI 3
AVR: Pioneer VSX-922K
AVR IP: 10.0.1.15
AVR Port: 8102 (this is the default for the script, not sure if I should use another one)
I've tried connecting to the AVR through telnet, this works fine.
In the past, the AVR have been connected to the standard Pioneer App, and through openHAB, with great success, so I'm pretty sure it is possible. Not sure if the problem lies within the model of my AVR or possible the port number.
I've added the plugin to domoticz and tried to connect it to my AVR. I'm note sure if the port number is correct, but it looks like it can't connect to the avr. the debug is as follows:
Code: Select all
2018-06-23 08:44:42.353 (Forstærker Stue) Started.
2018-06-23 08:44:42.481 (Forstærker Stue) Entering work loop.
2018-06-23 08:44:42.481 (Forstærker Stue) Initialized version 0.9.0, author 'febalci'
2018-06-23 08:44:42.483 (Forstærker Stue) Debug log level set to: 'true'.
2018-06-23 08:44:42.483 (Forstærker Stue) LIST:Off|CD|TUNER|CD-R/TAPE|DVD|TV/SAT|VIDEO 1|VIDEO 2|DVR/BDR|iPod/USB|BD|H.M.G.
2018-06-23 08:44:42.483 (Forstærker Stue) Creating device 'Power'.
2018-06-23 08:44:42.485 (Forstærker Stue) Creating device 'Input'.
2018-06-23 08:44:42.487 (Forstærker Stue) Creating device 'Display'.
2018-06-23 08:44:42.489 (Forstærker Stue) Creating device 'Listening Mode'.
2018-06-23 08:44:42.490 (Forstærker Stue) Creating device 'Playing Mode'.
2018-06-23 08:44:42.492 (Forstærker Stue) Creating device 'Volume Main Zone'.
2018-06-23 08:44:42.494 (Forstærker Stue) 'Key':'PioneerAVR'
2018-06-23 08:44:42.494 (Forstærker Stue) 'HardwareID':'8'
2018-06-23 08:44:42.494 (Forstærker Stue) 'Name':'Forstærker Stue'
2018-06-23 08:44:42.494 (Forstærker Stue) 'Mode6':'Debug'
2018-06-23 08:44:42.494 (Forstærker Stue) 'HomeFolder':'/home/pi/domoticz/plugins/DomoticzPioneerAVR/'
2018-06-23 08:44:42.494 (Forstærker Stue) 'Author':'febalci'
2018-06-23 08:44:42.494 (Forstærker Stue) 'Port':'8102'
2018-06-23 08:44:42.494 (Forstærker Stue) 'Version':'0.9.0'
2018-06-23 08:44:42.495 (Forstærker Stue) 'Address':'10.0.1.15'
2018-06-23 08:44:42.495 (Forstærker Stue) Device count: 6
2018-06-23 08:44:42.495 (Forstærker Stue) Device: 1 - ID: 443, Name: 'Forstærker Stue - Power', nValue: 0, sValue: ''
2018-06-23 08:44:42.495 (Forstærker Stue) Device ID: '443'
2018-06-23 08:44:42.495 (Forstærker Stue) Device Name: 'Forstærker Stue - Power'
2018-06-23 08:44:42.495 (Forstærker Stue) Device nValue: 0
2018-06-23 08:44:42.495 (Forstærker Stue) Device sValue: ''
2018-06-23 08:44:42.495 (Forstærker Stue) Device LastLevel: 0
2018-06-23 08:44:42.495 (Forstærker Stue) Device: 2 - ID: 444, Name: 'Forstærker Stue - Input', nValue: 0, sValue: ''
2018-06-23 08:44:42.495 (Forstærker Stue) Device ID: '444'
2018-06-23 08:44:42.495 (Forstærker Stue) Device Name: 'Forstærker Stue - Input'
2018-06-23 08:44:42.495 (Forstærker Stue) Device nValue: 0
2018-06-23 08:44:42.495 (Forstærker Stue) Device sValue: ''
2018-06-23 08:44:42.495 (Forstærker Stue) Device LastLevel: 0
2018-06-23 08:44:42.495 (Forstærker Stue) Device: 3 - ID: 445, Name: 'Forstærker Stue - Display', nValue: 0, sValue: ''
2018-06-23 08:44:42.495 (Forstærker Stue) Device ID: '445'
2018-06-23 08:44:42.495 (Forstærker Stue) Device Name: 'Forstærker Stue - Display'
2018-06-23 08:44:42.495 (Forstærker Stue) Device nValue: 0
2018-06-23 08:44:42.495 (Forstærker Stue) Device sValue: ''
2018-06-23 08:44:42.495 (Forstærker Stue) Device LastLevel: 0
2018-06-23 08:44:42.495 (Forstærker Stue) Device: 4 - ID: 446, Name: 'Forstærker Stue - Listening Mode', nValue: 0, sValue: ''
2018-06-23 08:44:42.495 (Forstærker Stue) Device ID: '446'
2018-06-23 08:44:42.495 (Forstærker Stue) Device Name: 'Forstærker Stue - Listening Mode'
2018-06-23 08:44:42.495 (Forstærker Stue) Device nValue: 0
2018-06-23 08:44:42.495 (Forstærker Stue) Device sValue: ''
2018-06-23 08:44:42.495 (Forstærker Stue) Device LastLevel: 0
2018-06-23 08:44:42.495 (Forstærker Stue) Device: 5 - ID: 447, Name: 'Forstærker Stue - Playing Mode', nValue: 0, sValue: ''
2018-06-23 08:44:42.495 (Forstærker Stue) Device ID: '447'
2018-06-23 08:44:42.496 (Forstærker Stue) Device Name: 'Forstærker Stue - Playing Mode'
2018-06-23 08:44:42.496 (Forstærker Stue) Device nValue: 0
2018-06-23 08:44:42.496 (Forstærker Stue) Device sValue: ''
2018-06-23 08:44:42.496 (Forstærker Stue) Device LastLevel: 0
2018-06-23 08:44:42.496 (Forstærker Stue) Device: 6 - ID: 448, Name: 'Forstærker Stue - Volume Main Zone', nValue: 0, sValue: ''
2018-06-23 08:44:42.496 (Forstærker Stue) Device ID: '448'
2018-06-23 08:44:42.496 (Forstærker Stue) Device Name: 'Forstærker Stue - Volume Main Zone'
2018-06-23 08:44:42.496 (Forstærker Stue) Device nValue: 0
2018-06-23 08:44:42.496 (Forstærker Stue) Device sValue: ''
2018-06-23 08:44:42.496 (Forstærker Stue) Device LastLevel: 0
2018-06-23 08:44:42.496 Error: (CDevice_update) Forstærker Stue - Power: Failed to parse parameters: 'nValue', 'sValue', 'SignalLevel', 'BatteryLevel' or 'Options' expected.
2018-06-23 08:44:42.496 Error: (Forstærker Stue) 'CDevice_update' failed 'TypeError':''TimedOut' is an invalid keyword argument for this function'.
2018-06-23 08:44:42.496 (Forstærker Stue) Update 0:'Off' (Forstærker Stue - Power)
2018-06-23 08:44:42.496 Error: (CDevice_update) Forstærker Stue - Input: Failed to parse parameters: 'nValue', 'sValue', 'SignalLevel', 'BatteryLevel' or 'Options' expected.
2018-06-23 08:44:42.496 Error: (Forstærker Stue) 'CDevice_update' failed 'TypeError':''TimedOut' is an invalid keyword argument for this function'.
2018-06-23 08:44:42.496 (Forstærker Stue) Update 0:'0' (Forstærker Stue - Input)
2018-06-23 08:44:42.496 Error: (Forstærker Stue) 'onStart' failed 'AttributeError':''Domoticz.Device' object has no attribute 'TimedOut''.
2018-06-23 08:44:42.496 Error: (Forstærker Stue) ----> Line 253 in /home/pi/domoticz/plugins/DomoticzPioneerAVR/plugin.py, function onStart
2018-06-23 08:44:42.496 Error: (Forstærker Stue) ----> Line 77 in /home/pi/domoticz/plugins/DomoticzPioneerAVR/plugin.py, function onStart
2018-06-23 08:44:42.496 Error: (Forstærker Stue) ----> Line 227 in /home/pi/domoticz/plugins/DomoticzPioneerAVR/plugin.py, function SyncDevices
2018-06-23 08:44:42.496 Error: (Forstærker Stue) ----> Line 288 in /home/pi/domoticz/plugins/DomoticzPioneerAVR/plugin.py, function UpdateDevice
2018-06-23 08:44:52.029 (Forstærker Stue) Calling message handler 'onHeartbeat'.
2018-06-23 08:44:52.029 Error: (Forstærker Stue) 'onHeartbeat' failed 'AttributeError':''NoneType' object has no attribute 'Connected''.
2018-06-23 08:44:52.029 Error: (Forstærker Stue) ----> Line 281 in /home/pi/domoticz/plugins/DomoticzPioneerAVR/plugin.py, function onHeartbeat
2018-06-23 08:44:52.029 Error: (Forstærker Stue) ----> Line 205 in /home/pi/domoticz/plugins/DomoticzPioneerAVR/plugin.py, function onHeartbeat
-
- Posts: 132
- Joined: Tuesday 20 October 2015 12:23
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: Netherlands
- Contact:
Re: Python Plugin: Pioneer AVR
I installed the plugin and tried using it with my VSX-933.
However I have some problems and I was wondering if you could help me out.
I receive these errors with not even doing anything:
Code: Select all
Failed to connect (110) to: 192.168.2.232:23 with error: Connection timed out
Error: CConnection_connect, connect request from 'Pioneer AVR' ignored. Transport is connecting.
Code: Select all
2019-02-25 16:15:45.867 Status: User: *** initiated a switch command (394/Pioneer AVR - Power/On)
2019-02-25 16:15:45.916 Error: (Pioneer AVR) 'onCommand' failed 'NameError':'name 'api' is not defined'.
2019-02-25 16:15:45.916 Error: (Pioneer AVR) ----> Line 269 in '/home/pi/domoticz/plugins/Pioneer-AVR/plugin.py', function onCommand
2019-02-25 16:15:45.916 Error: (Pioneer AVR) ----> Line 176 in '/home/pi/domoticz/plugins/Pioneer-AVR/plugin.py', function onCommand
-
- Posts: 331
- Joined: Monday 03 July 2017 19:58
- Target OS: NAS (Synology & others)
- Domoticz version:
- Contact:
Re: Python Plugin: Pioneer AVR
I am not so sure if vsx933 supports telnet connection; if yes from which port? From the messages it is obvious that it does not support port 23, have you tried 8102?rednas wrote: ↑Monday 25 February 2019 16:16I installed the plugin and tried using it with my VSX-933.
However I have some problems and I was wondering if you could help me out.
I receive these errors with not even doing anything:and when I for example try to power on the unit, I receive these errors:Code: Select all
Failed to connect (110) to: 192.168.2.232:23 with error: Connection timed out Error: CConnection_connect, connect request from 'Pioneer AVR' ignored. Transport is connecting.
Code: Select all
2019-02-25 16:15:45.867 Status: User: *** initiated a switch command (394/Pioneer AVR - Power/On) 2019-02-25 16:15:45.916 Error: (Pioneer AVR) 'onCommand' failed 'NameError':'name 'api' is not defined'. 2019-02-25 16:15:45.916 Error: (Pioneer AVR) ----> Line 269 in '/home/pi/domoticz/plugins/Pioneer-AVR/plugin.py', function onCommand 2019-02-25 16:15:45.916 Error: (Pioneer AVR) ----> Line 176 in '/home/pi/domoticz/plugins/Pioneer-AVR/plugin.py', function onCommand
-
- Posts: 132
- Joined: Tuesday 20 October 2015 12:23
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: Netherlands
- Contact:
Re: Python Plugin: Pioneer AVR
Port 8102 gives an error 111: connection refused
Port 23 gives an error 110: connection timed out
So actually it looks like there is a difference! Is there something else I could do wrong?
I am not able to find out whether it supports telnet actually..
Port 23 gives an error 110: connection timed out
So actually it looks like there is a difference! Is there something else I could do wrong?
I am not able to find out whether it supports telnet actually..
-
- Posts: 331
- Joined: Monday 03 July 2017 19:58
- Target OS: NAS (Synology & others)
- Domoticz version:
- Contact:
Re: Python Plugin: Pioneer AVR
Dear rednas,
I found it interesting that there is nearly no documents or information for connection types on web for VSX-933. But also, since it is not listed under supported for the smartphone app icontrolav5 https://play.google.com/store/apps/deta ... trolav2014, i assume your av does not support any telnet connections at all. As far as i know Pioneer was using Telnet connections for older models only. So it won't be possible for you to use this plugin for VSX-933

-
- Posts: 132
- Joined: Tuesday 20 October 2015 12:23
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Location: Netherlands
- Contact:
Re: Python Plugin: Pioneer AVR
Too bad, however strange that it responds different to port 8102 and 23...
I can find out that the VSX-933 supports Control4 control, so there must be a possibility to control it I would say. However, I can't find out how
I can find out that the VSX-933 supports Control4 control, so there must be a possibility to control it I would say. However, I can't find out how

Who is online
Users browsing this forum: Amazon [Bot] and 1 guest