ericstaal / domoticz

Domoticz plugins / script
MIT License
6 stars 4 forks source link

plugins LG #4

Open Mayki07 opened 4 years ago

Mayki07 commented 4 years ago

The plugin does not work, I get the following error: 2020-05-13 18:26:12.038 Error: (LG) 'onHeartbeat' failed 'IndexError':'list index out of range'. 2020-05-13 18:26:12.038 Error: (LG) ----> Line 660 in '/home/pi/domoticz/plugins/LG/plugin.py' 2020-05-13 18:26:12.038 Error: (LG) ----> Line 413 in '/home/pi/domoticz/plugins/LG/plugin.py'

ericstaal commented 4 years ago

Have you use this pluygin with an earlier version as well, or deleted devcies from the plugin? If so: -disable the plugin -allow adding new devices -reenable the plugin.

Mayki07 commented 4 years ago

I'm sorry, but I don't understand much. I have LG TV 2019, Domoticz 4.11352, I copied the plugin to the folder / home / pi / domoticz / plugins I have the settings according to the picture. 01 If I enable the plugin, I will immediately receive an error message. 2020-05-13 19:33:10.881 Error: (LG) 'onHeartbeat' failed 'IndexError':'list index out of range'. 2020-05-13 19:33:10.881 Error: (LG) ----> Line 660 in '/home/pi/domoticz/plugins/LG/plugin.py' 2020-05-13 19:33:10.881 Error: (LG) ----> Line 413 in '/home/pi/domoticz/plugins/LG/plugin.py' Don't know what "allow adding new devices" means? Thank you for help.

Mayki07 commented 4 years ago

I updated the plugin to the latest version, now I can run it without error and add devices. Unfortunately, it does not work, I do not see any error in the log, but for example, after pressing the mute button, nothing happens.

EDIT: found error: 2020-05-13 20:06:05.291 Status: (LG) Failed to connect (111) to: 192.168.0.151:8080 with error: Connection refused dropped 0 commands 2020-05-13 20:06:05.291 Status: (LG) onDisconnect 192.168.0.151:8080, no more commands in the queue

ericstaal commented 4 years ago

You can set the debug logging higher and see in the domoticz log fail what is going on.

On Wed, May 13, 2020 at 7:52 PM Mayki07 notifications@github.com wrote:

I updated the plugin to the latest version, now I can run it without error and add devices. Unfortunately, it does not work, I do not see any error in the log, but for example, after pressing the mute button, nothing happens.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/ericstaal/domoticz/issues/4#issuecomment-628149041, or unsubscribe https://github.com/notifications/unsubscribe-auth/AD4ITXUOOP3XV4KNH5LXARTRRLM7TANCNFSM4M75P2LQ .

Mayki07 commented 4 years ago

