My Config Collection (OH 1.8 ONLY!) - Might help Someone

Can anyone please help? My node 01 is a Arduino with three door sensors and a few other sensors and right is unplugged from power but OH still store states of some sensors! below some debug states:

21:03:00.007 [DEBUG] [.p.rrd4j.internal.RRD4jService:113 ] - Stored 'Node01Door' with state 'OPEN' in rrd4j database (again)
21:03:00.009 [DEBUG] [.p.rrd4j.internal.RRD4jService:132 ] - Stored 'Node01Door' with state '1' in rrd4j database
21:03:00.023 [TRACE] [o.c.p.internal.PersistItemsJob:56 ] - Storing item 'Node01Door' with persistence service 'rrd4j' took 19ms

I think is related to rrd4j binding


Any idea?

@jcid1 I managed somehow to start my gateway and I simplified the rules to whatch a single door contact that is in the group and I managed to test your rule. The result is this:
When I armaway or armstay I get email of the alarm status, also if the door contact is open I get email that the alarm couldn’t be armed because of that.
If the alarm is set to armaway and armstay and if I open the contact the lights in the galllights group will come on.
So far so good but, I don’t receive email if the alarm is set to armaway or armstay and the door contact it’s open during this time! Do you receive email in this case?
Also I think it needs to have some seconds when you come back home and you disarm the system because in this case, before disarming (from insi the house ) you will trigger all the devices like sirens, lights

What do you think about this?

Can you please tell me why you have {autoupdate=“false”} at the ent of the AlarArmDisarm item?
Thanks.

Honestly don’t remember. But it is working fine so. May have been there from before i added states but who knows


My config actually already has a timer. When the alarm is set off it first triggers all the lights to let you know something is about to happen. Then after a minute or something it sets off the sirens etc
 Feel free to extend on that


Why would you not want states? Plug the arduino back in and let it update the proper states? OH is doing exactly what it is configured to do.

I have groups for Doors, Windows, Motion etc. When I arm away it looks at all the motion and doors/widows groups and checks if it is OPEN. A group will show OPEN is any if the items in that group are open. Same with doors etc. If all Doors are closed then the group will show closed.

Arming stay only looks at the Doors and windows groups. Not Motion :wink:

No clue. Dont use mqtt at all
 Sorry.

Yes i noticed i forgot some scripts in the folder but there all posted here for you to grab if their missing.

Persistence
exec
mail
samsung
zwave
http

think thats about it.

Just a note for anyone using OpenHab on Microsoft Windows. My scripts will NOT work for you. You must be using a flavor of Linux preferably Debian 7 as thats what mine is coded under


Are you using Linux or windows?

UPDATE for everyone:

I switched from:
Usage is: /etc/voicerss-cli.pl -t “window is open.” -o /usr/share/openhab/sounds/windoisopen.wav

to

Ivona_Speak:
https://pypi.python.org/pypi/ivona_speak

ivona-speak synthesize --access-key ‘YOUR ACCESS KEY’ --secret-key ‘YOUR SECRET KEY’ -n Salli -o /usr/share/openhab/sounds/AlarmActivated.mp3 ‘Alarm is Activated!’

Almost natural sounding voices
 Sally especially.
demo at https://www.ivona.com/

2 Likes

Man, a lot of answers! Thank you, appreciate it.
I got it with the alarm item “false” I switched to “true” and now it keeps the status in Rotini app. Also I addded a timer when alarm is set to armstay or armaway for 30 sec so when I come home I have enough time to disarm the system from my wall tablet installed near the entry door.
It’s very interesting this thing with ivona! Can you please give us more details about how did you configure it on your machine? Or a suggestion for a step by step tutorial?
I have my server running on a pi so I’ll need some examples for Linux. This Ivona its very nice because you can set any language you want and you can add different voices for different actions I suppose like arming the system you can display a text as you prefer!
Could you please tell us more detailed how did you do it?
Thanks a lot.
Best!!

UPDATE: Proximity Detection:

So i used the IOS app called “Locative”. It is a proximity app where you can set a geo-fence and when ever you enter that geo-fence or leave it the app will do an http request to a script of your choice. I left the global settings blank and just used the custom settings with authentication direct to openhab since my openhab is internet accessible.

Long story short when ever i enter my driveway the app makes a post request to my openhab using the address http://hab.mydomain.com/CMD?garagegoor1=ON which in turn immediately opens my garage door. The app seems very responsive and have not noticed any battery difference being that it is always watching my GPS
 You can set multiple geo-fences also like six or eight i believe.You could have one for a garage door and maybe another to run different Scenes etc
 Those scenes could be outdoor lighting or something


