[Python] Control Mitsubishi MAC-557IF-E airconditioning

For heating/cooling related questions in Domoticz
echeberri77
Posts: 40
Joined: Friday 09 March 2018 19:52
Target OS: Linux
Domoticz version: 3.9203
Location: Italy
Contact:

Re: [Python] Control Mitsubishi MAC-557IF-E airconditioning

Post by echeberri77 » Saturday 21 April 2018 15:58

gysmo38 wrote:
Monday 16 April 2018 22:25
@echeberri77 Can you put the plugin option debug to true and send me detailed log in PM?

Code: Select all

2018-04-21 15:56:24.402 (Condizionatore salotto) SET COMMAND SEND Power=true&DeviceID=107767&OperationMode=&SetTemperature=&SetFanSpeed=&VaneHorizontal=&VaneVertical=&EffectiveFlags=1&HasPendingCommand=true
2018-04-21 15:56:24.402 (Condizionatore salotto - Mitsu-salotto - Fan) Updating device from 0:'40' to have values 1:'40'.
2018-04-21 15:56:24.402 LUA: Time set to Afternoon
2018-04-21 15:56:24.404 (Condizionatore salotto - Mitsu-salotto - Temp) Updating device from 0:'' to have values 1:''.
2018-04-21 15:56:24.405 (Condizionatore salotto - Mitsu-salotto - Vane Horizontal) Updating device from 0:'40' to have values 1:'40'.
2018-04-21 15:56:24.406 LUA: Time set to Afternoon
2018-04-21 15:56:24.407 (Condizionatore salotto - Mitsu-salotto - Vane Vertical) Updating device from 0:'60' to have values 1:'60'.
2018-04-21 15:56:24.409 (Condizionatore salotto) SET COMMAND SEND Power=true&DeviceID=107767&OperationMode=1&SetTemperature=&SetFanSpeed=&VaneHorizontal=&VaneVertical=&EffectiveFlags=6&HasPendingCommand=true
2018-04-21 15:56:24.409 (Condizionatore salotto) Sending 432 bytes of data
2018-04-21 15:56:24.409 (Condizionatore salotto) Sending 433 bytes of data
2018-04-21 15:56:24.409 LUA: Time set to Afternoon
2018-04-21 15:56:24.411 LUA: Time set to Afternoon
2018-04-21 15:56:24.413 LUA: Time set to Afternoon
2018-04-21 15:56:24.559 (Condizionatore salotto) Received 1012 bytes of data
2018-04-21 15:56:24.560 (Condizionatore salotto) JSON REPLY: {'TemperatureIncrementOverride': 0, 'HideVaneControls': None, 'OperationMode': 0, 'ErrorCode': 8000, 'DefaultHeatingSetTemperature': None, 'SceneOwner': None, 'WeatherObservations': None, 'LastCommunication': '2018-04-21T13:56:05.193', 'NumberOfFanSpeeds': 5, 'DeviceID': 107767, 'Power': True, 'Offline': False, 'VaneHorizontal': 0, 'Scene': None, 'NextCommunication': '2018-04-21T13:57:05.193', 'EffectiveFlags': 1, 'DeviceType': 0, 'Name': None, 'RoomTemperature': 22.5, 'VaneVertical': 0, 'ErrorMessage': None, 'LocalIPAddress': None, 'HideDryModeControl': None, 'HasPendingCommand': True, 'InStandbyMode': False, 'DefaultCoolingSetTemperature': None, 'SetTemperature': 0.0, 'SetFanSpeed': 0, 'RoomTemperatureLabel': 0}
2018-04-21 15:56:24.560 (Condizionatore salotto) TIME OFFSSET :+1
2018-04-21 15:56:24.560 (Condizionatore salotto) Next update for command: 2018-04-21 14:57:05.193
2018-04-21 15:56:24.560 (Condizionatore salotto - Mitsu-salotto - Unit Infos) Updating device from 1:'Update for last command at 2018-04-21 14:49:04.88' to have values 1:'Update for last command at 2018-04-21 14:57:05.193'.
2018-04-21 15:56:24.563 LUA: Time set to Afternoon
2018-04-21 15:56:24.613 (Condizionatore salotto) Received 1012 bytes of data
2018-04-21 15:56:24.613 (Condizionatore salotto) JSON REPLY: {'TemperatureIncrementOverride': 0, 'HideVaneControls': None, 'OperationMode': 1, 'ErrorCode': 8000, 'DefaultHeatingSetTemperature': None, 'SceneOwner': None, 'WeatherObservations': None, 'LastCommunication': '2018-04-21T13:56:05.193', 'NumberOfFanSpeeds': 5, 'DeviceID': 107767, 'Power': True, 'Offline': False, 'VaneHorizontal': 0, 'Scene': None, 'NextCommunication': '2018-04-21T13:57:05.193', 'EffectiveFlags': 6, 'DeviceType': 0, 'Name': None, 'RoomTemperature': 22.5, 'VaneVertical': 0, 'ErrorMessage': None, 'LocalIPAddress': None, 'HideDryModeControl': None, 'HasPendingCommand': True, 'InStandbyMode': False, 'DefaultCoolingSetTemperature': None, 'SetTemperature': 0.0, 'SetFanSpeed': 0, 'RoomTemperatureLabel': 0}
2018-04-21 15:56:24.613 (Condizionatore salotto) TIME OFFSSET :+1
2018-04-21 15:56:24.613 (Condizionatore salotto) Next update for command: 2018-04-21 14:57:05.193
2018-04-21 15:56:24.613 (Condizionatore salotto - Mitsu-salotto - Unit Infos) Updating device from 1:'Update for last command at 2018-04-21 14:57:05.193' to have values 1:'Update for last command at 2018-04-21 14:57:05.193'.
2018-04-21 15:56:24.616 LUA: Time set to Afternoon
2018-04-21 15:56:28.472 (Condizionatore salotto) Current MEL Cloud Key ID:3D8575BCF48844AEA0AB1743B36E5D
2018-04-21 15:56:28.472 (Condizionatore salotto) Sending 294 bytes of data
2018-04-21 15:56:28.622 (Condizionatore salotto) Received 2007 bytes of data
2018-04-21 15:56:28.622 (Condizionatore salotto) JSON REPLY: {'TemperatureIncrementOverride': 0, 'HideVaneControls': False, 'OperationMode': 1, 'ErrorCode': 8000, 'DefaultHeatingSetTemperature': None, 'SceneOwner': None, 'WeatherObservations': [{'Condition': 116, 'Sunset': '2018-04-21T19:48:00', 'ID': 99776263, 'Humidity': 67, 'Date': '2018-04-21T15:00:00', 'ConditionName': 'Partly Cloudy', 'WeatherType': 0, 'Day': 6, 'Sunrise': '2018-04-21T06:22:00', 'Icon': 'wsymbol_0002_sunny_intervals', 'Temperature': 20}, {'Condition': 116, 'Sunset': '2018-04-22T19:49:00', 'ID': 99939027, 'Humidity': 72, 'Date': '2018-04-22T03:00:00', 'ConditionName': 'Partly Cloudy', 'WeatherType': 2, 'Day': 6, 'Sunrise': '2018-04-22T06:21:00', 'Icon': 'wsymbol_0008_clear_sky_night', 'Temperature': 15}, {'Condition': 116, 'Sunset': '2018-04-22T19:49:00', 'ID': 99939031, 'Humidity': 57, 'Date': '2018-04-22T15:00:00', 'ConditionName': 'Partly Cloudy', 'WeatherType': 1, 'Day': 0, 'Sunrise': '2018-04-22T06:21:00', 'Icon': 'wsymbol_0002_sunny_intervals', 'Temperature': 21}, {'Condition': 113, 'Sunset': '2018-04-23T19:49:00', 'ID': 100100219, 'Humidity': 62, 'Date': '2018-04-23T03:00:00', 'ConditionName': 'Clear/Sunny', 'WeatherType': 2, 'Day': 0, 'Sunrise': '2018-04-23T06:20:00', 'Icon': 'wsymbol_0008_clear_sky_night', 'Temperature': 15}], 'LastCommunication': '2018-04-21T13:56:05.193', 'NumberOfFanSpeeds': 5, 'DeviceID': 107767, 'Power': True, 'Offline': False, 'VaneHorizontal': 0, 'Scene': None, 'NextCommunication': '2018-04-21T13:57:05.193', 'EffectiveFlags': 0, 'DeviceType': 0, 'Name': None, 'RoomTemperature': 22.5, 'VaneVertical': 0, 'ErrorMessage': None, 'LocalIPAddress': None, 'HideDryModeControl': False, 'HasPendingCommand': True, 'InStandbyMode': False, 'DefaultCoolingSetTemperature': None, 'SetTemperature': 0.0, 'SetFanSpeed': 0, 'RoomTemperatureLabel': 0}
2018-04-21 15:56:28.622 (Condizionatore salotto) Update unit Mitsu-salotto information.
2018-04-21 15:56:28.622 (Condizionatore salotto) Heartbeat unit info: {'sn': '1710063033', 'power': True, 'macaddr': 'b8:d7:af:4c:88:7a', 'op_mode': 1, 'room_temp': 22.5, 'idoffset': 0, 'name': 'Mitsu-salotto', 'set_temp': 0.0, 'id': 107767, 'building_id': 53422, 'vaneH': 0, 'next_comm': False, 'vaneV': 0, 'set_fan': 0}
2018-04-21 15:56:28.622 (Condizionatore salotto - Mitsu-salotto - Mode) Updating device from 1:'10' to have values 1:'10'.
2018-04-21 15:56:28.629 (Condizionatore salotto - Mitsu-salotto - Fan) Updating device from 1:'40' to have values 1:'50'.
2018-04-21 15:56:28.631 LUA: Time set to Afternoon
2018-04-21 15:56:28.632 Error: (Condizionatore salotto) 'onMessage' failed 'UnboundLocalError':'local variable 'setDomTemp' referenced before assignment'.
2018-04-21 15:56:28.632 Error: (Condizionatore salotto) ----> Line 420 in /home/xavier/domoticz/plugins/Melcloud/plugin.py, function onMessage
2018-04-21 15:56:28.632 Error: (Condizionatore salotto) ----> Line 185 in /home/xavier/domoticz/plugins/Melcloud/plugin.py, function onMessage
2018-04-21 15:56:28.632 Error: (Condizionatore salotto) ----> Line 398 in /home/xavier/domoticz/plugins/Melcloud/plugin.py, function domoticz_sync_switchs
2018-04-21 15:56:28.635 LUA: Time set to Afternoon
2018-04-21 15:56:53.473 (Condizionatore salotto) Current MEL Cloud Key ID:3D8575BCF48844AEA0AB1743B36E5D
2018-04-21 15:56:53.473 (Condizionatore salotto) Sending 294 bytes of data
2018-04-21 15:56:53.623 (Condizionatore salotto) Received 2007 bytes of data
2018-04-21 15:56:53.624 (Condizionatore salotto) JSON REPLY: {'TemperatureIncrementOverride': 0, 'HideVaneControls': False, 'OperationMode': 1, 'ErrorCode': 8000, 'DefaultHeatingSetTemperature': None, 'SceneOwner': None, 'WeatherObservations': [{'Condition': 116, 'Sunset': '2018-04-21T19:48:00', 'ID': 99776263, 'Humidity': 67, 'Date': '2018-04-21T15:00:00', 'ConditionName': 'Partly Cloudy', 'WeatherType': 0, 'Day': 6, 'Sunrise': '2018-04-21T06:22:00', 'Icon': 'wsymbol_0002_sunny_intervals', 'Temperature': 20}, {'Condition': 116, 'Sunset': '2018-04-22T19:49:00', 'ID': 99939027, 'Humidity': 72, 'Date': '2018-04-22T03:00:00', 'ConditionName': 'Partly Cloudy', 'WeatherType': 2, 'Day': 6, 'Sunrise': '2018-04-22T06:21:00', 'Icon': 'wsymbol_0008_clear_sky_night', 'Temperature': 15}, {'Condition': 116, 'Sunset': '2018-04-22T19:49:00', 'ID': 99939031, 'Humidity': 57, 'Date': '2018-04-22T15:00:00', 'ConditionName': 'Partly Cloudy', 'WeatherType': 1, 'Day': 0, 'Sunrise': '2018-04-22T06:21:00', 'Icon': 'wsymbol_0002_sunny_intervals', 'Temperature': 21}, {'Condition': 113, 'Sunset': '2018-04-23T19:49:00', 'ID': 100100219, 'Humidity': 62, 'Date': '2018-04-23T03:00:00', 'ConditionName': 'Clear/Sunny', 'WeatherType': 2, 'Day': 0, 'Sunrise': '2018-04-23T06:20:00', 'Icon': 'wsymbol_0008_clear_sky_night', 'Temperature': 15}], 'LastCommunication': '2018-04-21T13:56:05.193', 'NumberOfFanSpeeds': 5, 'DeviceID': 107767, 'Power': True, 'Offline': False, 'VaneHorizontal': 0, 'Scene': None, 'NextCommunication': '2018-04-21T13:57:05.193', 'EffectiveFlags': 0, 'DeviceType': 0, 'Name': None, 'RoomTemperature': 22.5, 'VaneVertical': 0, 'ErrorMessage': None, 'LocalIPAddress': None, 'HideDryModeControl': False, 'HasPendingCommand': True, 'InStandbyMode': False, 'DefaultCoolingSetTemperature': None, 'SetTemperature': 0.0, 'SetFanSpeed': 0, 'RoomTemperatureLabel': 0}
2018-04-21 15:56:53.624 (Condizionatore salotto) Update unit Mitsu-salotto information.
2018-04-21 15:56:53.624 (Condizionatore salotto) Heartbeat unit info: {'sn': '1710063033', 'power': True, 'macaddr': 'b8:d7:af:4c:88:7a', 'op_mode': 1, 'room_temp': 22.5, 'idoffset': 0, 'name': 'Mitsu-salotto', 'set_temp': 0.0, 'id': 107767, 'building_id': 53422, 'vaneH': 0, 'next_comm': False, 'vaneV': 0, 'set_fan': 0}
2018-04-21 15:56:53.624 (Condizionatore salotto - Mitsu-salotto - Mode) Updating device from 1:'10' to have values 1:'10'.
2018-04-21 15:56:53.628 (Condizionatore salotto - Mitsu-salotto - Fan) Updating device from 1:'50' to have values 1:'50'.
2018-04-21 15:56:53.630 LUA: Time set to Afternoon
2018-04-21 15:56:53.631 Error: (Condizionatore salotto) 'onMessage' failed 'UnboundLocalError':'local variable 'setDomTemp' referenced before assignment'.
2018-04-21 15:56:53.631 Error: (Condizionatore salotto) ----> Line 420 in /home/xavier/domoticz/plugins/Melcloud/plugin.py, function onMessage
2018-04-21 15:56:53.631 Error: (Condizionatore salotto) ----> Line 185 in /home/xavier/domoticz/plugins/Melcloud/plugin.py, function onMessage
2018-04-21 15:56:53.631 Error: (Condizionatore salotto) ----> Line 398 in /home/xavier/domoticz/plugins/Melcloud/plugin.py, function domoticz_sync_switchs
2018-04-21 15:56:53.633 LUA: Time set to Afternoon
2018-04-21 15:57:01.340 User: Admin initiated a switch command (23/NWDScriptRunning/On)
2018-04-21 15:57:01.343 (Hardware) Lighting 1 (NWDScriptRunning)
2018-04-21 15:57:01.344 LUA: Time set to Afternoon
2018-04-21 15:57:15.117 User: Admin initiated a switch command (30/Temperatura/umidità/On)
2018-04-21 15:57:15.153 User: Admin initiated a switch command (24/Iphone di Silvia/On)
2018-04-21 15:57:15.155 (Hardware) Lighting 1 (Iphone di Silvia)
2018-04-21 15:57:15.156 LUA: Time set to Afternoon
2018-04-21 15:57:15.156 EventSystem: Script event triggered: /home/xavier/domoticz/scripts/lua/script_device_presence.lua
2018-04-21 15:57:15.174 (Presenza in casa) Lighting 1 (Presenza in casa)
2018-04-21 15:57:15.175 LUA: Time set to Afternoon
2018-04-21 15:57:15.178 User: Admin initiated a switch command (23/NWDScriptRunning/On)
2018-04-21 15:57:15.180 (Hardware) Lighting 1 (NWDScriptRunning)
2018-04-21 15:57:15.180 LUA: Time set to Afternoon
2018-04-21 15:57:18.471 (Condizionatore salotto) Current MEL Cloud Key ID:3D8575BCF48844AEA0AB1743B36E5D
2018-04-21 15:57:18.471 (Condizionatore salotto) Sending 294 bytes of data
2018-04-21 15:57:18.572 (Condizionatore salotto) Received 2008 bytes of data
2018-04-21 15:57:18.572 (Condizionatore salotto) JSON REPLY: {'TemperatureIncrementOverride': 0, 'HideVaneControls': False, 'OperationMode': 1, 'ErrorCode': 8000, 'DefaultHeatingSetTemperature': None, 'SceneOwner': None, 'WeatherObservations': [{'Condition': 116, 'Sunset': '2018-04-21T19:48:00', 'ID': 99776263, 'Humidity': 67, 'Date': '2018-04-21T15:00:00', 'ConditionName': 'Partly Cloudy', 'WeatherType': 0, 'Day': 6, 'Sunrise': '2018-04-21T06:22:00', 'Icon': 'wsymbol_0002_sunny_intervals', 'Temperature': 20}, {'Condition': 116, 'Sunset': '2018-04-22T19:49:00', 'ID': 99939027, 'Humidity': 72, 'Date': '2018-04-22T03:00:00', 'ConditionName': 'Partly Cloudy', 'WeatherType': 2, 'Day': 6, 'Sunrise': '2018-04-22T06:21:00', 'Icon': 'wsymbol_0008_clear_sky_night', 'Temperature': 15}, {'Condition': 116, 'Sunset': '2018-04-22T19:49:00', 'ID': 99939031, 'Humidity': 57, 'Date': '2018-04-22T15:00:00', 'ConditionName': 'Partly Cloudy', 'WeatherType': 1, 'Day': 0, 'Sunrise': '2018-04-22T06:21:00', 'Icon': 'wsymbol_0002_sunny_intervals', 'Temperature': 21}, {'Condition': 113, 'Sunset': '2018-04-23T19:49:00', 'ID': 100100219, 'Humidity': 62, 'Date': '2018-04-23T03:00:00', 'ConditionName': 'Clear/Sunny', 'WeatherType': 2, 'Day': 0, 'Sunrise': '2018-04-23T06:20:00', 'Icon': 'wsymbol_0008_clear_sky_night', 'Temperature': 15}], 'LastCommunication': '2018-04-21T13:57:05.253', 'NumberOfFanSpeeds': 5, 'DeviceID': 107767, 'Power': True, 'Offline': False, 'VaneHorizontal': 3, 'Scene': None, 'NextCommunication': '2018-04-21T13:58:05.253', 'EffectiveFlags': 0, 'DeviceType': 0, 'Name': None, 'RoomTemperature': 22.5, 'VaneVertical': 4, 'ErrorMessage': None, 'LocalIPAddress': None, 'HideDryModeControl': False, 'HasPendingCommand': False, 'InStandbyMode': False, 'DefaultCoolingSetTemperature': None, 'SetTemperature': 0.0, 'SetFanSpeed': 5, 'RoomTemperatureLabel': 0}
2018-04-21 15:57:18.572 (Condizionatore salotto) Update unit Mitsu-salotto information.
2018-04-21 15:57:18.572 (Condizionatore salotto) Heartbeat unit info: {'sn': '1710063033', 'power': True, 'macaddr': 'b8:d7:af:4c:88:7a', 'op_mode': 1, 'room_temp': 22.5, 'idoffset': 0, 'name': 'Mitsu-salotto', 'set_temp': 0.0, 'id': 107767, 'building_id': 53422, 'vaneH': 3, 'next_comm': False, 'vaneV': 4, 'set_fan': 5}
2018-04-21 15:57:18.572 (Condizionatore salotto - Mitsu-salotto - Mode) Updating device from 1:'10' to have values 1:'10'.
2018-04-21 15:57:18.575 Error: (Condizionatore salotto) 'onMessage' failed 'UnboundLocalError':'local variable 'setDomFan' referenced before assignment'.
2018-04-21 15:57:18.575 Error: (Condizionatore salotto) ----> Line 420 in /home/xavier/domoticz/plugins/Melcloud/plugin.py, function onMessage
2018-04-21 15:57:18.575 Error: (Condizionatore salotto) ----> Line 185 in /home/xavier/domoticz/plugins/Melcloud/plugin.py, function onMessage
2018-04-21 15:57:18.575 Error: (Condizionatore salotto) ----> Line 397 in /home/xavier/domoticz/plugins/Melcloud/plugin.py, function domoticz_sync_switchs
2018-04-21 15:57:18.575 LUA: Time set to Afternoon
2018-04-21 15:57:25.123 Error: WUnderground: Error: No cities match your search query
2018-04-21 15:57:27.818 User: Admin initiated a switch command (35/Condizionatore salotto - Mitsu-salotto - Mode/Set Level)
2018-04-21 15:57:27.840 (Condizionatore salotto) onCommand called for Unit 1: Parameter 'Off', Level: 0
2018-04-21 15:57:27.840 (Condizionatore salotto) Switch Off the unit Mitsu-salottowith ID offset 0
2018-04-21 15:57:27.840 (Condizionatore salotto - Mitsu-salotto - Mode) Updating device from 1:'10' to have values 0:'0'.
2018-04-21 15:57:27.842 (Condizionatore salotto - Mitsu-salotto - Fan) Updating device from 1:'50' to have values 0:'50'.
2018-04-21 15:57:27.843 LUA: Time set to Afternoon
2018-04-21 15:57:27.843 (Condizionatore salotto - Mitsu-salotto - Temp) Updating device from 1:'' to have values 0:''.
2018-04-21 15:57:27.845 (Condizionatore salotto - Mitsu-salotto - Vane Horizontal) Updating device from 1:'40' to have values 0:'40'.
2018-04-21 15:57:27.847 (Condizionatore salotto - Mitsu-salotto - Vane Vertical) Updating device from 1:'60' to have values 0:'60'.
2018-04-21 15:57:27.848 LUA: Time set to Afternoon
2018-04-21 15:57:27.850 (Condizionatore salotto) SET COMMAND SEND Power=false&DeviceID=107767&OperationMode=1&SetTemperature=0.0&SetFanSpeed=5&VaneHorizontal=3&VaneVertical=4&EffectiveFlags=1&HasPendingCommand=true
2018-04-21 15:57:27.850 (Condizionatore salotto) Sending 440 bytes of data
2018-04-21 15:57:27.852 LUA: Time set to Afternoon
2018-04-21 15:57:27.854 LUA: Time set to Afternoon
2018-04-21 15:57:27.857 LUA: Time set to Afternoon
2018-04-21 15:57:28.000 (Condizionatore salotto) Received 1013 bytes of data
2018-04-21 15:57:28.001 (Condizionatore salotto) JSON REPLY: {'TemperatureIncrementOverride': 0, 'HideVaneControls': None, 'OperationMode': 1, 'ErrorCode': 8000, 'DefaultHeatingSetTemperature': None, 'SceneOwner': None, 'WeatherObservations': None, 'LastCommunication': '2018-04-21T13:57:05.253', 'NumberOfFanSpeeds': 5, 'DeviceID': 107767, 'Power': False, 'Offline': False, 'VaneHorizontal': 3, 'Scene': None, 'NextCommunication': '2018-04-21T13:58:05.253', 'EffectiveFlags': 1, 'DeviceType': 0, 'Name': None, 'RoomTemperature': 22.5, 'VaneVertical': 4, 'ErrorMessage': None, 'LocalIPAddress': None, 'HideDryModeControl': None, 'HasPendingCommand': True, 'InStandbyMode': False, 'DefaultCoolingSetTemperature': None, 'SetTemperature': 0.0, 'SetFanSpeed': 5, 'RoomTemperatureLabel': 0}
2018-04-21 15:57:28.001 (Condizionatore salotto) TIME OFFSSET :+1
2018-04-21 15:57:28.001 (Condizionatore salotto) Next update for command: 2018-04-21 14:58:05.253
2018-04-21 15:57:28.001 (Condizionatore salotto - Mitsu-salotto - Unit Infos) Updating device from 1:'Update for last command at 2018-04-21 14:57:05.193' to have values 1:'Update for last command at 2018-04-21 14:58:05.253'.
2018-04-21 15:57:28.004 LUA: Time set to Afternoon
2018-04-21 15:57:43.479 (Condizionatore salotto) Current MEL Cloud Key ID:3D8575BCF48844AEA0AB1743B36E5D
2018-04-21 15:57:43.479 (Condizionatore salotto) Sending 294 bytes of data

