Get Device Name and Zone

Discussions about RaZberry - Z-Wave board for Raspberry computer
Post Reply
newera
Posts: 2
Joined: 19 Feb 2013 22:13

Get Device Name and Zone

Post by newera »

Hi,

After going through the documentation, I have a problem which is related to a very obvious and common query I must guess, which is not clearly explain IMHO.

What is the proper way to get the name and zone/location of a device? I found that the details are stored inside the rules.xml file however these properties are not returned in JSON when calling ZWaveAPI/Run/devices or ZWaveAPI/Run/devices[3] for example. I can understand why they are not part of the device properties but there should be an easy method for retrieving the name and zone.

Does any one have an idea how this can be solved or if there is any better method other than reading the xml file?

Thanks
pz1
Posts: 2053
Joined: 08 Apr 2012 13:44

Well you have to enter name

Post by pz1 »

Well you have to enter name and location (you can do it via the expert commands if your device supports those parameters. I get them with for example:
http://raspberry_IP:8083/ZwaveAPI/Run/devices[11].instances[0].NodeNaming.data.nodename.value
Use location instead of nodename for the zone. Please note that this does not give you the zone as defined in the Map. It get the variable that you set in the device.
Since 29-12-2016 I am no longer a moderator for this forum
newera
Posts: 2
Joined: 19 Feb 2013 22:13

Thanks will try it out.

Post by newera »

Thanks will try it out.
Post Reply