Good luck!!

Hi Jay, I am 70 years old retired Telecom engineer and my hobby is openHab, I am thrilled to see the kind of Config collection you published. May I have the items file details, particularly on Security System so that I may start trying it. Thanking you with Great Regards, Ragothaman R. (ragoth@gmail.com)

Hello Sir,

here ya go.

/* Group for persistence */
Group persist
Group:Number:MIN gBattery "Minimum Battery Level [%d]" <temperature>
Group:Contact:OR(OPEN,CLOSED) gMotionSensors (All)
Group:Contact:OR(OPEN,CLOSED) gDoorSensors (All)
Group:Contact:OR(OPEN,CLOSED) gTamper (All)
Group:Contact:OR(OPEN,CLOSED) gSmoke(All)
Group:Contact:OR(OPEN,CLOSED) gWindows(All)
Group gGarageLights (All)
Group gAllLights (All)
Group gAllSirensSwitch (All)
Group gAllSirensSet (All)
Group gBattery (All)
String Notification_Proxy

/* Garage */
String Switch1 "Door Status [%s]" <garage> (persist,gDoorSensors) 
Switch relay1 "Garage" <garage> (persist) { autoupdate="false",exec=">[ON:ssh root@10.1.100.4 /etc/garage.py] >[OFF:ssh root@10.1.100.4 /etc/garage.py]" }
Dimmer Garage_Left_Light "Left Garage: [%d %%]" <hue> (persist,gAllLights,gGarageLights) { zwave="16:command=SWITCH_MULTILEVEL" }
Dimmer Garage_Right_Light "Right Garage: [%d %%]" <hue> (persist,gAllLights,gGarageLights) { zwave="17:command=SWITCH_MULTILEVEL" }

/* Temperature */
Number IndHeat "Set Point [%.0f °F]" <temperature> (persist)
Number Temperature "Temperature [%.2f °F]" <temperature> (persist) {weather="locationId=home, type=temperature, property=current, unit=fahrenheit"}
Number Humidity "Humidity [%d %%]" <temperature> (persist) {weather="locationId=home, type=atmosphere, property=humidity"}
String Condition0 "Condition [%s]" <temperature> (persist) {weather="locationId=home, type=condition, property=text"}
String Condition1 "Condition [%s]" <temperature> (persist) {weather="locationId=home, forecast=1, type=condition, property=text"}
String Condition2 "Condition [%s]" <temperature> (persist) {weather="locationId=home, forecast=2, type=condition, property=text"}

/* Observation times */
DateTime Weather_ObservationTime0  "Weather Observation time [%1$td.%1$tm.%1$tY%1$tH:%1$tM]" <temperature> (persist) {weather="locationId=home, forecast=0, type=condition, property=observationTime"}
DateTime Weather_ObservationTime1  "Weather Observation time [%1$td.%1$tm.%1$tY%1$tH:%1$tM]" <temperature> (persist) {weather="locationId=home, forecast=1, type=condition, property=observationTime"}
DateTime Weather_ObservationTime2  "Weather Observation time [%1$td.%1$tm.%1$tY%1$tH:%1$tM]" <temperature> (persist) {weather="locationId=home, forecast=2, type=condition, property=observationTime"}

/* weather stuff */
Number Clouds "Clouds [%.0f %%]" <temperature> (persist) {weather="locationId=home, type=clouds, property=percent"}
Number Visibility_Mph "Visibility [%.2f mi]" <temperature> (persist) {weather="locationId=home, type=atmosphere, property=visibility, unit=mph"}
Number Wind_Speed_Mph "Windspeed [%.2f mph]" <temperature> (persist) {weather="locationId=home, type=wind, property=speed, unit=mph"}
Number IndHoldStatus "Hold Status [MAP(thermostat2.map):%d]" <temperature> (persist)
Number IndHeaterStatus "Heat Fan [MAP(thermostat.map):%d]" <temperature> (persist)
Number IndFanStatus "Manual Fan [MAP(thermostat.map):%d]" <temperature> (persist)
Number IndTemp "Indoor Temp [%.0f °F]" <temperature> (persist)
Number SendTemp "[%.0f °F]" (persist) 
Number IndHeatSet "Heating [%.0f °F]" (persist)
String IndHeatRes "Resume Schedule" <temperature> (persist) { autoupdate="false",exec=">[ON:python /etc/openhab/configurations/scripts/therm.py -x] >[OFF:python /etc/openhab/configurations/scripts/therm.py -x]" }

