Sensor recognised as switch

I have a problem with a Sensor being recognized as a Switch which is causing problems with rules and sitemaps.

I previously had a Fibaro FGK101 door/window sensor that would send notifications if the garage door was left open. openHAb recognised this as a Sensor with OPEN/CLOSE status . This would appear in in the sitemap showing the Open or Closed status with the Garage Door icon that changes with the status. Here’s the previous working .items line and thing in Paper UI:

Contact zwave_device_8527f2c0_node6_sensor_door "Garage Door [%s]" <garagedoor>


When the Fibaro sensor died, i replaced with an Aeotec ZW120 door/window sensor. However the Aeotec sensor is showing in Paper IU as a Switch with status of ON/OFF.


I’ve added the following line in .items file and used the type Switch (I’m assuming i can’t use the type Sensor)

Switch zwave_device_8527f2c0_node15_sensor_binary "Garage Door [%s]" <garagedoor>

But now i have the following problems:

  • the status shows and Triggered and Untriggered
  • the garage door icon now does not respond to changing status, it always shows partially open


I tried to add mappings=[TRIGGERED=“OPEN”,UNTRIGGERED=“CLOSED”] to my sitemap, but this produced errors in the log and the .sitemap failed to load.

How can i get the sensor to show as Open and Closed, and Use the Garage Door icon that shows the Open/Closed status?

Is the solution to change the database to recognise this item as a sensor, not a switch?

openHAB v2.2.0-1 on Intel NUC running Ubuntu 16.04 LTS

You are getting confused between Channels and Items

In your item file create an item with a binding to the channel:

Switch GarageDoor "Garage Door [MAP(]" <garagedoor> { channel="zwave:device:8527f2c0:node15:sensor:binary" }

Create a MAP file in your transformation folder called with the following content:


In your sitemap:

Text item=GarageDoor 

Good luck

1 Like

The solution is to update the database to use the channel sensor_door rather than sensor_binary. When devices are added to the database, they get given a generic name, and this just needs updating.

I’ll update this…

Thanks Chris - appreciate the assistance.