stefan-kaestle / openhab2-addons

Add-ons for openHAB 2.x
Eclipse Public License 2.0
16 stars 1 forks source link

boschshc: Add support for roomLightControl in 2.0 #61

Open jensflorian opened 3 years ago

jensflorian commented 3 years ago

Currently in-wall-switches are already supported. I would like to see in future versions as an enhancement also support for its parent: The roomLightControl service controls all light items assigned to a given room in Bosch SHC. There is only one channel for operation.

The device is already successfully detected in the current version.

[INFO ] [devices.bridge.BoschSHCBridgeHandler] - Found device: name=RoomLightControl id=roomLightControl_hz_5

The relevant device path is (for example in room hz_5 as above): /devices/roomLightControl_hz_5/services/BinarySwitch/state

Output in REST API (when all lights are off):

{
    "@type": "binarySwitchState",
    "on": false
}

"true" turns all lights on.

coeing commented 3 years ago

This looks like it works like the ClimateControl devices we already have. Should be pretty easy to implement.

coeing commented 3 years ago

On https://apidocs.bosch-smarthome.com/local there is LightControl documented, but it has a powerSwitchState instead of a binarySwitchState :/

I might have to ask for the API documentation for these virtual devices in the Bosch repository first.