/* Kitchen Items */
Contact Lower_Kitchen_Motion_Sensor "Motion: [%s]" <door> (persist,gMotionSensors) {zwave="6:command=SENSOR_BINARY"}
Contact Lower_Kitchen_Motion_Sensor_Tamper "Motion Tamper: [%s]" <lock> (persist,gTamper) {zwave="6:command=ALARM"}
Number Lower_Kitchen_Motion_Sensor_Battery "Motion Battery: [%d %%]" <battery> (persist,gBattery) {zwave="6:command=BATTERY"}
Number Meter_Energy "Total energy usage [%.2f KWh]" <energy> (persist,gDashboard) { zwave="4:command=meter,meter_scale=E_KWh,refresh_interval=60"}
Number Meter_Power "Power consumption [%.2f W]" <energy> (persist) { zwave="4:command=meter,meter_scale=E_W,refresh_interval=60"}
Contact Lower_Kitchen_Patio_Sensor "Patio Door: [%s]" <door> (persist,gDoorSensors) {zwave="10:command=SENSOR_BINARY"}
Contact Lower_Kitchen_Patio_Sensor_Tamper "Tamper: [%s]" <lock> (persist,gTamper) {zwave="10:command=ALARM, refresh_interval=20"}
Number Lower_Kitchen_Patio_Sensor_Battery "Battery: [%d %%]" <battery> (persist,gBattery) {zwave="10:command=BATTERY"}
Contact Lower_Kitchen_MainDoor_Sensor "Garage Door: [%s]" <door> (persist,gDoorSensors) {zwave="9:command=SENSOR_BINARY"}
Contact Lower_Kitchen_MainDoor_Sensor_Tamper "Tamper: [%s]" <lock> (persist,gTamper) {zwave="9:command=ALARM, refresh_interval=20"}
Number Lower_Kitchen_MainDoor_Sensor_Battery "Battery: [%d %%]" <battery> (persist,gBattery) {zwave="9:command=BATTERY"}
Dimmer Lower_Kitchen_Patio_Light "Patio Door [%d %%]" <hue> (persist,gAllLights) { zwave="2:command=SWITCH_MULTILEVEL" }
Dimmer Lower_Kitchen_Sink_Light "Kitchen Sink: [%d %%]" <hue> (persist,gAllLights) { zwave="15:command=SWITCH_MULTILEVEL" }

/* LivingRoom Items */
Dimmer Lower_LivingRoom_DoorWay_Light "Doorway Light: [%d %%]" <hue> (persist,gAllLights) { zwave="18:command=SWITCH_MULTILEVEL" }
Dimmer Lower_LivingRoom_TV_Light "TV Light [%d %%]" <hue> (persist,gAllLights) { zwave="3:command=SWITCH_MULTILEVEL" }
Contact Lower_LivingRoom_Motion_Sensor "Motion: [%s]" <door> (persist,gMotionSensors) {zwave="8:command=SENSOR_BINARY"}
Contact Lower_LivingRoom_Motion_Sensor_Tamper "Motion Tamper: [%s]" <lock> (persist,gTamper) {zwave="8:command=ALARM"}
Number Lower_LivingRoom_Motion_Sensor_Battery "Motion Battery: [%d %%]" <battery> (persist,gBattery) {zwave="8:command=BATTERY"}
Contact Lower_LivingRoom_FrontDoor_Sensor "Front Door: [%s]" <door> (persist,gDoorSensors) {zwave="11:command=SENSOR_BINARY"}
Contact Lower_LivingRoom_FrontDoor_Sensor_Tamper "Tamper: [%s]" <lock> (persist,gTamper) {zwave="11:command=ALARM, refresh_interval=20"}
Number Lower_LivingRoom_FrontDoor_Sensor_Battery "Battery: [%d %%]" <battery> (persist,gBattery) {zwave="11:command=BATTERY"}

/* Bedrooms */
Contact Upper_BedRoom_Window_Sensor "Zach Window: [%s]" <contact> (persist,gWindows) {zwave="7:command=basic,respond_to_basic=true"}
Contact Upper_BedRoom_Window_Sensor_Tamper "Tamper: [%s]" <lock> (persist,gTamper) {zwave="7:command=ALARM"}
Number Upper_BedRoom_Window_Sensor_Battery "Battery: [%d %%]" <battery> (persist,gBattery) {zwave="7:command=BATTERY"}
Switch Upper_BedRoom_Power_Switch "Entertainment:" <hue> (persist) { zwave="4:command=SWITCH_BINARY" }

