CCU2 w/ HomeMatic and homematic IP devices

I thinks that’s a MAX! Cube. Those are supported by another component: eQ-3 MAX! - Home Assistant

Little confused about supported/not supported devices …

I read in changelog https://github.com/danielperna84/pyhomematic/blob/master/changelog.txt:
Version 0.1.22 (2017-02-14)

  • Added support for HMIP-eTRV (Homematic IP Thermostat) @braindump

I bought two homematic thermostats for testing HM-CC-RT-DN and HmIP-eTRV-2
These devices are connected to RaspberryMatic 2.29.22.20170902 and both working

Homeassistant 0.53.1 config:

homematic:
  hosts:
    wired:
      ip: 192.168.1.58      
      resolvenames: json
      username: user
      password: pass

Only HM-CC-RT-DN is showing up in homeassistant and works well.
But HmIP-eTRV-2 does not show up :frowning:

Is HmIP-eTRV-2 simply not supported or am i doing something wrong ?

There is a difference between HmIP-eTRV (the supported one) and HmIP-eTRV-2. Maybe not technically, but pyhomematic needs to explicitly know about your version. It will probably work if you make a small change to the pyhomematic library your HASS is using. There should be a file called thermostats.py in the deps/pyhomematic/devicetypes/ folder. Duplicate the line with "HMIP-eTRV": IPThermostat, and add the -2 to your duplicate. After restarting HASS you should get the thermostat.
If HMIP-eTRV-2 doesn’t work, try with HmIP-eTRV-2 (small m). EQ3 is not being consistent with how they are naming the devices.

im running homeassistant in docker - hass.io
The deps dir in config is emty.
Where do i find deps/pyhomematic/devicetypes/ folder ?

thanks

I think in case of hassio it is not possible to manually patch the required file. Is it possible for you to set up a VM for testing this out in a test-environment? There you’d only have to configure the homematic component and see if the devices shows up in the UI after applying the change I have mentioned above.
I’m 99% sure that all we need is adding the extra name of the device. But as said before, EQ3 sometimes is not consistent with the naming, so I don’t want to take the chance and just try it out and create an extra version for every variation.

just tried:
https://home-assistant.io/developers/component_loading/

But its seems pyhomematic is in /usr/lib/python3.6/site-packages/pyhomematic
and not in /usr/lib/python3.6/site-packages/homeassistant/components :frowning:

another way to patch this file i have overseen ?

if no i will install a test-homeasistant tomorrow without hass-io and give it a try

Components are the parts of HASS that provide the needed functionality. In case of Homematic it needs the pyhomematic library, which handle the communication with the CCU. And thr problem with your thermostat is, that pyhomematic does not know about your thermostat. Hence that’s where the patching has to be done.
I haven’t worked much wit hassio, so I don’t know if there’s a workaround. But I think there is none. So to my knowledge there’s no other way than having a separate testing environment.

working !

HmIP-eTRV-2 Firmware-Version:1.6.3
RaspberryMatic 2.29.22.20170902

configuration.yaml :

homematic:
  hosts:
    wireless:
      ip: 192.168.1.58
      resolvenames: json
      username: user
      password: pass
    ip:
      ip: 192.168.1.58
      resolvenames: json
      username: user
      password: pass
      port: 2010

thermostats.py :

DEVICETYPES = {
    "HM-CC-RT-DN": Thermostat,
    "HM-CC-RT-DN-BoM": Thermostat,
    "HM-TC-IT-WM-W-EU": ThermostatWall,
    "HM-CC-TC": ThermostatWall2,
    "ZEL STG RM FWT": ThermostatWall2,
    "BC-RT-TRX-CyG": MAXThermostat,
    "BC-RT-TRX-CyG-2": MAXThermostat,
    "BC-RT-TRX-CyG-3": MAXThermostat,
    "BC-RT-TRX-CyG-4": MAXThermostat,
    "BC-RT-TRX-CyN": MAXThermostat,
    "BC-TC-C-WM-2": MAXWallThermostat,
    "BC-TC-C-WM-4": MAXWallThermostat,
    "HMIP-eTRV": IPThermostat,
    "HmIP-eTRV-2": IPThermostat,
    "HmIP-STHD": IPThermostatWall
}

States in homeassistant:

assumed_state: false
current_temperature: 18
id: 
temperature: 17
operation_list: boost
operation_mode: auto
min_temp: 4.5
mode: Auto
max_temp: 30.5
rssi: -23
proxy: ip
unit_of_measurement: °C
friendly_name: HmIP-eTRV-2 
valve: 2

Setting temperature in homeassistant is working.

But in homeassistant HmIP-eTRV-2 only shows: operation_list: boost
and no battery in states.
HM-CC-RT-DN - operation_list: boost,manual,comfort,lowering,auto
battery: 3.2

thats disappointing - battery and other modes not implemented ?

Working partly :frowning:

Homeassistant log:

2017-09-18 10:44:22 ERROR (Thread-9) [pyhomematic.devicetypes.generic] HMGeneric.getValue: CONTROL_MODE on 000xxxxxxxxxx:1 Exception: <Fault -5: ‘Unknown Parameter value for value key: CONTROL_MODE’>

Good to hear that basic functionality is working. As for the control-modes: until now nobody has taken care of the different modes for IP devices. If you want to you can fork pyhomematic and work on the implementation. :slight_smile:

I think i wasted my time with HmIP-eTRV-2
bought it for test and compare it to HM-CC-RT-DN and have a look in the ‘world’ of EQ-3 devices

EQ-3 sent a HmIP-eTRV-2 with nearly one year old firmware with bugs - updating firmware took 18h …
HmIP-eTRV-2 cost about 15% more
HM-CC-RT-DN worked out of the box with temperatureprofile for week - HmIP-eTRV-2 results in renaming my office-room to sauna …

HM-CC-RT-DN is exactly doing what i want since last days and is working in homeassistant/iobroker/RaspberryMatic

I think u should remove HmIP-eTRV-2 from device list cause in homeassistant it does not show battery state and valve attribute is always at 4 - no change when i manually set OFF or BOOST - in RaspberryMatic it returns corect values

The main features of a thermostat are setting a target temperature and reading the current temperature. Are those two values correct? If so, I would keep it. The other values can be fixed later on. The battery level is missing from a lot of devices since it hasn’t been implemented. A few missing values are no dealbreaker if the main functionality is provided. After all this is open source, so anybody who wants to fix these minor issues is free to do just that.

Yes, both values are correct - setting boost also working

I will send back the divice on friday - if u like i could do some tests on codechanges (my knowledge in python is very basic)

No, I will leave it as it is for now. If someone needs more functionality, then we will take care of it. :wink:

I had the same problem, and I wanted the operation mode of the hmip-etrv-2 to work in HASS.
I also fixed that the voltage and battery low/high is shown correctly in HASS

I created a PR here and at pyhomematic:


1 Like

Quick question here. I use Homematic at home and have a CCU2.
Also, I am very new to HA.
So in my config.yaml I wrote:

homematic:
  interfaces:
    wireless:
      host: <ccu-ip-address>

After restarting HA, everything was there. Great.
Now today I got myself a HmIP-eTRV-2 and it’s connected to my CCU2 and works there. Now I thought it will automatically show up in HA. But that’s not the case.
So I am wondering what I need to do. Do I need to extend my config file? But as it’s connected to the CCU I though that should be enough?!?
Any help is greatly appreciated! :slight_smile:
Cheers, Georg

Make your config look like this:

homematic:
  interfaces:
    wireless:
      host: <ccu-ip-address>
    ip:
      host: <ccu-ip-addres>
      port: 2010

IP-devices (as well as wired devices and thermostat groups) are accessed by using different ports.

1 Like

Awesome! Worked! :slight_smile: Thanks a lot!!!

It’s me again :slight_smile:
Today I got a new router and the IP-Addresses changed. I used to have them be like 10.0.1.x and not they are 192.168.1.x
So I went ahead and updated my config file with the new ccu-address but it’s not showing up any more in home-assistant. And I have no idea on how to debug something like this?!?
Last week or so I also changed the security of my CCU a bit and require a login now. But it worked until today even with that change. But can that have something todo with it?
I don’t really know where to start looking…

EDIT:
After a bit of digging I found the following in /config/home-assistant.log:

2019-01-23 22:53:21 WARNING (MainThread) [homeassistant.setup] Setup of homematic is taking over 10 seconds.
2019-01-23 22:55:24 WARNING (SyncWorker_16) [pyhomematic._hm] Failed to initialize proxy
2019-01-23 22:57:37 WARNING (SyncWorker_16) [pyhomematic._hm] Failed to initialize proxy

which also maybe explains why my startup-time is soooooo super slow?!?
Are there any other logs that I can have a look at?

After changing a network in such a dramatic way the first thing I would suggest to do is to restart all the relevant devices. Once that is done, ensure you have the correct IP addresses in your configuration. Also don’t forget to adjust firewalls. The CCU has a builtin firewall. There you have to allow access from the new network or at least the new IP of your Home Assistant machine.
The error itself from your log means that Home Assistant is not able to connect to the CCU.

1 Like