Git Product home page Git Product logo

Comments (7)

jghaanstra avatar jghaanstra commented on June 12, 2024

I can confirm this on my Remeha eTwist. No climate device was added and only two entities where added in my case (errors and water temp.). The app recognises the eTwist as model GTW-16 which I'm not sure that is correct as this is a different device. Although I can live without the extra entities not having the climate device unfortunately makes the integration rather useless. Is there something I can do to help, I dont have any real developer skills but I'm willing to test stuff.

I did notice my error is a little different so I'm posting this here as well, perhaps it helps.

bdr_thermostat: Error on device update!
Traceback (most recent call last):
  File "/usr/local/lib/python3.10/site-packages/requests/models.py", line 971, in json
    return complexjson.loads(self.text, **kwargs)
  File "/usr/local/lib/python3.10/site-packages/simplejson/__init__.py", line 525, in loads
    return _default_decoder.decode(s)
  File "/usr/local/lib/python3.10/site-packages/simplejson/decoder.py", line 370, in decode
    obj, end = self.raw_decode(s)
  File "/usr/local/lib/python3.10/site-packages/simplejson/decoder.py", line 400, in raw_decode
    return self.scan_once(s, idx=_w(s, idx).end())
simplejson.errors.JSONDecodeError: Expecting value: line 1 column 1 (char 0)

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 477, in _async_add_entity
    await entity.async_device_update(warning=False)
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 702, in async_device_update
    await task
  File "/config/custom_components/bdr_thermostat/sensor.py", line 93, in async_update
    water_pressure = await self._bdr_api.get_water_pressure()
  File "/config/custom_components/bdr_thermostat/BdrAPI.py", line 240, in get_water_pressure
    return await self.async_get_request(api_endpoint)
  File "/config/custom_components/bdr_thermostat/BdrAPI.py", line 139, in async_get_request
    return response.json() if response else response
  File "/usr/local/lib/python3.10/site-packages/requests/models.py", line 975, in json
    raise RequestsJSONDecodeError(e.msg, e.doc, e.pos)
requests.exceptions.JSONDecodeError: Expecting value: line 1 column 1 (char 0)

So I tried re-adding it but it gave the same result. I did see a new 403 error in the log that is related. Perhaps its an issue with communication with the cloud server of BDR Thermea Group.

ERROR with get request to https://ruapi.remoteapp.bdrthermea.com/v1.0/system/gateway/connection: 403

from bdrthermostatha.

jghaanstra avatar jghaanstra commented on June 12, 2024

Ok, the issue seems to be that the Remeha eTwist uses a different endpoint for the status.

On

api_endpoint = self.capabilities["centralHeatingZones"]["statusUri"]
it should not be api_endpoint = self.capabilities["centralHeatingZones"]["statusUri"] but api_endpoint = self.capabilities["centralHeatingZones"]["uri"] + '/status' to read the status object of the eTwist.

Here is the complete output of the capabilities endpoint.

{
    "centralHeatingZones": [{
        "name": "CIRCA ",
        "uri": "/central-heating-zone/1E1000000000010",
        "coolingSupported": false,
        "timeProgramsUri": "/central-heating-zone/1E1000000000010/time-programs",
        "timeProgramActivitiesUri": "/central-heating-zone/1E1000000000010/time-program-activities",
        "putSetpointScheduleUri": "/central-heating-zone/1E1000000000010/setpoint/schedule",
        "putSetpointManualUri": "/central-heating-zone/1E1000000000010/setpoint/manual",
        "putSetpointAntiFrostUri": "/central-heating-zone/1E1000000000010/setpoint/anti-frost",
        "putSetpointTemporaryOverrideUri": "/central-heating-zone/1E1000000000010/setpoint/temporary-override",
        "putSetpointHolidayUri": "/central-heating-zone/1E1000000000010/setpoint/holiday",
        "paramsMaxPreheatUri": "/central-heating-zone/1E1000000000010/parameters/max-pre-heat",
        "paramsHeatingCurveUri": "/central-heating-zone/1E1000000000010/parameters/heating-curve",
        "paramsHeatingCoolingSpeedUri": "/central-heating-zone/1E1000000000010/parameters/heating-cooling-speed",
        "paramsAntiFrostHolidayUri": "/central-heating-zone/1E1000000000010/parameters/anti-frost-and-holiday-setpoint"
    }],
    "domesticHotWaterZones": [{
        "name": "DHW Primary",
        "uri": "/domestic-hot-water-zone/1E1000000000011",
        "timeProgramsUri": "/domestic-hot-water-zone/1E1000000000011/time-programs",
        "putSetpointScheduleUri": "/domestic-hot-water-zone/1E1000000000011/setpoint/schedule",
        "putSetpointReducedUri": "/domestic-hot-water-zone/1E1000000000011/setpoint/anti-frost",
        "putSetpointComfortUri": "/domestic-hot-water-zone/1E1000000000011/setpoint/comfort",
        "putSetpointTemporaryOverrideUri": "/domestic-hot-water-zone/1E1000000000011/setpoint/temporary-override",
        "putSetpointHolidayUri": "/domestic-hot-water-zone/1E1000000000011/setpoint/holiday",
        "parametersUri": "/domestic-hot-water-zone/1E1000000000011/parameters"
    }],
    "producers": [{
        "name": "GTW-16",
        "statusUri": "/producers/1E1000000000",
        "powerSettingsUri": "/producers/1E1000000000/parameters/power-settings"
    }],
    "system": {
        "waterPressureUri": "/system/water-pressure",
        "gatewayUri": "/system/gateway",
        "historyUri": "/system/errors/history",
        "locationUri": "/system/location",
        "connectionUri": "/system/gateway/connection",
        "errorStatusUri": "/system/error-status",
        "applianceTimeUri": "/system/appliance-time",
        "flowTemperatureUri": "/system/flow-temperature",
        "deviceInformationUri": "/system/device-information"
    }
}

