Openhab 2 Groups and Rules

Hello,

I have been building my home automation openhab 2. Thanks for the great tool!

I have been able to add my zwave door sensors to openhab. And those are working fine. Now I’m stuck with the rules.

Items:
Group:Contact:OR(OPEN,CLOSED) Doors “Ovi tunnistemet” (All)
Contact DoorTakaoviAlatupa “Takaovi Alatupa [MAP(door.map):%s]” (Doors) {channel=“zwave:device:91c09578:node4:sensor_door”}

Rules:
// Imports
import org.openhab.core.library.types.*
import org.openhab.core.persistence.*
import org.openhab.model.script.actions.*

rule "Doors opened"
when
Item Doors changed
then
logInfo(“door sensors”, “door sensors changed state”)
end

Here is the Log:
2016-05-25 18:04:18.518 [INFO ] [marthome.event.ItemStateChangedEvent] - DoorTakaoviAlatupa changed from CLOSED to OPEN
2016-05-25 18:04:18.527 [INFO ] [marthome.event.ItemStateChangedEvent] - zwave_device_91c09578_node4_sensor_door changed from CLOSED to OPEN
2016-05-25 18:04:19.563 [INFO ] [marthome.event.ItemStateChangedEvent] - zwave_serial_zstick_91c09578_serial_sof changed from 82 to 83
2016-05-25 18:04:19.567 [INFO ] [marthome.event.ItemStateChangedEvent] - DoorTakaoviAlatupa changed from OPEN to CLOSED
2016-05-25 18:04:19.573 [INFO ] [marthome.event.ItemStateChangedEvent] - zwave_device_91c09578_node4_sensor_door changed from OPEN to CLOSED

-> I can’t see my logging line. Am i doing something wrong?

Second question is the grouping. First I just used the Items that was made for me by discovery in Paper UI. I did not found a way to group them -> This was the reason to add those items manually to items file and made also the groups there. Is there any other way?

Third question is related to Eclipse Smart Home Designer. I installed to that to my Windows and launched. It opens, but how I should connect this to my openhab environment running on Raspberry PI? Or is this even possible? So currently I’m just using notepad++ to maintain sitemaps etc.

I’m using the Openhab 2 beta 3 release.

Please try another trigger:

when
    Item Doors received update
then

Thanks, Rule started work today. I have just been rebooting a palying around with rfxcom binding. But now in my logs

2016-05-26 19:17:17.478 [INFO ] [ome.event.GroupItemStateChangedEvent] - Doors changed from OPEN to CLOSED through DoorTakaoviAlatupa
2016-05-26 19:17:17.481 [INFO ] [marthome.event.ItemStateChangedEvent] - DoorTakaoviAlatupa changed from OPEN to CLOSED
2016-05-26 19:17:17.482 [INFO ] [marthome.model.script.motion_tripped] - motion sensors changed state

I have no idea why this happened.

Strill wondering about that what should be thbest way to group items and should I use Eclipse MArt Home Designer and how…

In regards to your question on using the Smarthome Designer, in my setup I expose the Openhab conf folder via samba and mount that share on my Windows machine where I have the Designer installed.
This works pretty well for me.
Take care
Ingo

Thanks, I did this. It works for items in the items files, but how about the auto discovered things /items? How to add those to groups?

Or maybe I should just recreate/copy those also to the items files.