/* TV */
Switch SharpTVPower "TV Power" <television> { autoupdate="false",exec=">[ON:python3 /etc/openhab/configurations/scripts/orvibo/orvibo.py -i 10.1.100.28 -e /etc/orvibo/tv/sharp-power.ir] >[OFF:python3 /etc/openhab/configurations/scripts/orvibo/orvibo.py -i 10.1.100.28 -e /etc/openhab/configurations/scripts/orvibo/tv/sharp-power.ir]" }
String SharpTVInput "TV Input" <television> { autoupdate="false",sharptv = "uid=livingroom, bindingType=input" }
Switch SharpTVMute "TV Mute" <television> { autoupdate="false",exec=">[ON:python3 /etc/openhab/configurations/scripts/orvibo/orvibo.py -i 10.1.100.28 -e /etc/openhab/configurations/scripts/orvibo/tv/sharp-mute.ir] >[OFF:python3 /etc/openhab/configurations/scripts/orvibo/orvibo.py -i 10.1.100.28 -e /etc/openhab/configurations/scripts/orvibo/tv/sharp-mute.ir]" }
String LivingRoomTVState "TV Status: [%s]" <television>
String KodiState "Kodi Status: [%s]" <television>

/*Media Center */
String LRKodiPC "LivingRoom Kodi" <television> { autoupdate="false",exec=">[0:ssh root@10.1.100.123 shutdown -h now] >[1:wakeonlan 90:2b:34:18:24:a2]" }

/* Astro */
DateTime Sunrise_Time "SunRise [%1$tr]" <moon> (persist) { astro="planet=sun, type=rise, property=start" }
DateTime Sunset_Time "SunSet [%1$tr]" <sun>  (persist) { astro="planet=sun, type=set, property=end" }
Switch Sunset_Time_Task (persist) { astro="planet=sun, type=set, property=end" }

/* Aeon Labs Siren - set sound/volume and activate*/
Number Lower_Kitchen_Siren_Number "Kitchen Siren" <siren> (persist,gAllSirensSet) { zwave="5:command=configuration,parameter=37" }
Number Lower_Kitchen_Chirp_Number "Kitchen Chirp" <siren> (persist) { zwave="5:command=configuration,parameter=37" }
Number Upper_Hall_Siren_Number "Upper Hall Siren" <siren> (persist,gAllSirensSet) { zwave="12:command=configuration,parameter=37" }

/* Aeon Labs Siren - switch to turn on/off sirens*/
Switch Lower_Kitchen_Siren_Switch "Kitchen Siren" <siren> (persist,gAllSirensSwitch) { zwave="5:command=switch_binary" }
Switch Lower_Kitchen_Chirp_Switch "Kitchen Chirp" <siren> (persist) { zwave="5:command=switch_binary" }
Switch Upper_Hall_Siren_Switch "Upper Hall Siren" <siren> (persist,gAllSirensSwitch) { zwave="12:command=switch_binary" }

/* First Alert Carbon and Smoke alarm */
Contact	Lower_LivingRoom_Smoke_Sensor "LivingRoom Smoke Alarm [%s]" <fire> (persist,gSmoke) { zwave="14:command=ALARM" }
Number	Lower_LivingRoom_Smoke_Sensor_Battery "Smoke Alarm Battery [%s %%]" <battery> (persist,gBattery) { zwave="14:command=BATTERY" }
Contact Upper_Hall_Smoke_Sensor "Hall Smoke Alarm [%s]" <fire> (persist,gSmoke) { zwave="13:command=ALARM" }
Number  Upper_Hall_Smoke_Sensor_Battery "Smoke Alarm Battery [%s %%]" <battery> (persist,gBattery) { zwave="13:command=BATTERY" }

/* Scene Switches */
Number OnWayHomeScene <house> {autoupdate="false"}
Number AllOffScene <house> {autoupdate="false"}
Number MovieTimeScene <house> {autoupdate="false"}
Number sAllLightsOff <house> {autoupdate="false"}
Number sAllLightsOn <house> {autoupdate="false"}

/* Alarm System */
Number AlarmSysStatus "System Status: [MAP(alarm.map):%d]" <shield> (persist)
Number AlarmArmDisarm "Alarm Arm / Disarm:" <shield> (persist) {autoupdate="false"}
Number AlarmArmDisarmKeypad "Alarm Arm / Disarm:" <shield> (persist) {autoupdate="false"}

/* OpenHab System */
Number HostBatteryPercentage "Host Battery Percentage: [%d %%]" <battery> (persist)
String HostBatteryState "Host Battery State: [%s]" <battery> (persist)

