Homematic Energy Counter

Hi, I’m trying to use the Homematic Energy Counter attribute in a sensor, but the attribute shows up as :
‘svEnergyCounter_2477_001015699EA294:6’
I think the colon in ‘001015699EA294:6’ causes the configuration to fail.

When I use the svEnergyCounterOldVal_2477 everything works fine and I see the value of the attribute in the sensor.
Any idea how to solve this?
Thanks a lot!

What kind of device do you use? Usually devices with the ENERGY_COUNTER parameter show up as sensor-entities with Wh. So you don’t really need to access those variables manually.

Hi Daniel

Thanks a lot for your reply!
Ok, I didn’t see the ENERGY_COUNTER parameter yet, because the other problem I have, is that my devices don’t show up. I have a few HmIP-PSM actors. But now I just found out that the Swiss version, with the Swiss power plugs, seems to be named HmIP-PSM-CH, which is not listed in your DEVICETYPES

Hi Daniel,

In the actors.py file I added now the HmIP-PSM-CH to the DEVICETYPES and also changed theIPSwitchPowermeter class accordingly and everything is working now. :wink:
Can you please add the HmIP-PSM-CH to the pyhomematic repository?
Thanks a lot
Best regards
Peter

Since I am not sure what you mean by “also changed theIPSwitchPowermeter class accordingly”, could you just fork pyhomematic, add your changes to your fork, and the create a pull request? From my point of view all that is needed would be adding the device to the dictionary at the bottom, so no changes to the class would be necessary.

Ok, in that case I will fork and make a pull request.

In the IPSwitchPowermeter class, the sensorIndex is set to 6 in case of a HMIP-PSM device