What is the preferred way to rename z-wave entities?

It’s not just zwave entities but any entity that supports getting a unique id from HA. That includes zigbee, chromecast, NEST among others. All of those need to be changed thru the UI. Everything else is done thru the text config.

Oh wow - actually this was one of the reasons I wanted to get rid of openhab. :roll_eyes:
So I have to rename >300 Z-Wave entities manually and then hope that magic backup button in hassIO ist always working?
Wouldn’t it be actually much easier and faster to suggest or set entity-ids through a config file?

1 Like

@spaceman_spiff

It was easier and faster the way it was done before but for some reason that still eludes me the powers that be decided to make it way more cumbersome for the sake of “consistency”. And for some reason won’t even try to address the concerns that people have with this new way.

Your situation is the exact example I use when I bring this issue up in every thread about this topic. And there’s quite a few of those.

1 Like

This is already annoying me and I am only using and learning hass now for ~6h.
I was really hoping things would be better, now they are just different.

I’ve never used openhab aside from just kind of looking it over and deciding it looked way more complicated than HA but I think that HA is a pretty good system. It’s just this one thing that seems that there is a push to move forward with over the protests of many users.

Well - at least z-wave was way easier to set up. :wink:
I am still struggling how the entities are automatically named.
What does “Exporting” mean?
Also, the energy-reset entity seems to be missing even though it is available in the xml:

<CommandClass id="50" name="COMMAND_CLASS_METER" version="4" request_flags="2" innif="true">
    <Instance index="1" />
    <Value type="decimal" genre="user" instance="1" index="0" label="Energy" units="kWh" read_only="true" write_only="false" verify_changes="false" poll_intensity="0" min="0" max="0" value="0.5" />
    <Value type="decimal" genre="user" instance="1" index="1" label="Previous Reading" units="kWh" read_only="true" write_only="false" verify_changes="false" poll_intensity="0" min="0" max="0" value="0.5" />
    <Value type="int" genre="user" instance="1" index="2" label="Interval" units="seconds" read_only="true" write_only="false" verify_changes="false" poll_intensity="0" min="-2147483648" max="2147483647" value="1" />
    <Value type="decimal" genre="user" instance="1" index="8" label="Power" units="W" read_only="true" write_only="false" verify_changes="false" poll_intensity="0" min="0" max="0" value="0.0" />
    <Value type="bool" genre="user" instance="1" index="32" label="Exporting" units="" read_only="true" write_only="false" verify_changes="false" poll_intensity="0" min="0" max="0" value="False" />
    <Value type="button" genre="system" instance="1" index="33" label="Reset" units="" read_only="false" write_only="true" verify_changes="false" poll_intensity="0" min="0" max="0" />
</CommandClass>

How can I use energy meter reset?

Also I get:

light.fibaro_system_fgrgbwm441_rgbw_controller_level
light.fibaro_system_fgrgbwm441_rgbw_controller_level_4
light.fibaro_system_fgrgbwm441_rgbw_controller_level_5
light.fibaro_system_fgrgbwm441_rgbw_controller_level_6
light.fibaro_system_fgrgbwm441_rgbw_controller_level_7
light.fibaro_system_fgrgbwm441_rgbw_controller_level_8

but the device has five outputs (endpoint 1-5):
General dim-level and one for each channel (rgbw).
What is what and why does it start with 4?
Also it seems that all entities are RGBW-entities when they should be plain dimmers.
How can I convert the entity to dimmer?

Sorry for the many questions but this is very confusing for me.

How many fibaro devices do you have?

In my experience with home assistant and zwave when you include a device you will get several entities per device. They all take the base name based on the manufacturer information in the config directory. Then there will be a extension added to the base name that corresponds to the “function” of that feature (_level, _alarm, _burglar, _alarm_level, etc.). Then if you have several if the same type of device that you add at the same time without changing the node name of the other devices (which we can no longer do since that functionality was just recently removed for some elusive reason) then all of those entities get the same base based on the node name but then appended by a number.

Then you get what looks like might be happening in your example…a bunch of entities that you have no way of knowing what they are functionally and having to manually rename every entity id.

If you look thru your entities you will probably find other fibaro light entities that end with a different extension and number and also a bunch of zwave Fibaro entities that end in different numbers

Its kind of a mess.

Quite a few, but these are the entities of one Node. I used the Z-Wave Node Management to get the entities of the node.
Any idea how to use a dimmer instead of an rgb-picker and how I can use the meter reset?

Edit:
I doublechecked and think I got what you were saying. The naming is indeed a mess :frowning:
The endpoint is shown under entity info which means I have to click all through all the endpoints.

Just for your information my old openhab z-wave config with home assistant equivalents. Maybe this is good input for future improvements.

Type    Entity_ID                        friendly_name                    platform=NODE:ENDPOINT