Cellipo
Posts: 1
Joined: Sunday 06 May 2018 18:55
Target OS: Raspberry Pi
Domoticz version:
Contact:

Re: [Python] Control Mitsubishi MAC-557IF-E airconditioning

Post by Cellipo » Sunday 06 May 2018 19:38

Hi, i have just installed latest MELCloud plugin and i am experiencing similar errors to the ones reported by echeberri77. (Line 420; 185; 374)
i have a trial split system. With the plugin all the three splits seems to be controlled by commands sent by domoticz but when it comes to read actual status the plugin seems to fail.
In particular if i use the physical remote controller the plugin fail to read the status, if i switch off/on through domoticz it start to read correctly.

@Gysmo are you still working on the plugin, how can i help to fix this "issue" (ex. doing some tests on my configuration)?

hereunder domoticz log:

Code: Select all

2018-05-06 19:19:30.179 (Mithsubishi) Current MEL Cloud Key ID:ECEBFF1FB28340F499638C8D88FB43
2018-05-06 19:19:30.332 (Mithsubishi) Update unit Clima Cameretta information.
2018-05-06 19:19:30.332 Error: (Mithsubishi) 'onMessage' failed 'UnboundLocalError':'local variable 'setModeLevel' referenced before assignment'.
2018-05-06 19:19:30.333 Error: (Mithsubishi) ----> Line 420 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function onMessage
2018-05-06 19:19:30.333 Error: (Mithsubishi) ----> Line 185 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function onMessage
2018-05-06 19:19:30.333 Error: (Mithsubishi) ----> Line 374 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function domoticz_sync_switchs
2018-05-06 19:19:30.384 (Mithsubishi) Update unit ClimaCamera information.
2018-05-06 19:19:30.385 Error: (Mithsubishi) 'onMessage' failed 'UnboundLocalError':'local variable 'setModeLevel' referenced before assignment'.
2018-05-06 19:19:30.385 Error: (Mithsubishi) ----> Line 420 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function onMessage
2018-05-06 19:19:30.385 Error: (Mithsubishi) ----> Line 185 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function onMessage
2018-05-06 19:19:30.385 Error: (Mithsubishi) ----> Line 374 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function domoticz_sync_switchs
2018-05-06 19:19:30.487 (Mithsubishi) Update unit ClimaSoggiorno information.
2018-05-06 19:19:30.496 Error: (Mithsubishi) 'onMessage' failed 'UnboundLocalError':'local variable 'setDomFan' referenced before assignment'.
2018-05-06 19:19:30.497 Error: (Mithsubishi) ----> Line 420 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function onMessage
2018-05-06 19:19:30.497 Error: (Mithsubishi) ----> Line 185 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function onMessage
2018-05-06 19:19:30.497 Error: (Mithsubishi) ----> Line 397 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function domoticz_sync_switchs
2018-05-06 19:19:55.200 (Mithsubishi) Current MEL Cloud Key ID:ECEBFF1FB28340F499638C8D88FB43
2018-05-06 19:19:55.303 (Mithsubishi) Update unit Clima Cameretta information.
2018-05-06 19:19:55.303 Error: (Mithsubishi) 'onMessage' failed 'UnboundLocalError':'local variable 'setModeLevel' referenced before assignment'.
2018-05-06 19:19:55.303 Error: (Mithsubishi) ----> Line 420 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function onMessage
2018-05-06 19:19:55.303 Error: (Mithsubishi) ----> Line 185 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function onMessage
2018-05-06 19:19:55.303 Error: (Mithsubishi) ----> Line 374 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function domoticz_sync_switchs
2018-05-06 19:19:55.405 (Mithsubishi) Update unit ClimaCamera information.
2018-05-06 19:19:55.405 Error: (Mithsubishi) 'onMessage' failed 'UnboundLocalError':'local variable 'setModeLevel' referenced before assignment'.
2018-05-06 19:19:55.406 Error: (Mithsubishi) ----> Line 420 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function onMessage
2018-05-06 19:19:55.406 Error: (Mithsubishi) ----> Line 185 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function onMessage
2018-05-06 19:19:55.406 Error: (Mithsubishi) ----> Line 374 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function domoticz_sync_switchs
2018-05-06 19:19:55.457 (Mithsubishi) Update unit ClimaSoggiorno information.
2018-05-06 19:19:55.467 Error: (Mithsubishi) 'onMessage' failed 'UnboundLocalError':'local variable 'setDomFan' referenced before assignment'.
2018-05-06 19:19:55.467 Error: (Mithsubishi) ----> Line 420 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function onMessage
2018-05-06 19:19:55.467 Error: (Mithsubishi) ----> Line 185 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function onMessage
2018-05-06 19:19:55.467 Error: (Mithsubishi) ----> Line 397 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function domoticz_sync_switchs
2018-05-06 19:20:19.666 User: Admin initiated a switch command (42/Mithsubishi - ClimaCamera - Mode/Set Level)
2018-05-06 19:20:19.716 (Mithsubishi) onCommand called for Unit 8: Parameter 'Set Level', Level: 10
2018-05-06 19:20:19.716 (Mithsubishi) Set to WARM the unit ClimaCamera
2018-05-06 19:20:19.864 (Mithsubishi) Next update for command: 2018-05-06 18:21:17.423
2018-05-06 19:20:19.971 (Mithsubishi) Next update for command: 2018-05-06 18:21:17.423
2018-05-06 19:20:20.179 (Mithsubishi) Current MEL Cloud Key ID:ECEBFF1FB28340F499638C8D88FB43
2018-05-06 19:20:20.331 (Mithsubishi) Update unit Clima Cameretta information.
2018-05-06 19:20:20.331 Error: (Mithsubishi) 'onMessage' failed 'UnboundLocalError':'local variable 'setModeLevel' referenced before assignment'.
2018-05-06 19:20:20.332 Error: (Mithsubishi) ----> Line 420 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function onMessage
2018-05-06 19:20:20.332 Error: (Mithsubishi) ----> Line 185 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function onMessage
2018-05-06 19:20:20.332 Error: (Mithsubishi) ----> Line 374 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function domoticz_sync_switchs
2018-05-06 19:20:20.383 (Mithsubishi) Update unit ClimaCamera information.
2018-05-06 19:20:20.459 (Mithsubishi) Update unit ClimaSoggiorno information.
2018-05-06 19:20:20.464 Error: (Mithsubishi) 'onMessage' failed 'UnboundLocalError':'local variable 'setDomFan' referenced before assignment'.
2018-05-06 19:20:20.464 Error: (Mithsubishi) ----> Line 420 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function onMessage
2018-05-06 19:20:20.464 Error: (Mithsubishi) ----> Line 185 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function onMessage
2018-05-06 19:20:20.464 Error: (Mithsubishi) ----> Line 397 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function domoticz_sync_switchs
2018-05-06 19:20:22.596 User: Admin initiated a switch command (42/Mithsubishi - ClimaCamera - Mode/Set Level)
2018-05-06 19:20:22.619 (Mithsubishi) onCommand called for Unit 8: Parameter 'Off', Level: 0
2018-05-06 19:20:22.619 (Mithsubishi) Switch Off the unit ClimaCamerawith ID offset 7
2018-05-06 19:20:22.746 (Mithsubishi) Next update for command: 2018-05-06 18:21:17.423
2018-05-06 19:20:34.641 User: Admin initiated a switch command (35/Mithsubishi - Clima Cameretta - Mode/Set Level)
2018-05-06 19:20:34.675 (Mithsubishi) onCommand called for Unit 1: Parameter 'Set Level', Level: 10
2018-05-06 19:20:34.675 (Mithsubishi) Set to WARM the unit Clima Cameretta
2018-05-06 19:20:34.817 (Mithsubishi) Next update for command: 2018-05-06 18:21:29.283
2018-05-06 19:20:34.875 (Mithsubishi) Next update for command: 2018-05-06 18:21:29.283
2018-05-06 19:20:37.690 User: Admin initiated a switch command (35/Mithsubishi - Clima Cameretta - Mode/Set Level)
2018-05-06 19:20:37.736 (Mithsubishi) onCommand called for Unit 1: Parameter 'Off', Level: 0
2018-05-06 19:20:37.736 (Mithsubishi) Switch Off the unit Clima Camerettawith ID offset 0
2018-05-06 19:20:37.866 (Mithsubishi) Next update for command: 2018-05-06 18:21:29.283
2018-05-06 19:20:45.186 (Mithsubishi) Current MEL Cloud Key ID:ECEBFF1FB28340F499638C8D88FB43
2018-05-06 19:20:45.289 (Mithsubishi) Update unit Clima Cameretta information.
2018-05-06 19:20:47.251 (Mithsubishi) Update unit ClimaCamera information.
2018-05-06 19:20:47.278 (Mithsubishi) Update unit ClimaSoggiorno information.
2018-05-06 19:20:47.283 Error: (Mithsubishi) 'onMessage' failed 'UnboundLocalError':'local variable 'setDomFan' referenced before assignment'.
2018-05-06 19:20:47.283 Error: (Mithsubishi) ----> Line 420 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function onMessage
2018-05-06 19:20:47.283 Error: (Mithsubishi) ----> Line 185 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function onMessage
2018-05-06 19:20:47.283 Error: (Mithsubishi) ----> Line 397 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function domoticz_sync_switchs
2018-05-06 19:21:10.229 (Mithsubishi) Current MEL Cloud Key ID:ECEBFF1FB28340F499638C8D88FB43
2018-05-06 19:21:10.332 (Mithsubishi) Update unit Clima Cameretta information.
2018-05-06 19:21:10.384 (Mithsubishi) Update unit ClimaCamera information.
2018-05-06 19:21:10.462 (Mithsubishi) Update unit ClimaSoggiorno information.
2018-05-06 19:21:10.468 Error: (Mithsubishi) 'onMessage' failed 'UnboundLocalError':'local variable 'setDomFan' referenced before assignment'.
2018-05-06 19:21:10.468 Error: (Mithsubishi) ----> Line 420 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function onMessage
2018-05-06 19:21:10.468 Error: (Mithsubishi) ----> Line 185 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function onMessage
2018-05-06 19:21:10.468 Error: (Mithsubishi) ----> Line 397 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function domoticz_sync_switchs
2018-05-06 19:21:35.220 (Mithsubishi) Current MEL Cloud Key ID:ECEBFF1FB28340F499638C8D88FB43
2018-05-06 19:21:35.322 (Mithsubishi) Update unit Clima Cameretta information.
2018-05-06 19:21:35.404 (Mithsubishi) Update unit ClimaCamera information.
2018-05-06 19:21:35.437 (Mithsubishi) Update unit ClimaSoggiorno information.
2018-05-06 19:21:35.443 Error: (Mithsubishi) 'onMessage' failed 'UnboundLocalError':'local variable 'setDomFan' referenced before assignment'.
2018-05-06 19:21:35.444 Error: (Mithsubishi) ----> Line 420 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function onMessage
2018-05-06 19:21:35.444 Error: (Mithsubishi) ----> Line 185 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function onMessage
2018-05-06 19:21:35.444 Error: (Mithsubishi) ----> Line 397 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function domoticz_sync_switchs
2018-05-06 19:22:00.198 (Mithsubishi) Current MEL Cloud Key ID:ECEBFF1FB28340F499638C8D88FB43
2018-05-06 19:22:00.301 (Mithsubishi) Update unit Clima Cameretta information.
2018-05-06 19:22:00.354 (Mithsubishi) Update unit ClimaCamera information.
2018-05-06 19:22:00.453 (Mithsubishi) Update unit ClimaSoggiorno information.
2018-05-06 19:22:00.458 Error: (Mithsubishi) 'onMessage' failed 'UnboundLocalError':'local variable 'setDomFan' referenced before assignment'.
2018-05-06 19:22:00.458 Error: (Mithsubishi) ----> Line 420 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function onMessage
2018-05-06 19:22:00.459 Error: (Mithsubishi) ----> Line 185 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function onMessage
2018-05-06 19:22:00.459 Error: (Mithsubishi) ----> Line 397 in /home/pi/domoticz/plugins/MELCloud/plugin.py, function domoticz_sync_switchs
UPDATE: some hours after i found what was the problem in my case. When i was using the remote controller to start the conditioner, it was setted in AUTO mode -> op_mode = 8. That mode is not part of the plugin.

Code: Select all

2018-05-06 21:14:13.400 (Mitsubishi) Update unit ClimaSoggiorno information.
2018-05-06 21:14:13.400 (Mitsubishi) Heartbeat unit info: {'sn': '1710028092', 'set_temp': 16.0, 'name': 'ClimaSoggiorno', [b]'op_mode': 8, [/b]'next_comm': False, 'id': 107925, 'vaneV': 0, 'building_id': 53572, 'set_fan': 0, 'idoffset': 14, 'vaneH': 3, 'power': False, 'room_temp': 22.0, 'macaddr': 'b8:d7:af:49:8f:ab'}

whatisk
Posts: 25
Joined: Sunday 15 October 2017 6:13
Target OS: Linux
Domoticz version: 3.9224
Location: Australia
Contact:

Re: [Python] Control Mitsubishi MAC-557IF-E airconditioning

Post by whatisk » Monday 07 May 2018 0:54

@gysmo38 have responded to your PM. If you don't get it for some reason or need something else let me know :)

miljume
Posts: 79
Joined: Thursday 03 December 2015 22:36
Target OS: Raspberry Pi
Domoticz version: v3.8742
Contact:

Re: [Python] Control Mitsubishi MAC-557IF-E airconditioning

Post by miljume » Tuesday 12 June 2018 14:19