/* mosquitto JC*/
String JCRawData "RawData %s" (persist) { mqtt="<[mosquitto:owntracks/jcid/jay-cell:state:default]" }
String JCWayPointData "WayPoint Data %s" (persist) { mqtt="<[mosquitto:owntracks/jcid/jay-cell/event:state:default]" }
Number JCPosition "Position: [%s]" (persist)
Number JCLatitude "Lattitude: [%s]" (persist)
Number JCLongitude "Longitude: [%s]" (persist)
Location JCLocation "Location: [%s]" (persist)
Number JCAccuracy "Accuracy: [%s m]" (persist)
Number JCBattery "Battery: [%s %%]" (persist)
String JCStatus "Jay is at: [%s]" (persist)

/* mosquitto ZC*/
String ZCRawData "RawData %s" (persist) { mqtt="<[mosquitto:owntracks/zcid/zach-ipad:state:default]" }
String ZCWayPointData "WayPoint Data %s" (persist) { mqtt="<[mosquitto:owntracks/zcid/zach-ipad/waypoint:state:default]" }
Number ZCPosition "Position: [%s]" (persist)
Number ZCLatitude "Lattitude: [%s]" (persist)
Number ZCLongitude "Longitude: [%s]" (persist)
Location ZCLocation "Location: [%s]" (persist)
Number ZCAccuracy "Accuracy: [%s  %%]" (persist)
Number ZCBattery "Battery: [%s %%]" (persist)
String ZCStatus "Zach is at: [%s]" (persist)


/* Node Check */
DateTime Node2 "Node2 Update [%1$ta %1$td-%1$tm %1$tr]" (persist) {zwave="2:command=INFO,item=LAST_UPDATE"}
DateTime Node3 "Node3 Update [%1$ta %1$td-%1$tm %1$tr]" (persist) {zwave="3:command=INFO,item=LAST_UPDATE"}
DateTime Node4 "Node4 Update [%1$ta %1$td-%1$tm %1$tr]" (persist) {zwave="4:command=INFO,item=LAST_UPDATE"}
DateTime Node5 "Node5 Update [%1$ta %1$td-%1$tm %1$tr]" (persist) {zwave="5:command=INFO,item=LAST_UPDATE"}
DateTime Node6 "Node6 Update [%1$ta %1$td-%1$tm %1$tr]" (persist) {zwave="6:command=INFO,item=LAST_UPDATE"}
DateTime Node7 "Node7 Update [%1$ta %1$td-%1$tm %1$tr]" (persist) {zwave="7:command=INFO,item=LAST_UPDATE"}
DateTime Node8 "Node8 Update [%1$ta %1$td-%1$tm %1$tr]" (persist) {zwave="8:command=INFO,item=LAST_UPDATE"}
DateTime Node9 "Node9 Update [%1$ta %1$td-%1$tm %1$tr]" (persist) {zwave="9:command=INFO,item=LAST_UPDATE"}
DateTime Node10 "Node10 Update [%1$ta %1$td-%1$tm %1$tr]" (persist) {zwave="10:command=INFO,item=LAST_UPDATE"}
DateTime Node11 "Node11 Update [%1$ta %1$td-%1$tm %1$tr]" (persist) {zwave="11:command=INFO,item=LAST_UPDATE"}
DateTime Node12 "Node12 Update [%1$ta %1$td-%1$tm %1$tr]" (persist) {zwave="12:command=INFO,item=LAST_UPDATE"}
DateTime Node13 "Node13 Update [%1$ta %1$td-%1$tm %1$tr]" (persist) {zwave="13:command=INFO,item=LAST_UPDATE"}
DateTime Node14 "Node14 Update [%1$ta %1$td-%1$tm %1$tr]" (persist) {zwave="14:command=INFO,item=LAST_UPDATE"}
DateTime Node15 "Node15 Update [%1$ta %1$td-%1$tm %1$tr]" (persist) {zwave="15:command=INFO,item=LAST_UPDATE"}
DateTime Node16 "Node16 Update [%1$ta %1$td-%1$tm %1$tr]" (persist) {zwave="16:command=INFO,item=LAST_UPDATE"}
DateTime Node17 "Node17 Update [%1$ta %1$td-%1$tm %1$tr]" (persist) {zwave="17:command=INFO,item=LAST_UPDATE"}
DateTime Node18 "Node18 Update [%1$ta %1$td-%1$tm %1$tr]" (persist) {zwave="18:command=INFO,item=LAST_UPDATE"}

Hi Jay, Thank you sooo much.
With Best Regards,
Ragothaman R.

Hey @jcid1 thanks for putting all this together!

A few quick substitutions and tweaks to integrate it into my presence detection items/rules and i’ve got a basic automated security system. Thanks!

@jcid1
Appreciate if you zip and upload your latest config
thanks