Welcome to Smart Home Forum by FIBARO
Dear Guest,
as you can notice parts of Smart Home Forum by FIBARO is not available for you. You have to register in order to view all content and post in our community. Don't worry! Registration is a simple free process that requires minimal information for you to sign up. Become a part of of Smart Home Forum by FIBARO by creating an account.
As a member you can:
- Start new topics and reply to others
- Follow topics and users to get email updates
- Get your own profile page and make new friends
- Send personal messages
- ... and learn a lot about our system!
Regards,
Smart Home Forum by FIBARO Team

Question
pos 22
Hi
Let us assume we name a light device with the name "roof" if you have only one light device in a room. This means you have a lot of light devices with the same name in the Fibaro system, but of course different ID numbers...
Now... Let us assume I have a LUA code and handle for example light ID 144. It is easy to look up its name and present that to the user instead of the ID as its name exists in the light device JSON code through the API. But if I have more rooms it will probably be so that I will present several light IDs with the same name, as their names are the same, but in different rooms.
Therefor I would like to look up the lighid device number and get its name PLUS the room it is in. In this case I can present it like "Bathroom/Roof" instead of just "Roof".
The problem is that the light device JSON object has no info about the room it is in. and the Room JSON object has no info in it about the devices in the room.
Anyone that knows how to easily look up the room a device is in?
Tnx
/Peo
/Peo
5 answers to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.