Hello,

I have been running version 0.6 for quite a time now but suddenly i have started to receive the following errors in the log

Code: Select all

2018-06-12 14:09:25.829 Error: (MelCloud) 'onHeartbeat' failed 'TypeError':'Can't convert 'NoneType' object to str implicitly'.
2018-06-12 14:09:25.829 Error: (MelCloud) ----> Line 436 in /home/pi/domoticz/plugins/Melcloud/plugin.py, function onHeartbeat
2018-06-12 14:09:25.829 Error: (MelCloud) ----> Line 295 in /home/pi/domoticz/plugins/Melcloud/plugin.py, function onHeartbeat
Any clues what can be the problem?

miljume
Posts: 79
Joined: Thursday 03 December 2015 22:36
Target OS: Raspberry Pi
Domoticz version: v3.8742
Contact:

Re: [Python] Control Mitsubishi MAC-557IF-E airconditioning

Post by miljume » Tuesday 26 June 2018 11:04

Hello, one more problem with connections

I received

Code: Select all

2018-06-26 11:00:21.573 (MelCloud) MELCloud receive unknonw message with error code 401
And then the melcloud sensors stop updating

miljume
Posts: 79
Joined: Thursday 03 December 2015 22:36
Target OS: Raspberry Pi
Domoticz version: v3.8742
Contact:

Re: [Python] Control Mitsubishi MAC-557IF-E airconditioning

Post by miljume » Tuesday 03 July 2018 12:48

One more error ...

Code: Select all

2018-07-01 19:15:39.593 Error: (MelCloud) 'onMessage' failed 'UnboundLocalError':'local variable 'setModeLevel' referenced before assignment'.
2018-07-01 19:15:39.593 Error: (MelCloud) ----> Line 420 in /home/pi/domoticz/plugins/Melcloud/plugin.py, function onMessage
2018-07-01 19:15:39.593 Error: (MelCloud) ----> Line 185 in /home/pi/domoticz/plugins/Melcloud/plugin.py, function onMessage
2018-07-01 19:15:39.593 Error: (MelCloud) ----> Line 374 in /home/pi/domoticz/plugins/Melcloud/plugin.py, function domoticz_sync_switchs
@gysmo38: Can you please check?

miljume
Posts: 79
Joined: Thursday 03 December 2015 22:36
Target OS: Raspberry Pi
Domoticz version: v3.8742
Contact:

Re: [Python] Control Mitsubishi MAC-557IF-E airconditioning

Post by miljume » Tuesday 10 July 2018 12:38

And one more ...

Code: Select all

2018-07-10 12:31:39.286 Error: (MelCloud) 'onMessage' failed 'UnboundLocalError':'local variable 'setDomTemp' referenced before assignment'.
2018-07-10 12:31:39.286 Error: (MelCloud) ----> Line 420 in /home/pi/domoticz/plugins/Melcloud/plugin.py, function onMessage
2018-07-10 12:31:39.286 Error: (MelCloud) ----> Line 185 in /home/pi/domoticz/plugins/Melcloud/plugin.py, function onMessage
2018-07-10 12:31:39.286 Error: (MelCloud) ----> Line 398 in /home/pi/domoticz/plugins/Melcloud/plugin.py, function domoticz_sync_switchs