Dimmer 	Flur_Schuhschrank_Out_All	"Schuhschrank alle [%d]"	{zwave="7:1:command=SWITCH_MULTILEVEL" }
Dimmer 	Flur_Schuhschrank_Out_R		"Schuhschrank Rot [%d]"		{zwave="7:2:command=SWITCH_MULTILEVEL" }
Dimmer 	Flur_Schuhschrank_Out_G		"Schuhschrank Gelb [%d]"	{zwave="7:3:command=SWITCH_MULTILEVEL" }
Dimmer 	Flur_Schuhschrank_Out_B		"Schuhschrank Blau [%d]"	{zwave="7:4:command=SWITCH_MULTILEVEL" }
Dimmer 	Flur_Schuhschrank_Out_W		"Schuhschrank Weiß [%d]"	{zwave="7:5:command=SWITCH_MULTILEVEL" }

All the things you need to back up are in your /config/ folder, so you can back that up outside of Hass.io. If you’re using the snapshot function, you should be copying those snapshots off the Hass.io system, but most people forget to do that.

That said, the entity registry now lives inside .storage/ (so, /config/.storage/). That file is no longer YAML but JSON, and importantly is no longer validated by Home Assistant. You can shut Home Assistant down, and edit that file, but if you break the formatting, you break Home Assistant. Manually editing this file is no longer officially encouraged, but is still possible.

I would love to get a better renaming/cleaning function of the entities. Both Mqtt and Z-wave can be messy and it is very difficult to clean up manually.

Below is one of my z-wave switch that is “Unknown Node”
27-23-22-50

Does any one know where I can rename this node? If I click on the node under Z-Wave devices, it shows up as:
27-23-28-35

As you see “Kontakt Rebekka seng” is listed.

27-23-25-26

This is the node in core.entity_registry
{
“config_entry_id”: “2127c304c60142e28394cab4c4096b76”,
“device_id”: “2c84b93ccabd48c7971e0b51dd053f38”,
“disabled_by”: null,
“entity_id”: “switch.rebekkaseng_switch”,
“name”: “Rebekkaseng”,
“platform”: “zwave”,
“unique_id”: “14-72057594277609472”
},

In z-wave zwcfg_0xecd54037.xml the “Node 14” is listed as:

<Node id="14" name="" location="" basic="4" generic="16" specific="1" type="Binary Power Switch" listening="true" frequentListening="false" beaming="false" routing="true" max_baud_rate="9600" version="2" query_stage="Complete">
	<Manufacturer id="0" name="">
		<Product type="0" id="0" name="" />
	</Manufacturer>
	<CommandClasses>
		<CommandClass id="32" name="COMMAND_CLASS_BASIC" version="1" mapping="37">
			<Instance index="1" />
		</CommandClass>
		<CommandClass id="37" name="COMMAND_CLASS_SWITCH_BINARY" version="1">
			<Instance index="1" />
			<Value type="bool" genre="user" instance="1" index="0" label="Switch" units="" read_only="false" write_only="false" verify_changes="false" poll_intensity="0" min="0" max="0" value="True" />
		</CommandClass>
		<CommandClass id="39" name="COMMAND_CLASS_SWITCH_ALL" version="1">
			<Instance index="1" />
			<Value type="list" genre="system" instance="1" index="0" label="Switch All" units="" read_only="false" write_only="false" verify_changes="false" poll_intensity="0" min="0" max="0" vindex="3" size="1">
				<Item label="Disabled" value="0" />
				<Item label="Off Enabled" value="1" />
				<Item label="On Enabled" value="2" />
				<Item label="On and Off Enabled" value="255" />
			</Value>
		</CommandClass>
	</CommandClasses>
</Node>

Z-wave naming understood SOLVED
PS. Before editing the files listed, you must stop home assistant http://hassio.local:8123/config/core

I will try to explain what I found out

This description is for my z-wave devices node id 14. I have tried to give it different names where ever I could find node id 14 in the different source files.

1: The Title or friendly_name: “Kontakt Rebekka seng” in the image below is collected from config.storage\core.device_registry and the json data:

    {
        "config_entry_id": null,
        "device_id": null,
        "disabled_by": null,
        "entity_id": "zwave.rebekkaseng",
        "name": "Kontakt Rebekka seng",
        "platform": "zwave",
        "unique_id": "node-14"
    },

2: The Node name “Rebekka_seng_lys3” in this Z-wave card is collected from config\zwcfg_0xecd54037.xml and the XML data listed below. Note that the zwcfg_xxxxx.xml file is created based on the manufacturers xml file and their xml description of their device listed on openzwave
(I use Merten from Schneider Electric, and unfortunate most of the xml is missing):

	<Node id="14" name="Rebekka_seng_lys3" location="" basic="4" generic="16" specific="1" type="Binary Power Switch" listening="true" frequentListening="false" beaming="false" routing="true" max_baud_rate="9600" version="2" query_stage="Complete">
		<Manufacturer id="0" name="Torgrim">
			<Product type="0" id="0" name="Super bryter" />
		</Manufacturer>

