Hi, I am running OH3.4.4 on a RPi4.
I have successfully created 2 items related to my Garage Door in OH3. The first is a Switch item to control the garage door motor, and the second is a Contact item to report the status of the magnetic reed switch on the garage door (contact closed = door closed, contact open = door open).
I have the Google Home Assistant action running and working fine to control lights and on/off plugs.
The switch and contact items for my garage door work great in OH3, however, I’m having problems integrating these 2 items with Google Home Assistant as a Garage door device.
My objective is to be able to say to Home Assistant:
- ‘Hey Google, is the Garage Door open/closed’, and it responds with either ‘The Garage Door is open/closed’ based on the status of the garage door Contact item in OH3.
- ‘Hey Google, open/close the Garage Door’, and it responds by activating the garage door Switch item in OH3.
The problem is that HA sees these 2 items as separate devices - i.e. there are 2 Garage Door devices in HA - even though they both have the same name.
My question is: how do I combine these 2 items into a single Garage Door device in HA so that when I ask ‘Hey Google, is the Garage Door open/closed’, it refers the current status of the Contact item in OH3, and when I say ‘Hey Google, close/open the Garage Door’, it activates the Switch item in OH3?
Here is the snippet from my .items file:
Switch pGarageDoor_Opener "Garage Door opener [%s]" <switch> (gGarage_Room) {ga="Garage" [name="Garage door", roomHint="Garage", discreteOnly=true], channel="deconz:onofflight:raspbeebridge:garage-door-motor:switch", expire="1s,command=OFF"}
Contact pGarageDoor_Status "Garage Door is [%s]" <garagedoor> (gGarage_Room) {ga="Garage" [name="Garage door", roomHint="Garage", queryOnly=true], channel="deconz:openclosesensor:raspbeebridge:garage-door-openclose-sensor:open"}
As stated above, these 2 items work great in OH3 - I can open/close the door if I click on the Switch item, and I can see the correct status of the door if I look at the Contact item in OH3. The issue is integrating both of these 2 items into a single Garage door device in HA.
Any help will be greatly appreciated.