Semantic Model — Door Sensor

Tags: #<Tag:0x00007f172d215638>

I currently have a group created for my garage door with an equipment tag of “GarageDoor”, like below.

Group Indoor "Indoor" ["Indoor"]
Group Room_Garage "Garage" <garage> (Floor_Ground) ["Garage"]
Group Door_External_Garage "Garage Door" <garagedoor> (Room_Garage) ["GarageDoor"]

The door has a sensor on it to measure its tilt to determine open/close status. It’s unclear if the sensor’s Points should belong to the Door_External_Garage group, or if a second Equipment group should belong to the Door_External_Garage group and the sensor’s Points should belong that that?

Number:Dimensionless Sensor_Tilt_GarageDoor_Battery "Battery [%d %%]" <battery> (Door_External_Garage) ["Measurement","Level"] {
  channel = "zwave:eco_tiltzwave25_00_000:controller:tilt_sensor_garage_door:battery-level"
}
Contact Door_External_Garage_Sensor_State "State" (Door_External_Garage,Persist) ["OpenState"] {
  channel = "zwave:eco_tiltzwave25_00_000:controller:tilt_sensor_garage_door:sensor_door"
}
Switch Sensor_Tilt_GarageDoor_TamperAlarm "Tamper Alarm" (Door_External_Garage,Persist) ["Tampered"] {
  channel = "zwave:eco_tiltzwave25_00_000:controller:tilt_sensor_garage_door:alarm_tamper"
}

This only makes partial sense to me, as the garage door doesn’t have a battery or tamper alarm, the sensor does.

An alternative is creating a Sensor Equipment group and having its Points belong to that group, but I don’t believe that’s correct either, and the UI for Locations doesn’t seem to update properly for the Garage Door when it’s opened/closed.

Group Sensor_Tilt_GarageDoor "Garage Door" <garagedoor> (Door_External_Garage) ["Sensor"]

Number:Dimensionless Sensor_Tilt_GarageDoor_Battery "Battery [%d %%]" <battery> (Sensor_Tilt_GarageDoor) ["Measurement","Level"] {
  channel = "zwave:eco_tiltzwave25_00_000:controller:tilt_sensor_garage_door:battery-level"
}
Contact Door_External_Garage_Sensor_State "State" (Sensor_Tilt_GarageDoor) ["OpenState"] {
  channel = "zwave:eco_tiltzwave25_00_000:controller:tilt_sensor_garage_door:sensor_door"
}
Switch Sensor_Tilt_GarageDoor_TamperAlarm "Tamper Alarm" (Sensor_Tilt_GarageDoor) ["Tampered"] {
  channel = "zwave:eco_tiltzwave25_00_000:controller:tilt_sensor_garage_door:alarm_tamper"
}

I’m happy to include additional information or clarify anything. Thanks!

This is up to you. If it makes sens to you it is OK.

I created for doors or windows with contacts as equipment door/window and the sensor ist part of the door. So i am able to say the door/window is open/closed/tampered. Because this makes sens to me.

Windows with mor than one wing and more contacts have a special state group for the whole window to refelct its state. within the group the singe contacts are located.

I think that makes sense. I messed around some and seem to have landed on the sensor state being part of the door equipment. I then create another piece of equipment specific for the sensor that’s nested under the door equipment. This contains the battery and tamper alarm.