Debug log: 2020-05-14 17:26:07.886 Status: (LG) Failed to connect (111) to: 192.168.0.151:8080 with error: Connection refused dropped 0 commands 2020-05-14 17:26:07.887 Status: (LG) onDisconnect 192.168.0.151:8080, no more commands in the queue 2020-05-14 17:26:26.906 (LG) Pushing 'onCommandCallback' on to queue 2020-05-14 17:26:26.930 (LG) Processing 'onCommandCallback' message 2020-05-14 17:26:26.930 (LG) Calling message handler 'onCommand'. 2020-05-14 17:26:26.930 (LG) onCommand called for Unit 1: Parameter 'Set Level', Level: 10, Hue: 2020-05-14 17:26:26.931 (LG) Update [LG - Source] from: ('0:'0') to: (10:'10') 2020-05-14 17:26:26.959 (LG) Update [LG - Channel] from: ('0:'Off') to: (0:'TV') 2020-05-14 17:26:26.972 (LG) Set source from 10 to 10 and text to 'TV' 2020-05-14 17:26:26.972 (LG) queuedCommands (list[2]): 2020-05-14 17:26:26.972 (LG) --> [0] (str[4]): 'exit' 2020-05-14 17:26:26.972 (LG) --> [1] (str[8]): 'tv_radio' 2020-05-14 17:26:26.972 (LG) Pushing 'ConnectDirective' on to queue 2020-05-14 17:26:26.972 (LG) checkConnection: Trying to connect 2020-05-14 17:26:26.973 (LG) Processing 'ConnectDirective' message 2020-05-14 17:26:26.973 (LG) Transport set to: 'TCP/IP', 192.168.0.151:8080. 2020-05-14 17:26:26.973 (LG) Connect directive received, action initiated successfully. 2020-05-14 17:26:26.974 (LG) Pushing 'onConnectCallback' on to queue 2020-05-14 17:26:26.974 (LG) Pushing 'DisconnectedEvent' on to queue 2020-05-14 17:26:26.930 Status: (LG) onCommand: last command send 6286.242229223251 seconds ago. Insert additional exit to wake TV 2020-05-14 17:26:27.024 (LG) Processing 'onConnectCallback' message 2020-05-14 17:26:27.024 (LG) Calling message handler 'onConnect'. 2020-05-14 17:26:27.024 (LG) Update [LG - Source] from: ('10:'10') to: (0:'0') 2020-05-14 17:26:27.050 (LG) Update [LG - Channel] from: ('0:'TV') to: (0:'Off') 2020-05-14 17:26:27.060 (LG) Set source from 0 to 0 and text to 'Off' 2020-05-14 17:26:27.061 (LG) Processing 'DisconnectedEvent' message 2020-05-14 17:26:27.061 (LG) Disconnect event received for '192.168.0.151:8080'. 2020-05-14 17:26:27.061 (LG) Pushing 'onDisconnectCallback' on to queue 2020-05-14 17:26:27.061 (LG) Processing 'onDisconnectCallback' message 2020-05-14 17:26:27.061 (LG) Calling message handler 'onDisconnect'. 2020-05-14 17:26:27.815 (LG) Pushing 'onHeartbeatCallback' on to queue 2020-05-14 17:26:27.816 (LG) Processing 'onHeartbeatCallback' message 2020-05-14 17:26:27.816 (LG) Calling message handler 'onHeartbeat'. 2020-05-14 17:26:27.817 (LG) onHeartbeat called, check connection 2020-05-14 17:26:27.817 (LG) Pushing 'ConnectDirective' on to queue 2020-05-14 17:26:27.817 (LG) checkConnection: Trying to connect 2020-05-14 17:26:27.817 (LG) Processing 'ConnectDirective' message 2020-05-14 17:26:27.817 (LG) Transport set to: 'TCP/IP', 192.168.0.151:8080. 2020-05-14 17:26:27.817 (LG) Connect directive received, action initiated successfully. 2020-05-14 17:26:27.819 (LG) Pushing 'onConnectCallback' on to queue 2020-05-14 17:26:27.819 (LG) Pushing 'DisconnectedEvent' on to queue 2020-05-14 17:26:27.868 (LG) Processing 'onConnectCallback' message 2020-05-14 17:26:27.868 (LG) Calling message handler 'onConnect'. 2020-05-14 17:26:27.868 (LG) Processing 'DisconnectedEvent' message 2020-05-14 17:26:27.868 (LG) Disconnect event received for '192.168.0.151:8080'. 2020-05-14 17:26:27.869 (LG) Pushing 'onDisconnectCallback' on to queue 2020-05-14 17:26:27.869 (LG) Processing 'onDisconnectCallback' message 2020-05-14 17:26:27.869 (LG) Calling message handler 'onDisconnect'. 2020-05-14 17:26:27.024 Status: (LG) Failed to connect (111) to: 192.168.0.151:8080 with error: Connection refused dropped 2 commands 2020-05-14 17:26:27.061 Status: (LG) onDisconnect 192.168.0.151:8080, no more commands in the queue 2020-05-14 17:26:27.868 Status: (LG) Failed to connect (111) to: 192.168.0.151:8080 with error: Connection refused dropped 0 commands 2020-05-14 17:26:27.869 Status: (LG) onDisconnect 192.168.0.151:8080, no more commands in the queue 2020-05-14 17:26:47.821 (LG) Pushing 'onHeartbeatCallback' on to queue 2020-05-14 17:26:47.828 (LG) Processing 'onHeartbeatCallback' message 2020-05-14 17:26:47.828 (LG) Calling message handler 'onHeartbeat'. 2020-05-14 17:26:47.829 (LG) onHeartbeat called, check connection 2020-05-14 17:26:47.829 (LG) Pushing 'ConnectDirective' on to queue 2020-05-14 17:26:47.829 (LG) checkConnection: Trying to connect 2020-05-14 17:26:47.829 (LG) Processing 'ConnectDirective' message 2020-05-14 17:26:47.829 (LG) Transport set to: 'TCP/IP', 192.168.0.151:8080. 2020-05-14 17:26:47.829 (LG) Connect directive received, action initiated successfully. 2020-05-14 17:26:47.830 (LG) Pushing 'onConnectCallback' on to queue 2020-05-14 17:26:47.831 (LG) Pushing 'DisconnectedEvent' on to queue 2020-05-14 17:26:47.880 (LG) Processing 'onConnectCallback' message 2020-05-14 17:26:47.880 (LG) Calling message handler 'onConnect'. 2020-05-14 17:26:47.880 (LG) Processing 'DisconnectedEvent' message 2020-05-14 17:26:47.880 (LG) Disconnect event received for '192.168.0.151:8080'. 2020-05-14 17:26:47.880 (LG) Pushing 'onDisconnectCallback' on to queue 2020-05-14 17:26:47.881 (LG) Processing 'onDisconnectCallback' message 2020-05-14 17:26:47.881 (LG) Calling message handler 'onDisconnect'. 2020-05-14 17:26:47.880 Status: (LG) Failed to connect (111) to: 192.168.0.151:8080 with error: Connection refused dropped 0 commands 2020-05-14 17:26:47.881 Status: (LG) onDisconnect 192.168.0.151:8080, no more commands in the queue

ericstaal commented 4 years ago

What kind of TV do you have from which year?

Domoticz cannot connect to the TV, is it turned on? Failed to connect (111) to: 192.168.0.151:8080 with error: Connection refused dropped 2 commands

On Thu, May 14, 2020 at 5:28 PM Mayki07 notifications@github.com wrote:

Debug log: 2020-05-14 17:26:07.886 Status: (LG) Failed to connect (111) to: 192.168.0.151:8080 with error: Connection refused dropped 0 commands 2020-05-14 17:26:07.887 Status: (LG) onDisconnect 192.168.0.151:8080, no more commands in the queue 2020-05-14 17:26:26.906 (LG) Pushing 'onCommandCallback' on to queue 2020-05-14 17:26:26.930 (LG) Processing 'onCommandCallback' message 2020-05-14 17:26:26.930 (LG) Calling message handler 'onCommand'. 2020-05-14 17:26:26.930 (LG) onCommand called for Unit 1: Parameter 'Set Level', Level: 10, Hue: 2020-05-14 17:26:26.931 (LG) Update [LG - Source] from: ('0:'0') to: (10:'10') 2020-05-14 17:26:26.959 (LG) Update [LG - Channel] from: ('0:'Off') to: (0:'TV') 2020-05-14 17:26:26.972 (LG) Set source from 10 to 10 and text to 'TV' 2020-05-14 17:26:26.972 (LG) queuedCommands (list[2]): 2020-05-14 17:26:26.972 (LG) --> [0] (str[4]): 'exit' 2020-05-14 17:26:26.972 (LG) --> [1] (str[8]): 'tv_radio' 2020-05-14 17:26:26.972 (LG) Pushing 'ConnectDirective' on to queue 2020-05-14 17:26:26.972 (LG) checkConnection: Trying to connect 2020-05-14 17:26:26.973 (LG) Processing 'ConnectDirective' message 2020-05-14 17:26:26.973 (LG) Transport set to: 'TCP/IP', 192.168.0.151:8080. 2020-05-14 17:26:26.973 (LG) Connect directive received, action initiated successfully. 2020-05-14 17:26:26.974 (LG) Pushing 'onConnectCallback' on to queue 2020-05-14 17:26:26.974 (LG) Pushing 'DisconnectedEvent' on to queue 2020-05-14 17:26:26.930 Status: (LG) onCommand: last command send 6286.242229223251 seconds ago. Insert additional exit to wake TV 2020-05-14 17:26:27.024 (LG) Processing 'onConnectCallback' message 2020-05-14 17:26:27.024 (LG) Calling message handler 'onConnect'. 2020-05-14 17:26:27.024 (LG) Update [LG - Source] from: ('10:'10') to: (0:'0') 2020-05-14 17:26:27.050 (LG) Update [LG - Channel] from: ('0:'TV') to: (0:'Off') 2020-05-14 17:26:27.060 (LG) Set source from 0 to 0 and text to 'Off' 2020-05-14 17:26:27.061 (LG) Processing 'DisconnectedEvent' message 2020-05-14 17:26:27.061 (LG) Disconnect event received for '192.168.0.151:8080'. 2020-05-14 17:26:27.061 (LG) Pushing 'onDisconnectCallback' on to queue 2020-05-14 17:26:27.061 (LG) Processing 'onDisconnectCallback' message 2020-05-14 17:26:27.061 (LG) Calling message handler 'onDisconnect'. 2020-05-14 17:26:27.815 (LG) Pushing 'onHeartbeatCallback' on to queue 2020-05-14 17:26:27.816 (LG) Processing 'onHeartbeatCallback' message 2020-05-14 17:26:27.816 (LG) Calling message handler 'onHeartbeat'. 2020-05-14 17:26:27.817 (LG) onHeartbeat called, check connection 2020-05-14 17:26:27.817 (LG) Pushing 'ConnectDirective' on to queue 2020-05-14 17:26:27.817 (LG) checkConnection: Trying to connect 2020-05-14 17:26:27.817 (LG) Processing 'ConnectDirective' message 2020-05-14 17:26:27.817 (LG) Transport set to: 'TCP/IP', 192.168.0.151:8080. 2020-05-14 17:26:27.817 (LG) Connect directive received, action initiated successfully. 2020-05-14 17:26:27.819 (LG) Pushing 'onConnectCallback' on to queue 2020-05-14 17:26:27.819 (LG) Pushing 'DisconnectedEvent' on to queue 2020-05-14 17:26:27.868 (LG) Processing 'onConnectCallback' message 2020-05-14 17:26:27.868 (LG) Calling message handler 'onConnect'. 2020-05-14 17:26:27.868 (LG) Processing 'DisconnectedEvent' message 2020-05-14 17:26:27.868 (LG) Disconnect event received for ' 192.168.0.151:8080'. 2020-05-14 17:26:27.869 (LG) Pushing 'onDisconnectCallback' on to queue 2020-05-14 17:26:27.869 (LG) Processing 'onDisconnectCallback' message 2020-05-14 17:26:27.869 (LG) Calling message handler 'onDisconnect'. 2020-05-14 17:26:27.024 Status: (LG) Failed to connect (111) to: 192.168.0.151:8080 with error: Connection refused dropped 2 commands 2020-05-14 17:26:27.061 Status: (LG) onDisconnect 192.168.0.151:8080, no more commands in the queue 2020-05-14 17:26:27.868 Status: (LG) Failed to connect (111) to: 192.168.0.151:8080 with error: Connection refused dropped 0 commands 2020-05-14 17:26:27.869 Status: (LG) onDisconnect 192.168.0.151:8080, no more commands in the queue 2020-05-14 17:26:47.821 (LG) Pushing 'onHeartbeatCallback' on to queue 2020-05-14 17:26:47.828 (LG) Processing 'onHeartbeatCallback' message 2020-05-14 17:26:47.828 (LG) Calling message handler 'onHeartbeat'. 2020-05-14 17:26:47.829 (LG) onHeartbeat called, check connection 2020-05-14 17:26:47.829 (LG) Pushing 'ConnectDirective' on to queue 2020-05-14 17:26:47.829 (LG) checkConnection: Trying to connect 2020-05-14 17:26:47.829 (LG) Processing 'ConnectDirective' message 2020-05-14 17:26:47.829 (LG) Transport set to: 'TCP/IP', 192.168.0.151:8080. 2020-05-14 17:26:47.829 (LG) Connect directive received, action initiated successfully. 2020-05-14 17:26:47.830 (LG) Pushing 'onConnectCallback' on to queue 2020-05-14 17:26:47.831 (LG) Pushing 'DisconnectedEvent' on to queue 2020-05-14 17:26:47.880 (LG) Processing 'onConnectCallback' message 2020-05-14 17:26:47.880 (LG) Calling message handler 'onConnect'. 2020-05-14 17:26:47.880 (LG) Processing 'DisconnectedEvent' message 2020-05-14 17:26:47.880 (LG) Disconnect event received for ' 192.168.0.151:8080'. 2020-05-14 17:26:47.880 (LG) Pushing 'onDisconnectCallback' on to queue 2020-05-14 17:26:47.881 (LG) Processing 'onDisconnectCallback' message 2020-05-14 17:26:47.881 (LG) Calling message handler 'onDisconnect'. 2020-05-14 17:26:47.880 Status: (LG) Failed to connect (111) to: 192.168.0.151:8080 with error: Connection refused dropped 0 commands 2020-05-14 17:26:47.881 Status: (LG) onDisconnect 192.168.0.151:8080, no more commands in the queue

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/ericstaal/domoticz/issues/4#issuecomment-628710101, or unsubscribe https://github.com/notifications/unsubscribe-auth/AD4ITXS6H3ZVBW7Z2EECHOLRRQEYDANCNFSM4M75P2LQ .

Mayki07 commented 4 years ago

TV is OLEDC9 2019, yes is turned on.

ericstaal commented 4 years ago

If you read the documentation you should know it only works for models till 2011, so the old ones. Newer TVs have a different API

On Thu, May 14, 2020 at 6:57 PM Mayki07 notifications@github.com wrote:

TV is OLEDC9 2019, yes is turned on.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/ericstaal/domoticz/issues/4#issuecomment-628762069, or unsubscribe https://github.com/notifications/unsubscribe-auth/AD4ITXSOMKTU2H7SFKFNDNLRRQPIPANCNFSM4M75P2LQ .

Mayki07 commented 4 years ago

Okay, thank you for your help.