Closed djensen47 closed 11 years ago
I have the same mirror issue.
$ onkyo master-volume:level-up
<eISCP(TX-NR509) 192.168.1.20:60128>: MVLUP
Traceback (most recent call last):
File "/usr/bin/onkyo", line 9, in <module>
load_entry_point('onkyo-eiscp==0.9', 'console_scripts', 'onkyo')()
File "/usr/lib/python2.7/site-packages/onkyo_eiscp-0.9-py2.7.egg/eiscp/script.py", line 124, in run
sys.exit(main() or 0)
File "/usr/lib/python2.7/site-packages/onkyo_eiscp-0.9-py2.7.egg/eiscp/script.py", line 119, in main
response = iscp_to_command(response)
File "/usr/lib/python2.7/site-packages/onkyo_eiscp-0.9-py2.7.egg/eiscp/core.py", line 206, in iscp_to_command
'Cannot convert ISCP message to command: %s' % iscp_message)
ValueError: Cannot convert ISCP message to command: MVL1F
same as above and also if I look up the volume command in help I get this error, which is quite obviously a unicode error as the windows console cannot display unicode characters natively.. I see no reason the character in question needs to be unicode and couldnt just be a '-'(dash)
PS C:\Users\Owner> onkyo --help-commands main master-volume
Possible values for this command:
Traceback (most recent call last):
File "D:\Apps\Python27\Scripts\onkyo-script.py", line 8, in
also in addition to above error(posted by moneytoo) I cannot send specific volume numbers such as: onkyo-master-volume=20 it gives an error:
PS C:\Users\Owner> onkyo main master-volume=20 Error: Need at least command and argument PS C:\Users\Owner> onkyo master-volume=20 Error: "20" is not a valid argument for command "master-volume" in zone "main"
Hi,
it seems to me that there is a problem regarding the commands.py. The value range is not properly defined. I am not a python guy, but (0, 100) does not work. I circumvented this by hacking the iscp_to_command function in core.py (see below). It is now possible to read out the values:
$ onkyo main.master-volume=query
<eISCP(TX-NR515) xxx.xxx.xxx.xxx:60128>: MVLQSTN
('master-volume', '15')
However for value input a more reliable solution should be implemented by a person which has more python knowledge than I. Note: It is important to distinguish between int and hex values
Just my two cent Juergen
def iscp_to_command(iscp_message):
for zone, zone_cmds in commands.COMMANDS.iteritems():
# For now, ISCP commands are always three characters, which
# makes this easy.
command, args = iscp_message[:3], iscp_message[3:]
if command in zone_cmds:
if args in zone_cmds[command]['values']:
return zone_cmds[command]['name'], \
zone_cmds[command]['values'][args]['name']
else:
return zone_cmds[command]['name'], \
int(args, 16)
else:
raise ValueError(
'Cannot convert ISCP message to command: %s' % iscp_message)
I've implemented the solution posted by @3s1d above, on my own fork.
I changed it a little to correct the indentation (no doubt lost in the post) and to check for an actual hexadecimal string before converting to int, otherwise it just reports it as a string.
I think this might be fixed then.
I'm experiencing similar issue:
onkyo -n 616 master-volume:query
<eISCP(TX-NR616) 192.168.25.9:60128>: MVLQSTN
Traceback (most recent call last):
File "/usr/local/bin/onkyo", line 8, in
Plus I'm having issue using command: onkyo -n 616 master-volume:55 or onkyo -n 616 master-volume=55
If it's of any use, Onkyo sent me the most recent v1.2.6 of the ISCP command XLS attached about 3 days ago:
That's great, thanks.
I have an Onkyo TX-NR515 and whenever I issue a command it works and then returns a ValueError.