miljume
Posts: 79
Joined: Thursday 03 December 2015 22:36
Target OS: Raspberry Pi
Domoticz version: v3.8742
Contact:

Re: [Python] Control Mitsubishi MAC-557IF-E airconditioning

Post by miljume » Friday 13 July 2018 22:56

Another type of error

Code: Select all

2018-07-13 22:53:39.184 Error: (MELCloud Plugin) 'onHeartbeat' failed 'TypeError':'Can't convert 'NoneType' object to str implicitly'.
2018-07-13 22:53:39.184 Error: (MELCloud Plugin) ----> Line 436 in /home/pi/domoticz/plugins/Melcloud/plugin.py, function onHeartbeat
2018-07-13 22:53:39.184 Error: (MELCloud Plugin) ----> Line 295 in /home/pi/domoticz/plugins/Melcloud/plugin.py, function onHeartbeat
Really strange, this plugin was working really great from the beginning but lately it has been spitting errors more or less every day

Really annoying!

raoul
Posts: 3
Joined: Saturday 25 August 2018 10:48
Target OS: Linux
Domoticz version:
Contact:

Re: [Python] Control Mitsubishi MAC-557IF-E airconditioning

Post by raoul » Saturday 25 August 2018 10:51

Hello gysmo,

there is a small bug for people having some special chars in their password.