from bdrthermostatha.

rubkec avatar rubkec commented on June 12, 2024

mine works with the etwist, HA recorgnized them as an CU-GH08

from bdrthermostatha.

freitdav avatar freitdav commented on June 12, 2024

Ok, the issue seems to be that the Remeha eTwist uses a different endpoint for the status.

On

api_endpoint = self.capabilities["centralHeatingZones"]["statusUri"]

it should not be api_endpoint = self.capabilities["centralHeatingZones"]["statusUri"] but api_endpoint = self.capabilities["centralHeatingZones"]["uri"] + '/status' to read the status object of the eTwist.

Here is the complete output of the capabilities endpoint.

{
    "centralHeatingZones": [{
        "name": "CIRCA ",
        "uri": "/central-heating-zone/1E1000000000010",
        "coolingSupported": false,
        "timeProgramsUri": "/central-heating-zone/1E1000000000010/time-programs",
        "timeProgramActivitiesUri": "/central-heating-zone/1E1000000000010/time-program-activities",
        "putSetpointScheduleUri": "/central-heating-zone/1E1000000000010/setpoint/schedule",
        "putSetpointManualUri": "/central-heating-zone/1E1000000000010/setpoint/manual",
        "putSetpointAntiFrostUri": "/central-heating-zone/1E1000000000010/setpoint/anti-frost",
        "putSetpointTemporaryOverrideUri": "/central-heating-zone/1E1000000000010/setpoint/temporary-override",
        "putSetpointHolidayUri": "/central-heating-zone/1E1000000000010/setpoint/holiday",
        "paramsMaxPreheatUri": "/central-heating-zone/1E1000000000010/parameters/max-pre-heat",
        "paramsHeatingCurveUri": "/central-heating-zone/1E1000000000010/parameters/heating-curve",
        "paramsHeatingCoolingSpeedUri": "/central-heating-zone/1E1000000000010/parameters/heating-cooling-speed",
        "paramsAntiFrostHolidayUri": "/central-heating-zone/1E1000000000010/parameters/anti-frost-and-holiday-setpoint"
    }],
    "domesticHotWaterZones": [{
        "name": "DHW Primary",
        "uri": "/domestic-hot-water-zone/1E1000000000011",
        "timeProgramsUri": "/domestic-hot-water-zone/1E1000000000011/time-programs",
        "putSetpointScheduleUri": "/domestic-hot-water-zone/1E1000000000011/setpoint/schedule",
        "putSetpointReducedUri": "/domestic-hot-water-zone/1E1000000000011/setpoint/anti-frost",
        "putSetpointComfortUri": "/domestic-hot-water-zone/1E1000000000011/setpoint/comfort",
        "putSetpointTemporaryOverrideUri": "/domestic-hot-water-zone/1E1000000000011/setpoint/temporary-override",
        "putSetpointHolidayUri": "/domestic-hot-water-zone/1E1000000000011/setpoint/holiday",
        "parametersUri": "/domestic-hot-water-zone/1E1000000000011/parameters"
    }],
    "producers": [{
        "name": "GTW-16",
        "statusUri": "/producers/1E1000000000",
        "powerSettingsUri": "/producers/1E1000000000/parameters/power-settings"
    }],
    "system": {
        "waterPressureUri": "/system/water-pressure",
        "gatewayUri": "/system/gateway",
        "historyUri": "/system/errors/history",
        "locationUri": "/system/location",
        "connectionUri": "/system/gateway/connection",
        "errorStatusUri": "/system/error-status",
        "applianceTimeUri": "/system/appliance-time",
        "flowTemperatureUri": "/system/flow-temperature",
        "deviceInformationUri": "/system/device-information"
    }
}

Based on this reply, Remeha eTwist users feel free to change the code accordingly.
Thank you jghaanstra.
Closing this as solved.

from bdrthermostatha.

jghaanstra avatar jghaanstra commented on June 12, 2024

Closing this as solved.
How is this solved? The issue has been identified but not solved in any way.

For people who bump into this issue and have the same unsupported Remeha eTwist model (GTW-16), here is a customized version of the app with a customized status URL and removed waterpressure and outside temp sensor entities (as these are by default not available for this thermostat model and give issue with the current code). Also you will not be able to set the operatingMode as there is no endpoint available to do so (it will return an error). Unfortunately I lack the coding skills to create a pull request to merge support for this model into this component without breaking the support for other devices.

https://github.com/jghaanstra/BDRthermostatHA

from bdrthermostatha.

freitdav avatar freitdav commented on June 12, 2024

As is written in the project's disclaimer - use at your own risk and consider doing changes that suit your needs. Apparently Remeha has little bit different API implementation. I have no means to verify or to test any changes nor the issue itself. You posted all the API endpoints Remeha provides and with that everyone is able to change my code accordingly.
Understand please that this is a hobby project of mine, having only the De Dietrich heat pump and Smart TC App. There are more and more issues with Remeha brand, however I am not an official support nor developer.
Therefore, solved.

from bdrthermostatha.

dacowiec avatar dacowiec commented on June 12, 2024

I've add the change to the api file and can confirm that I can now see the temperature of my etwist.

from bdrthermostatha.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.