28-00-52-00

3: Under you can see the switch card where z-wave Node 14 is named “Rebekka seng lys2” collected from
config\customize.yaml and the yaml data:

switch.rebekkaseng_switch:
  friendly_name: Rebekka seng lys2
  icon: mdi:cake

28-01-02-38

If you don’t use customize.yaml the name are collected from config.storage\core.device_registry under
"name": "Rebekka seng lys1",

28-01-57-23
4: The Node 14 is a switch and therfore can be listed in the core.device_registry several times,
but minimum 2 times.
If the z-wave device has more attributs like power meter, it will get a loot more listings.
Node 14 gets two:

{
"config_entry_id": "2127c304c60142e28394cab4c4096b76",
"device_id": "2c84b93ccabd48c7971e0b51dd053f38",
"disabled_by": null,
"entity_id": "switch.rebekkaseng_switch",
"name": "Rebekka seng lys1",
"platform": "zwave",
"unique_id": "14-72057594277609472" },

    {
        "config_entry_id": null,
        "device_id": null,
        "disabled_by": null,
        "entity_id": "zwave.rebekkaseng",
        "name": "Kontakt Rebekka seng",
        "platform": "zwave",
        "unique_id": "node-14"
    },

Hope this makes any sense to someone else

1 Like

Wow, that sure is consistent…:frowning_face: That makes complete sense…:frowning_face:

No negativity toward you @Torgrim but this used to be SO much easier and less confusing before all the changes made “for consistency”. :roll_eyes:

Thank you for your input to this topic.

Don’t edit the files in .storage - they are not intended for human editing.

Simply use the UI to give the devices a “Friendly Name” that you use; but leave the underlying zwave and associated devices as discovered.

I don’t like this either and prefer the older way; but I can tell you editing those files will lead to problems as you add new devices and remove devices.

Do you know how I can remove battery powered z-wave devices, that is not dead?

Or Mqtt devices that is discovered, but no longer is used.

In the zwave entity properties mark it as ignored.

I would love to be able to delete a entity in a easy way, e.g below I would like to delete zwave.waterleak but it looks like the light switch also got the same node id 33.

    {
        "config_entry_id": null,
        "device_id": null,
        "disabled_by": null,
        "entity_id": "zwave.waterleak",
        "name": null,
        "platform": "zwave",
        "unique_id": "node-33"
    },
    {
        "config_entry_id": null,
        "device_id": null,
        "disabled_by": null,
        "entity_id": "light.merten_transmitter_move_level",
        "name": null,
        "platform": "zwave",
        "unique_id": "33-72057594596392961"
    },

I can’t find node id 33 anywhere in the front end. And I haven’t done any to the data

I’ve had the exact same thing happen after I edited the files manually. To clear it up:

  1. Shut down HA
  2. Move the zwcfg*.xml out of the HA directory (put in a safe place)
  3. Delete pyozw.sqlite from the HA directory
  4. Restart and wait while your zwave devices report in. For battery powered you can force them by hitting whatever switch wakes them up.

This should rebuild it all and then you can assign logical names in the zwave entity editor.

Also make sure you are on 81.0 as it added some more functionality for zwave in the entity registry.

1 Like

Thanks, that rebuild the z-wave nodes.

Most of them is still listed as “Unknown Node”, so I guess setting the proper name in core.entity_registry and rebuild again will do the trick.

1 Like

Did it not detect the device type? It should default to a name that is the device manufacture and type.

If it’s unknown it means it’s not detected the device type in OZW.

I use switches and light from Merten, and they are missing the xml files.
I struggle to get the Transmitter to work, I probably need to find a way to define the xml data my self.

&lt;Manufacturer id="007a" name="Merten"&gt;
&lt;Product type="8001" id="0001" name="Plug-in Appliance Module"/&gt;
&lt;Product type="8002" id="0001" name="Plug-in Dimmer Module"/&gt;
&lt;Product type="8003" id="0001" name="Plug-in Roller Shutter Module" config="merten/507801.xml"/&gt;
&lt;Product type="4003" id="0001" name="Wall Dimmer Module"/&gt;
&lt;Product type="4002" id="0001" name="Wall Appliance Module"/&gt;
&lt;Product type="4004" id="0001" name="Wall Roller Shutter Module" config="merten/50x5xx.xml"/&gt;
&lt;Product type="8001" id="8001" name="Receiver Flush-Mounted 1-Gang Switch"/&gt;
&lt;Product type="0003" id="0004" name="Transmitter Flush-Mounted 4-Gang Switch"/&gt;
&lt;Product type="0001" id="0002" name="Transmitter 1-Gang Switch"/&gt;
&lt;Product type="0001" id="0004" name="Transmitter 2-Gang Switch"/&gt;
&lt;Product type="0002" id="0001" name="Transmitter Move"/&gt;
&lt;/Manufacturer&gt;