I solved it using urllib.parse.quote in the login func:

Code: Select all

    def melcloud_login(self):
        data = "AppVersion=1.9.3.0&Email={0}&Password={1}".format(Parameters["Username"],urllib.parse.quote(Parameters["Password"]))
        self.melcloud_send_data(self.melcloud_urls["login"],data,"LOGIN")
        return True

raoul
Posts: 3
Joined: Saturday 25 August 2018 10:48
Target OS: Linux
Domoticz version:
Contact:

Re: [Python] Control Mitsubishi MAC-557IF-E airconditioning

Post by raoul » Saturday 25 August 2018 17:08

Maybe the fan control has an issue to. For setting level 5 correctly, I had to change the line 107 like this:

Code: Select all

    domoticz_levels["fan"] = {"0":1,"10":2,"20":3,"30":4,"40":5,"50":0,"60":1}

mitkodotcom
Posts: 4
Joined: Thursday 14 September 2017 17:50
Target OS: Raspberry Pi
Domoticz version:
Contact:

Re: [Python] Control Mitsubishi MAC-557IF-E airconditioning

Post by mitkodotcom » Monday 29 October 2018 21:54

When I turn on the AC through this plugin, it starts but it does not set the temperature so the temperature stays at 10 degrees (checked with the original melcloud mobile app). I have to explicitly change the temperature after I turn on the unit. Is this the normal and expected behavior?

