Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

iT600 gateway rejected 'read' command with content '{'requestAttr': 'deviceid', 'id': []}' #3

Closed
d0d0oo opened this issue Sep 8, 2020 · 25 comments

Comments

@d0d0oo
Copy link

d0d0oo commented Sep 8, 2020

Hi, when I launch main.py with demo application and trying to connect to my UGE600 gateway I get error during "read" request. Trace log at the bottom.
The same thing when I try to integrate with home-assistant. There is a issue about that in homeassistant_salus project: konradb3/homeassistant_salus#2
Unfortunately I do not have any python experience and will be glad if someone can help figure out what is wrong.

System information:

  • Host system: Windows 10
  • Python 3.8.3
  • Salus UGE600 gateway
  • UGE600 software version: 020140200226
  • UGE600 coordinator version: 20200115
  • ZigBee chanel: 15
  • Thermostat connected: TS600 (the one and only active component)
  • There are other salus components mapped to UGE600 but they are turned off right now so there are warnings in app,
  • UGE600 has ip from router DHCP, 192.168.1.15 via wifi only,
  • UGE600 is reachable from salus it600 app.
  • http://192.168.1.15 shows only empty single select and "Refresh ID List" button.

Trace log after launching main.py:

C:\Projekty\Python_sandbox\it600>python main.py --host 192.168.1.15 --euid 001E5E0########
DEBUG:pyit600:Trying to connect to gateway at 192.168.1.15
ERROR:pyit600:read failed: {'requestAttr': 'deviceid', 'id': []}
--- Logging error ---
Traceback (most recent call last):
  File "C:\Python38\lib\site-packages\pyit600\gateway.py", line 280, in _make_encrypted_request
    raise IT600CommandError(
pyit600.exceptions.IT600CommandError: iT600 gateway rejected 'read' command with content '{'requestAttr': 'deviceid', 'id': []}'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "C:\Python38\lib\logging\__init__.py", line 1081, in emit
    msg = self.format(record)
  File "C:\Python38\lib\logging\__init__.py", line 925, in format
    return fmt.format(record)
  File "C:\Python38\lib\logging\__init__.py", line 664, in format
    record.message = record.getMessage()
  File "C:\Python38\lib\logging\__init__.py", line 369, in getMessage
    msg = msg % self.args
TypeError: not all arguments converted during string formatting
Call stack:
  File "main.py", line 78, in <module>
    asyncio.run(main())
  File "C:\Python38\lib\asyncio\runners.py", line 43, in run
    return loop.run_until_complete(main)
  File "C:\Python38\lib\asyncio\base_events.py", line 603, in run_until_complete
    self.run_forever()
  File "C:\Python38\lib\asyncio\windows_events.py", line 316, in run_forever
    super().run_forever()
  File "C:\Python38\lib\asyncio\base_events.py", line 570, in run_forever
    self._run_once()
  File "C:\Python38\lib\asyncio\base_events.py", line 1859, in _run_once
    handle._run()
  File "C:\Python38\lib\asyncio\events.py", line 81, in _run
    self._context.run(self._callback, *self._args)
  File "main.py", line 62, in main
    await gateway.poll_status(send_callback=True)
  File "C:\Python38\lib\site-packages\pyit600\gateway.py", line 115, in poll_status
    status = await self._make_encrypted_request(
  File "C:\Python38\lib\site-packages\pyit600\gateway.py", line 291, in _make_encrypted_request
    _LOGGER.error("Exception. %s / %s", type(e), repr(e.args), e)
Message: 'Exception. %s / %s'
Arguments: (<class 'pyit600.exceptions.IT600CommandError'>, '("iT600 gateway rejected \'read\' command with content \'{\'requestAttr\': \'deviceid\', \'id\': []}\'",)', IT600CommandError("iT600 gateway rejected 'read' command with content '{'requestAttr': 'deviceid', 'id': []}'"))
Traceback (most recent call last):
  File "C:\Python38\lib\site-packages\pyit600\gateway.py", line 280, in _make_encrypted_request
    raise IT600CommandError(
pyit600.exceptions.IT600CommandError: iT600 gateway rejected 'read' command with content '{'requestAttr': 'deviceid', 'id': []}'

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "main.py", line 78, in <module>
    asyncio.run(main())
  File "C:\Python38\lib\asyncio\runners.py", line 43, in run
    return loop.run_until_complete(main)
  File "C:\Python38\lib\asyncio\base_events.py", line 616, in run_until_complete
    return future.result()
  File "main.py", line 62, in main
    await gateway.poll_status(send_callback=True)
  File "C:\Python38\lib\site-packages\pyit600\gateway.py", line 115, in poll_status
    status = await self._make_encrypted_request(
  File "C:\Python38\lib\site-packages\pyit600\gateway.py", line 292, in _make_encrypted_request
    raise IT600CommandError(
pyit600.exceptions.IT600CommandError: Unknown error occurred while communicating with iT600 gateway
@jvitkauskas
Copy link
Collaborator

jvitkauskas commented Sep 8, 2020

I guess that my project does not support TS600 thermostats. I have added request/response debugging to the demo main.py. Can you pull latest master and run it with --debug and send me the output? You can redact things you don't like. I only need the response to {"requestAttr": "readall"} request.

I am guessing the problem will be here: https://github.com/jvitkauskas/pyit600/blob/master/pyit600/gateway.py#L114 (your thermostat is probably not of a it600ThermHW kind)

I should also probably modify a code that it won't try to send any requests if no supported thermostats are found.

@d0d0oo
Copy link
Author

d0d0oo commented Sep 8, 2020

I've just send you logs. I thought even if there is unsupported equipment it will be listed somewhere :)

@jvitkauskas
Copy link
Collaborator

jvitkauskas commented Sep 8, 2020

Can you try running main.py from ts600 branch and see if it will work and set your thermostat to 21 degrees? https://github.com/jvitkauskas/pyit600/tree/ts600

@d0d0oo
Copy link
Author

d0d0oo commented Sep 9, 2020

So this is a log from new branch for ts600 after execute main.py trying to change temperature. A listed device id is the right id for ts600 thermostat. I don't understand why this key is incorrect...

C:\Projekty\Python_sandbox\it600>python main.py --host 192.168.1.15 --euid 001E5E0XXXXXXXX
DEBUG:pyit600:Trying to connect to gateway at 192.168.1.15
Got callback for device id: 001e5e09023f74cc
Traceback (most recent call last):
  File "main.py", line 90, in <module>
    asyncio.run(main())
  File "C:\Python38\lib\asyncio\runners.py", line 43, in run
    return loop.run_until_complete(main)
  File "C:\Python38\lib\asyncio\base_events.py", line 616, in run_until_complete
    return future.result()
  File "main.py", line 70, in main
    await gateway.poll_status(send_callback=True)
  File "C:\Python38\lib\site-packages\pyit600\gateway.py", line 142, in poll_status
    current_temperature=th["LocalTemperature_x100"] / 100,
KeyError: 'LocalTemperature_x100'

@jvitkauskas
Copy link
Collaborator

jvitkauskas commented Sep 9, 2020

Ok, it seems like the temperature control is different for that thermostat. I'll help you find out what's needed later. In the meanwhile, can you send me the screenshot of the mobile app showing the thermostat control screen?

@d0d0oo
Copy link
Author

d0d0oo commented Sep 9, 2020

Here you go. Thermostat is paired with one smart relay and three window sensors but right now their are not connected.
Screenshot_2020-09-09-10-48-13-322_com salus connect solution
Screenshot_2020-09-09-10-49-02-541_com salus connect solution

@d0d0oo
Copy link
Author

d0d0oo commented Sep 10, 2020

I've just run main.py several times and get two different responses. One shows error indicating probably connection error (?), and at the next shot I've got probably correct temperature change - my thermostat is configured to max temp 20oC and main.py is trying set 21oC. Despite this temperature changed from 13,5oC to 20oC (which is max). Checked it with different values and it works. The only change during last two days was that I disconnected UGE600 from power.
What is interesting the connection error occurs because I had opened website (http://<UGE600_IP>) with "Refresh Id List" button which is sending some read requests all the time. When I closed it I could control thermostat temperature from main.py .
I will try get some test with other values.
I've tested all three methods:

  • set_climate_device_preset(device_id, preset)
    Works well with three constants but I need to do more tests with changing temperature during "Follow Schedule". When you change temperature during this preset thermostat should set it and change preset to "Untill HH:mm". Sometimes it changes temperature according to current schedule position just after few seconds. I have exactly the same problem with Salus Application.
  • set_climate_device_temperature(device_id, setpoint_celsius)
    Works as it should.
  • set_climate_device_mode(device_id, mode)
    I do not know what is for. When set to "off" it acts like set_climate_device_preset(device_id, "Off") , when set to "heat it" acts like set_climate_device_preset(device_id, "Follow Schedule")
  1. Correct temperature change:
C:\Projekty\Python_sandbox\it600>python main.py --host 192.168.1.15 --euid 001E5EXXXXXXXX
DEBUG:pyit600:Trying to connect to gateway at 192.168.1.15
Got callback for device id: 001e5e09023f74cc
DEBUG:pyit600:Refreshed 1 climate devices
All climate devices:
{'001e5e09023f74cc': ClimateDevice(available=True, name='My', unique_id='001e5e09023f74cc', temperature_unit='°C', precision=0.5, current_temperature=22.5, target_temperature=13.5, max_temp=20.0, min_temp=5.0, hvac_mode='heat', hvac_action='idle', hvac_modes=['off', 'heat'], preset_mode='Permanent Hold', preset_modes=['Follow Schedule', 'Permanent Hold', 'Off'], supported_features=17, device_class='temperature', data={'DeviceType': 100, 'UniID': '001e5e09023f74cc', 'Endpoint': 9})}
Climate device 001e5e09023f74cc status:
ClimateDevice(available=True, name='My', unique_id='001e5e09023f74cc', temperature_unit='°C', precision=0.5, current_temperature=22.5, target_temperature=13.5, max_temp=20.0, min_temp=5.0, hvac_mode='heat', hvac_action='idle', hvac_modes=['off', 'heat'], preset_mode='Permanent Hold', preset_modes=['Follow Schedule', 'Permanent Hold', 'Off'], supported_features=17, device_class='temperature', data={'DeviceType': 100, 'UniID': '001e5e09023f74cc', 'Endpoint': 9})
Setting heating device 001e5e09023f74cc temperature to 21 degrees celsius
  1. Strange error with connection (did not restart UGE600):
C:\Projekty\Python_sandbox\it600>python main.py --host 192.168.1.15 --euid 001E5E09XXXXXXXX
DEBUG:pyit600:Trying to connect to gateway at 192.168.1.15
--- Logging error ---
Traceback (most recent call last):
  File "C:\Python38\lib\site-packages\pyit600\gateway.py", line 278, in _make_encrypted_request
    resp = await self._session.post(
  File "C:\Python38\lib\site-packages\aiohttp\client.py", line 504, in _request
    await resp.start(conn)
  File "C:\Python38\lib\site-packages\aiohttp\client_reqrep.py", line 847, in start
    message, payload = await self._protocol.read()  # type: ignore  # noqa
  File "C:\Python38\lib\site-packages\aiohttp\streams.py", line 591, in read
    await self._waiter
aiohttp.client_exceptions.ServerDisconnectedError

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "C:\Python38\lib\logging\__init__.py", line 1081, in emit
    msg = self.format(record)
  File "C:\Python38\lib\logging\__init__.py", line 925, in format
    return fmt.format(record)
  File "C:\Python38\lib\logging\__init__.py", line 664, in format
    record.message = record.getMessage()
  File "C:\Python38\lib\logging\__init__.py", line 369, in getMessage
    msg = msg % self.args
TypeError: not all arguments converted during string formatting
Call stack:
  File "main.py", line 90, in <module>
    asyncio.run(main())
  File "C:\Python38\lib\asyncio\runners.py", line 43, in run
    return loop.run_until_complete(main)
  File "C:\Python38\lib\asyncio\base_events.py", line 603, in run_until_complete
    self.run_forever()
  File "C:\Python38\lib\asyncio\windows_events.py", line 316, in run_forever
    super().run_forever()
  File "C:\Python38\lib\asyncio\base_events.py", line 570, in run_forever
    self._run_once()
  File "C:\Python38\lib\asyncio\base_events.py", line 1859, in _run_once
    handle._run()
  File "C:\Python38\lib\asyncio\events.py", line 81, in _run
    self._context.run(self._callback, *self._args)
  File "C:\Python38\lib\site-packages\pyit600\gateway.py", line 306, in _make_encrypted_request
    _LOGGER.error("Exception. %s / %s", type(e), repr(e.args), e)
Message: 'Exception. %s / %s'
Arguments: (<class 'aiohttp.client_exceptions.ServerDisconnectedError'>, '()', ServerDisconnectedError())
Traceback (most recent call last):
  File "C:\Python38\lib\site-packages\pyit600\gateway.py", line 278, in _make_encrypted_request
    resp = await self._session.post(
  File "C:\Python38\lib\site-packages\aiohttp\client.py", line 504, in _request
    await resp.start(conn)
  File "C:\Python38\lib\site-packages\aiohttp\client_reqrep.py", line 847, in start
    message, payload = await self._protocol.read()  # type: ignore  # noqa
  File "C:\Python38\lib\site-packages\aiohttp\streams.py", line 591, in read
    await self._waiter
aiohttp.client_exceptions.ServerDisconnectedError

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "main.py", line 90, in <module>
    asyncio.run(main())
  File "C:\Python38\lib\asyncio\runners.py", line 43, in run
    return loop.run_until_complete(main)
  File "C:\Python38\lib\asyncio\base_events.py", line 616, in run_until_complete
    return future.result()
  File "main.py", line 60, in main
    await gateway.connect()
  File "C:\Python38\lib\site-packages\pyit600\gateway.py", line 69, in connect
    all_devices = await self._make_encrypted_request(
  File "C:\Python38\lib\site-packages\pyit600\gateway.py", line 307, in _make_encrypted_request
    raise IT600CommandError(
pyit600.exceptions.IT600CommandError: Unknown error occurred while communicating with iT600 gateway

@d0d0oo
Copy link
Author

d0d0oo commented Sep 11, 2020

So this is a log from new branch for ts600 after execute main.py trying to change temperature. A listed device id is the right id for ts600 thermostat. I don't understand why this key is incorrect...

C:\Projekty\Python_sandbox\it600>python main.py --host 192.168.1.15 --euid 001E5E0XXXXXXXX
DEBUG:pyit600:Trying to connect to gateway at 192.168.1.15
Got callback for device id: 001e5e09023f74cc
Traceback (most recent call last):
  File "main.py", line 90, in <module>
    asyncio.run(main())
  File "C:\Python38\lib\asyncio\runners.py", line 43, in run
    return loop.run_until_complete(main)
  File "C:\Python38\lib\asyncio\base_events.py", line 616, in run_until_complete
    return future.result()
  File "main.py", line 70, in main
    await gateway.poll_status(send_callback=True)
  File "C:\Python38\lib\site-packages\pyit600\gateway.py", line 142, in poll_status
    current_temperature=th["LocalTemperature_x100"] / 100,
KeyError: 'LocalTemperature_x100'

Unfortunately, the above error started reappearing. After restarting the UGE600, everything works as I wrote in the previous comment. Wonder what's going on with this UGE600 gateway...

@jvitkauskas
Copy link
Collaborator

jvitkauskas commented Sep 14, 2020

I recommend not using UGE600 website as it sends unencrypted requests which backend does not understand. Furthermore, I think the gateway strategy is to delay and not to send any response on incorrect data, so you might be unnecessarily DDoSing your gateway.

You are correct that set_climate_device_mode is redundant. I have included it just because home assistant API has a similar method.

Did that strange error occur when you have visited UGE600 website?

@dyrvigk
Copy link

dyrvigk commented Sep 15, 2020

here is log after doing what you asked and run main.py with python3

sudo apt update
sudo apt install git python3 python3-pip
git clone https://github.com/jvitkauskas/pyit600.git
cd pyit600
pip3 install .
python3 main.py --host YOUR_GATEWAYS_IP_ADDRESS_HERE --euid YOUR_GATEWAYS_EUID_HERE --debug

DEBUG:pyit600:Gateway response:
{"status":"success","id":[{"sZDOInfo":{"GatewayNodeDSN_i":"VR00ZN000093518","OnlineStatus_i":1,"JoinConfigEnd":1},"data":{"Endpoint":9,"DeviceType":100,"UniID":"001e5e09025f4c40"},"sZDO":{"JoinConfigVersion_i":"190629","ProtocalType_i":1,"FirmwareVersion":"0000001D","MACAddress":"001e5e09025f4c40","ShortID_d":61919,"LeaveNetwork":0,"LeaveRequest_d":0,"DeviceName":"{"deviceName":"Køkken","ShortID_d":61919}"},"sScheS":{"HeatSchedule3":"0effffffffffffffffffffffffffffffffffffffffffffffffddffffffffffffffffffffffffffffffffffffffffffffffffdd","ScheduleEnable":2,"HeatSchedule1":"0e010600210023001900ffff2100ffff2100ffff1800ffff2100dd0600210023001900ffff2100ffff2100ffff1800ffff2100ffffffffffffffffffffffff","HeatSchedule2":"0effffffffffffffffffffffffffffffffffffffffffffffffddffffffffffffffffffffffffffffffffffffffffffffffffdd"},"DeviceL":{"DeviceEndpointNum_i":1,"getModelIdentifierFlag_i":1,"DeviceSubType":64,"DeviceType":100,"UnquieID":"001e5e09025f4c40","AttributeList":"0001000500080010000b000a0028000300110012002a00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000","ModelIdentifier_i":"SQ610RF"},"sBasicS":{"ModelIdentifier":"SQ610RF","HardwareVersion":"2"},"sEndpt":{"DeviceType":64,"Endpoint_i":9},"sIT600D":{"DeviceIndex":32,"SyncResponseVersion_d":"0000001D","ConnectType_i":3},"sIT600TH":{"Error07":0,"HeatingSetpoint_x100_a":2700,"Error21":0,"Status_d":"71a50d0225500000012700210021000404013030303000004802ffffffffffffffffffffffff010003870005003500030104bccb00000200000000ffffffffffffffffffffffffffffffffff1c","ProgramOperationMode":0,"Error04":0,"Error03":0,"Error01":0,"AutoHeatingSetpoint_x100_a":2100,"Error02":0,"LockKey":0,"Error08":0,"Error06":0,"CoolingSetpoint_x100":2700,"Error09":0,"Error23":0,"SystemMode":4,"Error22":0,"AutoCoolingSetpoint_x100_a":2100,"Error24":0,"Error25":0,"LocalTemperature_x100":2550,"Error30":0,"Error31":0,"Error32":0,"SystemMode_a":4,"CloudySetpoint_x100":0,"PairedTRVShortID":"FFFFFFFFFFFFFFFFFFFFFFFF","HeatingSetpoint_x100":2700,"SunnySetpoint_x100":48,"AutoCoolingSetpoint_x100":2100,"AutoHeatingSetpoint_x100":2100,"RunningState":1,"RunningMode":4,"PairedWCNumber":102,"ScheduleType":1,"HoldType":2,"TimeFormat24Hour":1,"CoolingSetpoint_x100_a":2700,"HoldType_a":2,"LockKey_a":0},"status":"success"},{"sZDOInfo":{"OnlineStatus_i":1,"GatewayNodeDSN_i":"VR00ZN000093518"},"data":{"Endpoint":0,"DeviceType":200,"UniID":"0000000000000000"},"sZDO":{"ProtocalType_i":2,"FirmwareVersion":"20200115","MACAddress":"001e5e0902134bab","ShortID_d":0,"LeaveNetwork":0,"LeaveRequest_d":0,"DeviceName":"{"deviceName":"VR00ZN000093517","ShortID_d":0}"},"DeviceL":{"DeviceEndpointNum_i":1,"getModelIdentifierFlag_i":1,"DeviceSubType":0,"DeviceType":200,"UnquieID":"0000000000000000","AttributeList":"000100040003001100050008000b001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000","ModelIdentifier_i":"SAU2AG1-ZC"},"sEndpt":{"DeviceType":0,"Endpoint_i":0},"sCoord":{"PermitJoinState_d":0,"Channel_d":24,"PANID_d":27580,"Form_d":1,"ErrorCoordUART":0,"TimeFormat24Hour":1,"IdentifyInProgress_i":0},"sBasicS":{"ModelIdentifier":"SAU2AG1-ZC","HardwareVersion":"197"},"sOTA":{"OTAFirmwareURL_d":"http://eu.salusconnect.io/download/firmware/39a1449c-8dba-472f-add8-c76b1c511f71/SAU2AG1-ZC_20200115.tar.gz","OTAFirmwareVersion_d":"20200115","OTAStatus_d":0,"endPoint_i":0}},{"data":{"Endpoint":0,"DeviceType":300,"UniID":"0000000000000000"},"sGateway":{"NetworkWiFiIP":"","GatewaySoftwareVersion":"020140200226","GatewayHardwareVersion":"197","NetworkLANMode":1,"NetworkSSID":"fdb783604bdf1a2e4d6a78802c91ab7b","LocationMode_C":"","NetworkPriDNS":"192.168.1.1","NetworkLANIP":"192.168.1.122","LANConnected_d":1,"TimeStatus_i":2,"NetworkLANMAC":"00:1e:5e:00:eb:65","KeyState_i":0,"DSTEnable_i":1,"NetworkWiFiMAC":"00:1e:5e:00:eb:64","NetworkPassword":"fdb783604bdf1a2e4d6a78802c91ab7b","EnableNetworkReset":0,"WirelessAPpassword":"fdc8db1e464cc8d31676eab97ad74ce1","WiFiConnected_d":0,"DeviceTimeZone_i":3600,"IsRtcRight_i":1,"AylaConnected_i":1,"IsSdCardNormal_i":0,"NetworkLANSubnet":"255.255.255.0","LEDMode":1,"NetworkLANRouterAddr":"192.168.1.1","NetworkSecDNS":"","PhoneLocation":"","ModelIdentifier":"UGE600","LocalModeAccessCode":"2ca44efc0c3316b53e65c02b8307f509145fadc2bcee00a248f12b2676c2f399","WiFiMode":0,"DisableLocalMode":0,"TimeZone":"Europe/Copenhagen","TimeOffset_i":1,"Sunset":"1600191761","Sunrise":"1600145917","OutdoorTemperature":1100.0},"DeviceL":{"DeviceEndpointNum_i":1,"getModelIdentifierFlag_i":1,"DeviceSubType":0,"DeviceType":300,"UnquieID":"0000000000000000","AttributeList":"00010002000b000c001e00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000","ModelIdentifier_i":"SAU2AG1-GW"},"sDebug":{"LocalDebugMsg_d":"Model ID is: SAL2BG1","AylaHeartBeatFrequency":0},"Product":{"Mode":1,"Model":"SAL2BG1"},"sOTA":{"OTAFirmwareURL_d":"http://eu.salusconnect.io/download/firmware/ca6c916a-aae2-41c3-a051-e9ed920c3c8d/SAU2AG1-GW_020140200226.tar.gz","OTAFirmwareVersion_d":"020140200226","OTAStatus_d":0,"endPoint_i":0},"sAyla_i":{"aylaConfigStatus":1,"aylaNetWorkStatus":1,"aylaDeviceID":"AC000W000531357","aylaGateWayDsn":"VR00ZN000093518","aylaTimeConfig":"1,1,60,1603587600","aylaSetUTCTimeStatus":1}}]}

DEBUG:pyit600:Gateway request: POST http://192.168.1.122:80/deviceid/read
{"requestAttr": "deviceid", "id": [{"data": {"Endpoint": 9, "DeviceType": 100, "UniID": "001e5e09025f4c40"}}]}

DEBUG:pyit600:Gateway response:
{"status":"success","id":[{"sZDOInfo":{"GatewayNodeDSN_i":"VR00ZN000093518","OnlineStatus_i":1,"JoinConfigEnd":1},"data":{"Endpoint":9,"DeviceType":100,"UniID":"001e5e09025f4c40"},"sZDO":{"JoinConfigVersion_i":"190629","ProtocalType_i":1,"FirmwareVersion":"0000001D","MACAddress":"001e5e09025f4c40","ShortID_d":61919,"LeaveNetwork":0,"LeaveRequest_d":0,"DeviceName":"{"deviceName":"Køkken","ShortID_d":61919}"},"sScheS":{"HeatSchedule3":"0effffffffffffffffffffffffffffffffffffffffffffffffddffffffffffffffffffffffffffffffffffffffffffffffffdd","ScheduleEnable":2,"HeatSchedule1":"0e010600210023001900ffff2100ffff2100ffff1800ffff2100dd0600210023001900ffff2100ffff2100ffff1800ffff2100ffffffffffffffffffffffff","HeatSchedule2":"0effffffffffffffffffffffffffffffffffffffffffffffffddffffffffffffffffffffffffffffffffffffffffffffffffdd"},"DeviceL":{"DeviceEndpointNum_i":1,"getModelIdentifierFlag_i":1,"DeviceSubType":64,"DeviceType":100,"UnquieID":"001e5e09025f4c40","AttributeList":"0001000500080010000b000a0028000300110012002a00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000","ModelIdentifier_i":"SQ610RF"},"sBasicS":{"ModelIdentifier":"SQ610RF","HardwareVersion":"2"},"sEndpt":{"DeviceType":64,"Endpoint_i":9},"sIT600D":{"DeviceIndex":32,"SyncResponseVersion_d":"0000001D","ConnectType_i":3},"sIT600TH":{"Error07":0,"HeatingSetpoint_x100_a":2700,"Error21":0,"Status_d":"71a50d0225500000012700210021000404013030303000004802ffffffffffffffffffffffff010003870005003500030104bccb00000200000000ffffffffffffffffffffffffffffffffff1c","ProgramOperationMode":0,"Error04":0,"Error03":0,"Error01":0,"AutoHeatingSetpoint_x100_a":2100,"Error02":0,"LockKey":0,"Error08":0,"Error06":0,"CoolingSetpoint_x100":2700,"Error09":0,"Error23":0,"SystemMode":4,"Error22":0,"AutoCoolingSetpoint_x100_a":2100,"Error24":0,"Error25":0,"LocalTemperature_x100":2550,"Error30":0,"Error31":0,"Error32":0,"SystemMode_a":4,"CloudySetpoint_x100":0,"PairedTRVShortID":"FFFFFFFFFFFFFFFFFFFFFFFF","HeatingSetpoint_x100":2700,"SunnySetpoint_x100":48,"AutoCoolingSetpoint_x100":2100,"AutoHeatingSetpoint_x100":2100,"RunningState":1,"RunningMode":4,"PairedWCNumber":102,"ScheduleType":1,"HoldType":2,"TimeFormat24Hour":1,"CoolingSetpoint_x100_a":2700,"HoldType_a":2,"LockKey_a":0},"status":"success"}]}

Traceback (most recent call last):
File "main.py", line 90, in
asyncio.run(main())
File "/usr/lib/python3.8/asyncio/runners.py", line 43, in run
return loop.run_until_complete(main)
File "/usr/lib/python3.8/asyncio/base_events.py", line 616, in run_until_complete
return future.result()
File "main.py", line 70, in main
await gateway.poll_status(send_callback=True)
File "/home/kenn/pyit600/pyit600/gateway.py", line 142, in poll_status
max_temp=th["MaxHeatSetpoint_x100"] / 100,
KeyError: 'MaxHeatSetpoint_x100'

kenn

@dyrvigk
Copy link

dyrvigk commented Sep 15, 2020

all the temperatures in the log file are correct and acording to termostat sq610RF

kenn

@jvitkauskas
Copy link
Collaborator

@dyrvigk what is the maximum and the minimum temperature you can set your thermostat to? Do you have it configurable in Salus App?

@dyrvigk
Copy link

dyrvigk commented Sep 15, 2020 via email

@jvitkauskas
Copy link
Collaborator

@dyrvigk I have made some fallback values for min/max temperature. Get the latest files and try again.

@dyrvigk
Copy link

dyrvigk commented Sep 15, 2020

Hi Now it looks like something happens

DEBUG:pyit600:Gateway response:
{"status":"success","id":[{"sZDOInfo":{"OnlineStatus_i":1,"GatewayNodeDSN_i":"VR00ZN000093518"},"data":{"Endpoint":0,"DeviceType":200,"UniID":"0000000000000000"},"sZDO":{"ProtocalType_i":2,"FirmwareVersion":"20200115","MACAddress":"001e5e0902134bab","ShortID_d":0,"LeaveNetwork":0,"LeaveRequest_d":0,"DeviceName":"{"deviceName":"VR00ZN000093517","ShortID_d":0}"},"DeviceL":{"DeviceEndpointNum_i":1,"getModelIdentifierFlag_i":1,"DeviceSubType":0,"DeviceType":200,"UnquieID":"0000000000000000","AttributeList":"000100040003001100050008000b001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000","ModelIdentifier_i":"SAU2AG1-ZC"},"sEndpt":{"DeviceType":0,"Endpoint_i":0},"sCoord":{"PANID_d":27580,"PermitJoinState_d":0,"Channel_d":24,"PermitJoinTime_i":0,"ReceiveZigbeeCommand_d":"7c0fb809fc25640900087e00800080","Form_d":1,"ErrorCoordUART":0,"TimeFormat24Hour":1,"IdentifyInProgress_i":0},"sBasicS":{"ModelIdentifier":"SAU2AG1-ZC","HardwareVersion":"197"},"sOTA":{"OTAFirmwareURL_d":"http://eu.salusconnect.io/download/firmware/39a1449c-8dba-472f-add8-c76b1c511f71/SAU2AG1-ZC_20200115.tar.gz","OTAFirmwareVersion_d":"20200115","OTAStatus_d":0,"endPoint_i":0}},{"data":{"Endpoint":0,"DeviceType":300,"UniID":"0000000000000000"},"sGateway":{"NetworkWiFiIP":"","GatewaySoftwareVersion":"020140200226","GatewayHardwareVersion":"197","NetworkLANMode":1,"NetworkSSID":"fdb783604bdf1a2e4d6a78802c91ab7b","LocationMode_C":"","NetworkPriDNS":"192.168.1.1","NetworkLANIP":"192.168.1.122","LANConnected_d":1,"TimeStatus_i":2,"NetworkLANMAC":"00:1e:5e:00:eb:65","KeyState_i":0,"DSTEnable_i":1,"NetworkWiFiMAC":"00:1e:5e:00:eb:64","NetworkPassword":"fdb783604bdf1a2e4d6a78802c91ab7b","EnableNetworkReset":0,"WirelessAPpassword":"fdc8db1e464cc8d31676eab97ad74ce1","WiFiConnected_d":0,"DeviceTimeZone_i":3600,"IsRtcRight_i":1,"AylaConnected_i":1,"IsSdCardNormal_i":0,"NetworkLANSubnet":"255.255.255.0","LEDMode":1,"NetworkLANRouterAddr":"192.168.1.1","NetworkSecDNS":"","PhoneLocation":"","ModelIdentifier":"UGE600","LocalModeAccessCode":"2ca44efc0c3316b53e65c02b8307f509145fadc2bcee00a248f12b2676c2f399","WiFiMode":0,"DisableLocalMode":0,"TimeZone":"Europe/Copenhagen","TimeOffset_i":1,"Sunset":"1600191761","Sunrise":"1600145917","OutdoorTemperature":2400.0},"DeviceL":{"DeviceEndpointNum_i":1,"getModelIdentifierFlag_i":1,"DeviceSubType":0,"DeviceType":300,"UnquieID":"0000000000000000","AttributeList":"00010002000b000c001e00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000","ModelIdentifier_i":"SAU2AG1-GW"},"sDebug":{"LocalDebugMsg_d":"Model ID is: SAL2BG1","AylaHeartBeatFrequency":0,"OtherDebugMsg_d":"del device euid:001e5e09025f4c40, shortid: 0x2c08, debug_code:1"},"Product":{"Mode":1,"Model":"SAL2BG1"},"sOTA":{"OTAFirmwareURL_d":"http://eu.salusconnect.io/download/firmware/ca6c916a-aae2-41c3-a051-e9ed920c3c8d/SAU2AG1-GW_020140200226.tar.gz","OTAFirmwareVersion_d":"020140200226","OTAStatus_d":0,"endPoint_i":0},"sAyla_i":{"aylaConfigStatus":1,"aylaNetWorkStatus":1,"aylaDeviceID":"AC000W000531357","aylaGateWayDsn":"VR00ZN000093518","aylaTimeConfig":"1,1,60,1603587600","aylaSetUTCTimeStatus":1}},{"sZDOInfo":{"JoinConfigEnd":1,"OnlineStatus_i":1,"GatewayNodeDSN_i":"VR00ZN000093518"},"data":{"Endpoint":9,"DeviceType":100,"UniID":"001e5e09025f4c40"},"sScheS":{"HeatSchedule3":"03ffffffffffffffffffffffffffffffffffffffffffffffffddffffffffffffffffffffffffffffffffffffffffffffffffdd","ScheduleEnable":1,"HeatSchedule1":"03010600210023001900ffff2100ffff2100ffff2100ffff2100dd0600210023001900ffff2100ffff2100ffff2100ffff2100ffffffffffffffffffffffff","HeatSchedule2":"03ffffffffffffffffffffffffffffffffffffffffffffffffddffffffffffffffffffffffffffffffffffffffffffffffffdd"},"sZDO":{"JoinConfigVersion_i":"190629","ProtocalType_i":1,"FirmwareVersion":"0000001D","MACAddress":"001e5e09025f4c40","ShortID_d":25637,"LeaveNetwork":0,"LeaveRequest_d":0,"DeviceName":"{"deviceName":"SQ610RF Quantum rumtermostat 1","ShortID_d":25637}"},"DeviceL":{"DeviceEndpointNum_i":1,"getModelIdentifierFlag_i":1,"DeviceSubType":64,"DeviceType":100,"UnquieID":"001e5e09025f4c40","AttributeList":"0001000500080010000b000a0028000300110012002a00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000","ModelIdentifier_i":"SQ610RF"},"sBasicS":{"ModelIdentifier":"SQ610RF","HardwareVersion":"2"},"sEndpt":{"DeviceType":64,"Endpoint_i":9},"sIT600D":{"DeviceIndex":32,"SyncResponseVersion_d":"0000001D","ConnectType_i":3},"sIT600TH":{"Status_2_d":"7201010000010500350000000301040027001000060035000500350005000100000001018000000001ff010000000100ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff","SunnySetpoint_x100":52,"AutoCoolingSetpoint_x100":2100,"Error07":0,"HeatingSetpoint_x100_a":2100,"Error21":0,"Status_d":"710b0d0028500000012100210021000400003030303000005202ffffffffffffffffffffffff010003860005003500030104cccf00000000000000ffffffffffffffffffffffffffffffffff1c","ProgramOperationMode":0,"MaxHeatSetpoint_x100_a":3500,"Error04":0,"Error03":0,"Error01":0,"AutoHeatingSetpoint_x100_a":2100,"Error02":0,"LockKey":0,"Error08":0,"Error06":0,"CoolingSetpoint_x100":2100,"OUTSensorType":0,"Error09":0,"Error23":0,"MaxHeatSetpoint_x100":3500,"SystemMode":4,"Error22":0,"AutoCoolingSetpoint_x100_a":2100,"HeatingControl":1,"Error24":0,"Error25":0,"MinCoolSetpoint_x100":500,"Schedule":"7201010000010500350000000301040027001000060035000500350005000100000001018000000001ff010000000100ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff","LocalTemperature_x100":2850,"Error30":0,"Error31":0,"Error32":0,"SystemMode_a":4,"CloudySetpoint_x100":0,"PairedTRVShortID":"FFFFFFFFFFFFFFFFFFFFFFFF","CoolingControl":0,"HeatingSetpoint_x100":2100,"AutoHeatingSetpoint_x100":2100,"RunningState":0,"RunningMode":0,"PairedWCNumber":102,"ScheduleType":1,"HoldType":0,"OUTSensorProbe":0,"TimeFormat24Hour":1,"MinHeatSetpoint_x100":500,"MaxCoolSetpoint_x100":3500,"MinCoolSetpoint_x100_a":500,"CoolingSetpoint_x100_a":2100,"HoldType_a":0,"LockKey_a":0,"TemperatureDisplayMode":0},"sIT600I":{"CommandResponse_d":"42323000"}}]}

DEBUG:pyit600:Gateway request: POST http://192.168.1.122:80/deviceid/read
{"requestAttr": "readall"}

DEBUG:pyit600:Gateway response:
{"status":"success","id":[{"sZDOInfo":{"OnlineStatus_i":1,"GatewayNodeDSN_i":"VR00ZN000093518"},"data":{"Endpoint":0,"DeviceType":200,"UniID":"0000000000000000"},"sZDO":{"ProtocalType_i":2,"FirmwareVersion":"20200115","MACAddress":"001e5e0902134bab","ShortID_d":0,"LeaveNetwork":0,"LeaveRequest_d":0,"DeviceName":"{"deviceName":"VR00ZN000093517","ShortID_d":0}"},"DeviceL":{"DeviceEndpointNum_i":1,"getModelIdentifierFlag_i":1,"DeviceSubType":0,"DeviceType":200,"UnquieID":"0000000000000000","AttributeList":"000100040003001100050008000b001000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000","ModelIdentifier_i":"SAU2AG1-ZC"},"sEndpt":{"DeviceType":0,"Endpoint_i":0},"sCoord":{"PANID_d":27580,"PermitJoinState_d":0,"Channel_d":24,"PermitJoinTime_i":0,"ReceiveZigbeeCommand_d":"7c0fb809fc25640900087e00800080","Form_d":1,"ErrorCoordUART":0,"TimeFormat24Hour":1,"IdentifyInProgress_i":0},"sBasicS":{"ModelIdentifier":"SAU2AG1-ZC","HardwareVersion":"197"},"sOTA":{"OTAFirmwareURL_d":"http://eu.salusconnect.io/download/firmware/39a1449c-8dba-472f-add8-c76b1c511f71/SAU2AG1-ZC_20200115.tar.gz","OTAFirmwareVersion_d":"20200115","OTAStatus_d":0,"endPoint_i":0}},{"data":{"Endpoint":0,"DeviceType":300,"UniID":"0000000000000000"},"sGateway":{"NetworkWiFiIP":"","GatewaySoftwareVersion":"020140200226","GatewayHardwareVersion":"197","NetworkLANMode":1,"NetworkSSID":"fdb783604bdf1a2e4d6a78802c91ab7b","LocationMode_C":"","NetworkPriDNS":"192.168.1.1","NetworkLANIP":"192.168.1.122","LANConnected_d":1,"TimeStatus_i":2,"NetworkLANMAC":"00:1e:5e:00:eb:65","KeyState_i":0,"DSTEnable_i":1,"NetworkWiFiMAC":"00:1e:5e:00:eb:64","NetworkPassword":"fdb783604bdf1a2e4d6a78802c91ab7b","EnableNetworkReset":0,"WirelessAPpassword":"fdc8db1e464cc8d31676eab97ad74ce1","WiFiConnected_d":0,"DeviceTimeZone_i":3600,"IsRtcRight_i":1,"AylaConnected_i":1,"IsSdCardNormal_i":0,"NetworkLANSubnet":"255.255.255.0","LEDMode":1,"NetworkLANRouterAddr":"192.168.1.1","NetworkSecDNS":"","PhoneLocation":"","ModelIdentifier":"UGE600","LocalModeAccessCode":"2ca44efc0c3316b53e65c02b8307f509145fadc2bcee00a248f12b2676c2f399","WiFiMode":0,"DisableLocalMode":0,"TimeZone":"Europe/Copenhagen","TimeOffset_i":1,"Sunset":"1600191761","Sunrise":"1600145917","OutdoorTemperature":2400.0},"DeviceL":{"DeviceEndpointNum_i":1,"getModelIdentifierFlag_i":1,"DeviceSubType":0,"DeviceType":300,"UnquieID":"0000000000000000","AttributeList":"00010002000b000c001e00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000","ModelIdentifier_i":"SAU2AG1-GW"},"sDebug":{"LocalDebugMsg_d":"Model ID is: SAL2BG1","AylaHeartBeatFrequency":0,"OtherDebugMsg_d":"del device euid:001e5e09025f4c40, shortid: 0x2c08, debug_code:1"},"Product":{"Mode":1,"Model":"SAL2BG1"},"sOTA":{"OTAFirmwareURL_d":"http://eu.salusconnect.io/download/firmware/ca6c916a-aae2-41c3-a051-e9ed920c3c8d/SAU2AG1-GW_020140200226.tar.gz","OTAFirmwareVersion_d":"020140200226","OTAStatus_d":0,"endPoint_i":0},"sAyla_i":{"aylaConfigStatus":1,"aylaNetWorkStatus":1,"aylaDeviceID":"AC000W000531357","aylaGateWayDsn":"VR00ZN000093518","aylaTimeConfig":"1,1,60,1603587600","aylaSetUTCTimeStatus":1}},{"sZDOInfo":{"JoinConfigEnd":1,"OnlineStatus_i":1,"GatewayNodeDSN_i":"VR00ZN000093518"},"data":{"Endpoint":9,"DeviceType":100,"UniID":"001e5e09025f4c40"},"sScheS":{"HeatSchedule3":"03ffffffffffffffffffffffffffffffffffffffffffffffffddffffffffffffffffffffffffffffffffffffffffffffffffdd","ScheduleEnable":1,"HeatSchedule1":"03010600210023001900ffff2100ffff2100ffff2100ffff2100dd0600210023001900ffff2100ffff2100ffff2100ffff2100ffffffffffffffffffffffff","HeatSchedule2":"03ffffffffffffffffffffffffffffffffffffffffffffffffddffffffffffffffffffffffffffffffffffffffffffffffffdd"},"sZDO":{"JoinConfigVersion_i":"190629","ProtocalType_i":1,"FirmwareVersion":"0000001D","MACAddress":"001e5e09025f4c40","ShortID_d":25637,"LeaveNetwork":0,"LeaveRequest_d":0,"DeviceName":"{"deviceName":"SQ610RF Quantum rumtermostat 1","ShortID_d":25637}"},"DeviceL":{"DeviceEndpointNum_i":1,"getModelIdentifierFlag_i":1,"DeviceSubType":64,"DeviceType":100,"UnquieID":"001e5e09025f4c40","AttributeList":"0001000500080010000b000a0028000300110012002a00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000","ModelIdentifier_i":"SQ610RF"},"sBasicS":{"ModelIdentifier":"SQ610RF","HardwareVersion":"2"},"sEndpt":{"DeviceType":64,"Endpoint_i":9},"sIT600D":{"DeviceIndex":32,"SyncResponseVersion_d":"0000001D","ConnectType_i":3},"sIT600TH":{"Status_2_d":"7201010000010500350000000301040027001000060035000500350005000100000001018000000001ff010000000100ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff","SunnySetpoint_x100":52,"AutoCoolingSetpoint_x100":2100,"Error07":0,"HeatingSetpoint_x100_a":2100,"Error21":0,"Status_d":"710b0d0028500000012100210021000400003030303000005202ffffffffffffffffffffffff010003860005003500030104cccf00000000000000ffffffffffffffffffffffffffffffffff1c","ProgramOperationMode":0,"MaxHeatSetpoint_x100_a":3500,"Error04":0,"Error03":0,"Error01":0,"AutoHeatingSetpoint_x100_a":2100,"Error02":0,"LockKey":0,"Error08":0,"Error06":0,"CoolingSetpoint_x100":2100,"OUTSensorType":0,"Error09":0,"Error23":0,"MaxHeatSetpoint_x100":3500,"SystemMode":4,"Error22":0,"AutoCoolingSetpoint_x100_a":2100,"HeatingControl":1,"Error24":0,"Error25":0,"MinCoolSetpoint_x100":500,"Schedule":"7201010000010500350000000301040027001000060035000500350005000100000001018000000001ff010000000100ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff","LocalTemperature_x100":2850,"Error30":0,"Error31":0,"Error32":0,"SystemMode_a":4,"CloudySetpoint_x100":0,"PairedTRVShortID":"FFFFFFFFFFFFFFFFFFFFFFFF","CoolingControl":0,"HeatingSetpoint_x100":2100,"AutoHeatingSetpoint_x100":2100,"RunningState":0,"RunningMode":0,"PairedWCNumber":102,"ScheduleType":1,"HoldType":0,"OUTSensorProbe":0,"TimeFormat24Hour":1,"MinHeatSetpoint_x100":500,"MaxCoolSetpoint_x100":3500,"MinCoolSetpoint_x100_a":500,"CoolingSetpoint_x100_a":2100,"HoldType_a":0,"LockKey_a":0,"TemperatureDisplayMode":0},"sIT600I":{"CommandResponse_d":"42323000"}}]}

DEBUG:pyit600:Gateway request: POST http://192.168.1.122:80/deviceid/read
{"requestAttr": "deviceid", "id": [{"data": {"Endpoint": 9, "DeviceType": 100, "UniID": "001e5e09025f4c40"}}]}

DEBUG:pyit600:Gateway response:
{"status":"success","id":[{"sZDOInfo":{"JoinConfigEnd":1,"OnlineStatus_i":1,"GatewayNodeDSN_i":"VR00ZN000093518"},"data":{"Endpoint":9,"DeviceType":100,"UniID":"001e5e09025f4c40"},"sScheS":{"HeatSchedule3":"03ffffffffffffffffffffffffffffffffffffffffffffffffddffffffffffffffffffffffffffffffffffffffffffffffffdd","ScheduleEnable":1,"HeatSchedule1":"03010600210023001900ffff2100ffff2100ffff2100ffff2100dd0600210023001900ffff2100ffff2100ffff2100ffff2100ffffffffffffffffffffffff","HeatSchedule2":"03ffffffffffffffffffffffffffffffffffffffffffffffffddffffffffffffffffffffffffffffffffffffffffffffffffdd"},"sZDO":{"JoinConfigVersion_i":"190629","ProtocalType_i":1,"FirmwareVersion":"0000001D","MACAddress":"001e5e09025f4c40","ShortID_d":25637,"LeaveNetwork":0,"LeaveRequest_d":0,"DeviceName":"{"deviceName":"SQ610RF Quantum rumtermostat 1","ShortID_d":25637}"},"DeviceL":{"DeviceEndpointNum_i":1,"getModelIdentifierFlag_i":1,"DeviceSubType":64,"DeviceType":100,"UnquieID":"001e5e09025f4c40","AttributeList":"0001000500080010000b000a0028000300110012002a00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000","ModelIdentifier_i":"SQ610RF"},"sBasicS":{"ModelIdentifier":"SQ610RF","HardwareVersion":"2"},"sEndpt":{"DeviceType":64,"Endpoint_i":9},"sIT600D":{"DeviceIndex":32,"SyncResponseVersion_d":"0000001D","ConnectType_i":3},"sIT600TH":{"Status_2_d":"7201010000010500350000000301040027001000060035000500350005000100000001018000000001ff010000000100ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff","SunnySetpoint_x100":52,"AutoCoolingSetpoint_x100":2100,"Error07":0,"HeatingSetpoint_x100_a":2100,"Error21":0,"Status_d":"710b0d0028500000012100210021000400003030303000005202ffffffffffffffffffffffff010003860005003500030104cccf00000000000000ffffffffffffffffffffffffffffffffff1c","ProgramOperationMode":0,"MaxHeatSetpoint_x100_a":3500,"Error04":0,"Error03":0,"Error01":0,"AutoHeatingSetpoint_x100_a":2100,"Error02":0,"LockKey":0,"Error08":0,"Error06":0,"CoolingSetpoint_x100":2100,"OUTSensorType":0,"Error09":0,"Error23":0,"MaxHeatSetpoint_x100":3500,"SystemMode":4,"Error22":0,"AutoCoolingSetpoint_x100_a":2100,"HeatingControl":1,"Error24":0,"Error25":0,"MinCoolSetpoint_x100":500,"Schedule":"7201010000010500350000000301040027001000060035000500350005000100000001018000000001ff010000000100ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff","LocalTemperature_x100":2850,"Error30":0,"Error31":0,"Error32":0,"SystemMode_a":4,"CloudySetpoint_x100":0,"PairedTRVShortID":"FFFFFFFFFFFFFFFFFFFFFFFF","CoolingControl":0,"HeatingSetpoint_x100":2100,"AutoHeatingSetpoint_x100":2100,"RunningState":0,"RunningMode":0,"PairedWCNumber":102,"ScheduleType":1,"HoldType":0,"OUTSensorProbe":0,"TimeFormat24Hour":1,"MinHeatSetpoint_x100":500,"MaxCoolSetpoint_x100":3500,"MinCoolSetpoint_x100_a":500,"CoolingSetpoint_x100_a":2100,"HoldType_a":0,"LockKey_a":0,"TemperatureDisplayMode":0},"sIT600I":{"CommandResponse_d":"42323000"},"status":"success"}]}

Got callback for device id: 001e5e09025f4c40
DEBUG:pyit600:Refreshed 1 climate devices
All climate devices:
{'001e5e09025f4c40': ClimateDevice(available=True, name='SQ610RF Quantum rumtermostat 1', unique_id='001e5e09025f4c40', temperature_unit='°C', precision=0.5, current_temperature=28.5, target_temperature=21.0, max_temp=35.0, min_temp=5.0, hvac_mode='heat', hvac_action='idle', hvac_modes=['off', 'heat'], preset_mode='Follow Schedule', preset_modes=['Follow Schedule', 'Permanent Hold', 'Off'], supported_features=17, device_class='temperature', data={'Endpoint': 9, 'DeviceType': 100, 'UniID': '001e5e09025f4c40'})}
Climate device 001e5e09025f4c40 status:
ClimateDevice(available=True, name='SQ610RF Quantum rumtermostat 1', unique_id='001e5e09025f4c40', temperature_unit='°C', precision=0.5, current_temperature=28.5, target_temperature=21.0, max_temp=35.0, min_temp=5.0, hvac_mode='heat', hvac_action='idle', hvac_modes=['off', 'heat'], preset_mode='Follow Schedule', preset_modes=['Follow Schedule', 'Permanent Hold', 'Off'], supported_features=17, device_class='temperature', data={'Endpoint': 9, 'DeviceType': 100, 'UniID': '001e5e09025f4c40'})
Setting heating device 001e5e09025f4c40 temperature to 21 degrees celsius
DEBUG:pyit600:Gateway request: POST http://192.168.1.122:80/deviceid/write
{"requestAttr": "write", "id": [{"data": {"Endpoint": 9, "DeviceType": 100, "UniID": "001e5e09025f4c40"}, "sIT600TH": {"SetHeatingSetpoint_x100": 2100}}]}

DEBUG:pyit600:Gateway response:
{"status":"success","id":[{"status":"success","data":{"Devicetype":100,"Endpoint":9,"UniID":"001e5e09025f4c40\t"}}]}

kenn

@jvitkauskas
Copy link
Collaborator

jvitkauskas commented Sep 15, 2020

@dyrvigk Try adding custom component from my fork to home assistant https://github.com/jvitkauskas/homeassistant_salus

You might need to create custom_components folder if it does not exist in /config

@dyrvigk
Copy link

dyrvigk commented Sep 15, 2020

now it works in homeassistant

do yoy know if it is possibel to get battery status and maby also humidity read and how

i will now try to se if the salus vs20wrf also works also salus same function exatly as the other but with 4 aaa batteries instead of rechargeable

thanks a lot
kenn

@dyrvigk
Copy link

dyrvigk commented Sep 15, 2020

other one also working

@d0d0oo
Copy link
Author

d0d0oo commented Sep 15, 2020

I recommend not using UGE600 website as it sends unencrypted requests which backend does not understand. Furthermore, I think the gateway strategy is to delay and not to send any response on incorrect data, so you might be unnecessarily DDoSing your gateway.

You are correct that set_climate_device_mode is redundant. I have included it just because home assistant API has a similar method.

Did that strange error occur when you have visited UGE600 website?

I would have to make some all day tests with that error. I think it occurs even if do not access UGE600 website, but... I will have to try again.

Strange thing is I added printing some fields from "th" object just before place where error occurs and values were correct despite the error.

As far as "set_climate_device_mode" is concerned I have mentioned that the state of thermostat action/mode is not displayed correctly in HA. I think this method could be for forcing thermostat to start heating or not. In TS600 I recognized two fields representing this state:

  • "RunningState" (128 is off, 129 is heating)
  • "RunningMode" (0 is off, 2(?) is heating)

This is a place which could be corrected in integration with HA with this model.

@jvitkauskas
Copy link
Collaborator

Sorry, didn't see your message. I have fixed RunningState in version 0.0.6. So you can update that in manifest.json or use newer file(s) from my fork https://github.com/jvitkauskas/homeassistant_salus

@dyrvigk
Copy link

dyrvigk commented Sep 16, 2020 via email

@jvitkauskas
Copy link
Collaborator

jvitkauskas commented Sep 17, 2020

@dyrvigk does Salus app show humidity and battery status?

@dyrvigk
Copy link

dyrvigk commented Sep 18, 2020 via email

@jvitkauskas
Copy link
Collaborator

@dyrvigk can you provide me the output and write down the corresponding humidity and battery status? I need several samples to be able to compare the data and find out where it does report it.

@dyrvigk
Copy link

dyrvigk commented Oct 10, 2020

Hi sorry that i dident get back to you on this work has been holding me up i will come back to you later if that is ok

kenn

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants