[ST Edge] Is it possible to retrieve device's room from within edge driver?


For virtual devices it seems useful to show all created virtual devices from controller/creator’s detailed view.
I’m wondering whether it is possible not only to provide a label, but also to show device’s room.


1 Like

Even if you can retrieve the room it will inevitably be as the ID, i.e. a UUID/GID. So I am not sure it will be what you need.

No, it seems the driver doesn’t receive this information as part of the device_info and you cannot make API requests within the driver.
Also, if we move the device to a different room, the infoChanged lifecycle is not executed.
I can open a feature request but as Graham mentioned, it would be complicated to get the actual room name instead of the ID because the first can change at any moment.

1 Like

Thank you, @nayelyz
It would be great to receive the room name from device info or in any alternative way.
Since I’m not going to cache it, it is not a problem for my use case that the room changes after the query completes.
The controller scans all devices when user selects a type of virtual thing to create, so the list is anyway populated on demand

1 Like