miroslavpetrov
Posts: 30
Joined: Wednesday 03 February 2016 14:35
Target OS: Raspberry Pi
Domoticz version:
Contact:

Re: [Python] Control Mitsubishi MAC-557IF-E airconditioning

Post by miroslavpetrov » Thursday 08 November 2018 10:40

Thank you for the nice plugin. Unfortunately, I have a problem controlling my ACs from Domoticz. I have 18 ACs PSA-RP140ka connected to my Melcloud account. AC status and room temp updates regularly in Domoticz but when I try to change the setpoint or the mode of the AC, it doesn't respond. I also cannot turn on or off any of the ACs from domoticz. Any suggestions?
Automation Hardware:
Domoticz on Raspberry Pi 3 with HomeBridge.
Zigbee2MQTT + Xiaomi sensors
Fibaro HomeCenter 2 + Fibaro Dimmer2 & Double Switch2 + Aeon Multisensor 6 + Remotec ZXT-120
Eastron SDM230

dextm80
Posts: 104
Joined: Tuesday 24 October 2017 18:32
Target OS: Linux
Domoticz version: 4.10159
Contact:

Re: [Python] Control Mitsubishi MAC-557IF-E airconditioning

Post by dextm80 » Tuesday 13 November 2018 1:42

hy gysmo

Code: Select all

 2018-11-13 00:38:23.411 Status: User: admin initiated a switch command (31/Melcloud - Soggiorno - Mode/Set Level)
2018-11-13 00:38:41.408 (Melcloud) onCommand called for Unit 1: Parameter 'Off', Level: 0
2018-11-13 00:38:41.408 (Melcloud) Switch Off the unit Soggiornowith ID offset 0
2018-11-13 00:38:41.581 Error: (Melcloud) 'onMessage' failed 'ValueError':'invalid literal for int() with base 10: '''.
2018-11-13 00:38:41.581 Error: (Melcloud) ----> Line 444 in '/home/luigi/domoticz/plugins/Melcloud/plugin.py', function onMessage
2018-11-13 00:38:41.581 Error: (Melcloud) ----> Line 208 in '/home/luigi/domoticz/plugins/Melcloud/plugin.py', function onMessage 
issue when i try to set off my machine
Domoticz on AsRock j3455-ITX 8gb ram - Aeotec ZWave Usb Stick - RFLink 433Mhz
1x Fibaro Wall Plug
1x Fibaro Motion Sensor
2x NeoCoolcam Wall Plug
Netatmo Weather Station - Netatmo Thermostat
Philips Hue Bridge

Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests