Closed jluc2808 closed 6 years ago
Hello,
I have the same issue, I have created a new branch and testing a fix. I'll let you know what I found
hm, this is odd ... onMessage's parameters are Connection & Data, see
https://www.domoticz.com/wiki/Developing_a_Python_plugin
There have been changes in the Python API, maybe you're using a really old Domoticz Version? I'm on Version: 3.8823 (Beta).
i reinstalled the last available domoticz for my processor armxp (synology) and DSM 6.1 update 5: V3.8805 and now the error isn't the same 2018-01-21 11:00:11.206 Error: (yamaha ) 'onMessage' failed 'ValueError':'invalid literal for int() with base 10: 'X''. 2018-01-21 11:00:11.206 Error: (yamaha ) ----> Line 178 in /usr/local/domoticz/var/plugins/domoticz-yamaha/plugin.py, function onMessage 2018-01-21 11:00:11.206 Error: (yamaha ) ----> Line 100 in /usr/local/domoticz/var/plugins/domoticz-yamaha/plugin.py, function onMessage
perhaps this will help my log : 2018-01-21 11:14:08.675 (yamaha ) Received 72 bytes of data: 2018-01-21 11:14:08.675 (yamaha ) 40 4d 41 49 4e 3a 56 4f 4c 3d 2d 34 31 2e 35 0d 0a 40 4d 41 @MAIN:VOL=-41.5..@MA 2018-01-21 11:14:08.675 (yamaha ) 49 4e 3a 49 4e 50 3d 56 2d 41 55 58 0d 0a 40 4d 41 49 4e 3a IN:INP=V-AUX..@MAIN: 2018-01-21 11:14:08.675 (yamaha ) 4d 55 54 45 3d 4f 66 66 0d 0a 40 4d 41 49 4e 3a 53 4f 55 4e MUTE=Off..@MAIN:SOUN 2018-01-21 11:14:08.675 (yamaha ) 44 50 52 47 3d 44 72 61 6d 61 0d 0a .. .. .. .. .. .. .. .. DPRG=Drama..
ah ok. In line 100: inp = int(s[-1:]) I'm reading the input channel's number, assuming it is one digit, i. e. "HDMI1" or "AV4". But V-AUX has no trailing number ... damn!
let me know i you want that i modify the .py on my site , to test
I added a rudimentary fix - the error should be gone, but the input "V-AUX" is (still) not available from the plugin ... sorry.
i get this error message (every 20s) 2018-01-21 07:44:38.615 Error: (yamaha ) 'onMessage' failed 'TypeError':'onMessage() takes 2 positional arguments but 4 were given'.