-
Notifications
You must be signed in to change notification settings - Fork 0
Updating Rooms
Maxi Zink edited this page Feb 13, 2022
·
2 revisions
Updating Rooms does work exactly like updating Lamps.
private void updateRooms(final HueBridge hueBridge) {
HueRoomDiscovery hueRoomDiscovery = ServiceAccessor.accessService(HueRoomDiscovery.class);
Optional<HueRoom> hueRoomByName = hueBridge.getHueRoomByName("Room");
hueRoomByName.ifPresent(hueRoom -> {
hueRoom.turnOn();
hueRoom.updateRoomLamps(LampUpdateType.COLOR, Color.RED);
hueRoom.updateRoomLamps(LampUpdateType.BRIGHTNESS, 50);
});
}