-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
my.openHAB Persistence
Note: Service will be shut down on 31st Jan 2017. New openHAB cloud connector service: openHAB Cloud Connector
my.openHAB.org is a cloud service provided to you by openHAB and is well worth having a look at. After installing and registering, you can send Items and Events to the cloud where you can view them on the site. Whilst that is not the most exciting thing in the world, it does then allow you to have access to your openHAB installation outside of your network via the iOS and Android apps without having to open up your home network.
It also allows you to connect to IFTTT and all the hundreds of channels they offer. Including IFTTT's own very handy Maker Channel. Which essentially gives you a REST API through IFTTT into openHAB. Again without having to set up the network and port forwarding yourself.
First signup at my.openhab.org and follow the docs to install the binding, register and configure your setup.
Create a file called myopenhab.persist
in your persistence folder, and define the policy to store your data.
This example policy on the my.openHAB site will persist every item, and every change made to that item:
Strategies {
default = everyChange
}
Items {
* : strategy = everyChange
}
The above example taken from the my.openHAB docs will persist all your items, and log every change to my.openHAB cloud.
This means if you change the name of an item, the old "item" will still appear on my.openHAB cloud and also appear in your IFTTT dropdown. Also, if you set up my.openHAB with the demo configuration still setup, all of those items will also appear.
Any items such as a PIR or any type of sensor that sends constant updates to openHAB and will quickly clutter it up. So you probably don't need or want, the thousands of updates that will be logged to my.openHAB if you catchall.
People starting out should be aware of this due to the immense experimenting and testing that comes with learning openHAB. You will quickly find that the item list on my.openHAB and IFTTT will contain many items that you no longer need.
Create a group to identify your items
Group gMyOpenHAB
Then add items you know you need to log to that group. This will greatly help keep things under control.
e.g. Here only the on/off state of the switch is logged. There was no need to log every brightness state
Switch Light_GF_Lounge_All "Lounge All" (GF_Lounge, gMyOpenHAB) {milight="bridge01;6"}
Dimmer Light_GF_Lounge_All_B "Lounge All Brightness" (GF_Lounge) {milight="bridge01;6;brightness;27"}
Finally, configure your my.openHAB persistence file myopenhab.persist
to only persist items in the group
Strategies {
default = everyChange
}
Items {
gMyOpenHAB* : strategy = everyChange
}
There is a method to remove all data and from the my.openHAB cloud but no way to do it selectively. You can remove it all at once, or not at all. To do so, log into http://my.openhab.org, mouseover your account email address (top right) and select account from the dropdown. The button you want is under Dangerous actions labeled Delete Items and Events
Sending persistence data to my.openHAB is required if you use any data-driven cloud functions, IFTTT integration for example.
This means that if you want to control the brightness (or any item) using the openHAB IFTTT Channel, be sure that the item is in the gMyOpenHAB group, or it won't appear in the dropdown on IFTTT.
Please read the https://my.openhab.org/docs/ifttt for more details.
It is also required by the apps when used outside your local network.
You can also use REST through my.openHAB.org.
e.g.
To get the state of all items (remember my.openHAB will only display items that you have persisted to it)
https://my.openhab.org/rest/items
You can specify:
https://my.openhab.org/rest/items/Light_FF_Office_Desk
You can also send commands:
https://my.openhab.org/CMD?Light_FF_Office_Desk=TOGGLE
https://my.openhab.org/CMD?Light_FF_Office_Ceiling=ON
ℹ Please find all documentation for openHAB 2 under http://docs.openhab.org.
The wiki pages here contain (outdated) documentation for the older openHAB 1.x version. Please be aware that a lot of core details changed with openHAB 2.0 and this wiki as well as all tutorials found for openHAB 1.x might be misleading. Check http://docs.openhab.org for more details and consult the community forum for all remaining questions.
- Classic UI
- iOS Client
- Android Client
- Windows Phone Client
- GreenT UI
- CometVisu
- Kodi
- Chrome Extension
- Alfred Workflow
- Cosm Persistence
- db4o Persistence
- Amazon DynamoDB Persistence
- Exec Persistence
- Google Calendar Presence Simulator
- InfluxDB Persistence
- JDBC Persistence
- JPA Persistence
- Logging Persistence
- mapdb Persistence
- MongoDB Persistence
- MQTT Persistence
- my.openHAB Persistence
- MySQL Persistence
- rrd4j Persistence
- Sen.Se Persistence
- SiteWhere Persistence
- AKM868 Binding
- AlarmDecoder Binding
- Anel Binding
- Arduino SmartHome Souliss Binding
- Asterisk Binding
- Astro Binding
- Autelis Pool Control Binding
- BenQ Projector Binding
- Bluetooth Binding
- Bticino Binding
- CalDAV Binding
- Chamberlain MyQ Binding
- Comfo Air Binding
- Config Admin Binding
- CUL Transport
- CUL Intertechno Binding
- CUPS Binding
- DAIKIN Binding
- Davis Binding
- DD-WRT Binding
- Denon Binding
- digitalSTROM Binding
- DIY on XBee Binding
- DMX512 Binding
- DSC Alarm Binding
- DSMR Binding
- eBUS Binding
- Ecobee Binding
- EDS OWSever Binding
- eKey Binding
- Energenie Binding
- EnOcean Binding
- Enphase Energy Binding
- Epson Projector Binding
- Exec Binding
- Expire Binding
- Fatek PLC Binding
- Freebox Binding
- Freeswitch Binding
- Frontier Silicon Radio Binding
- Fritz AHA Binding
- Fritz!Box Binding
- FritzBox-TR064-Binding
- FS20 Binding
- Garadget Binding
- Global Caché IR Binding
- GPIO Binding
- HAI/Leviton OmniLink Binding
- HDAnywhere Binding
- Heatmiser Binding
- Homematic / Homegear Binding
- Horizon Mediabox Binding
- HTTP Binding
- IEC 62056-21 Binding
- IHC / ELKO Binding
- ImperiHome Binding
- Insteon Hub Binding
- Insteon PLM Binding
- IPX800 Binding
- IRtrans Binding
- jointSPACE-Binding
- KM200 Binding
- KNX Binding
- Koubachi Binding
- LCN Binding
- LightwaveRF Binding
- Leviton/HAI Omnilink Binding
- Lg TV Binding
- Logitech Harmony Hub
- MailControl Binding
- MAX!Cube-Binding
- MAX! CUL Binding
- MCP23017 I/O Expander Binding
- MCP3424 ADC Binding
- MiLight Binding
- MiOS Binding
- Mochad X10 Binding
- Modbus Binding
- MPD Binding
- MQTT Binding
- MQTTitude binding
- MystromEcoPower Binding
- Neohub Binding
- Nest Binding
- Netatmo Binding
- Network Health Binding
- Network UPS Tools Binding
- Nibe Heatpump Binding
- Nikobus Binding
- Novelan/Luxtronic Heatpump Binding
- NTP Binding
- One-Wire Binding
- Onkyo AV Receiver Binding
- Open Energy Monitor Binding
- OpenPaths presence detection binding
- OpenSprinkler Binding
- OSGi Configuration Admin Binding
- Panasonic TV Binding
- panStamp Binding
- Philips Hue Binding
- Picnet Binding
- Piface Binding
- PiXtend Binding
- pilight Binding
- Pioneer-AVR-Binding
- Plex Binding
- Plugwise Binding
- PLCBus Binding
- PowerDog Local API Binding
- Powermax alarm Binding
- Primare Binding
- Pulseaudio Binding
- Raspberry Pi RC Switch Binding
- RFXCOM Binding
- RWE Smarthome Binding
- Sager WeatherCaster Binding
- Samsung AC Binding
- Samsung TV Binding
- Serial Binding
- Sallegra Binding
- Satel Alarm Binding
- Siemens Logo! Binding
- SimpleBinary Binding
- Sinthesi Sapp Binding
- Smarthomatic Binding
- Snmp Binding
- Somfy URTSI II Binding
- Sonance Binding
- Sonos Binding
- Souliss Binding
- Squeezebox Binding
- Stiebel Eltron Heatpump
- Swegon ventilation Binding
- System Info Binding
- TA CMI Binding
- TCP/UDP Binding
- Tellstick Binding
- TinkerForge Binding
- Tivo Binding
- UCProjects.eu Relay Board Binding
- UPB Binding
- VDR Binding
- Velleman-K8055-Binding
- Wago Binding
- Wake-on-LAN Binding
- Waterkotte EcoTouch Heatpump Binding
- Weather Binding
- Wemo Binding
- Withings Binding
- XBMC Binding
- xPL Binding
- Yamahareceiver Binding
- Zibase Binding
- Z-Wave Binding
- Asterisk
- DoorBird
- FIND
- Foscam IP Cameras
- LG Hombot
- Worx Landroid
- Heatmiser PRT Thermostat
- Google Calendar
- Linux Media Players
- Osram Lightify
- Rainforest EAGLE Energy Access Gateway
- Roku Integration
- ROS Robot Operating System
- Slack
- Telldus Tellstick
- Zoneminder
- Wink Hub (rooted)
- Wink Monitoring
- openHAB Cloud Connector
- Google Calendar Scheduler
- Transformations
- XSLT
- JSON
- REST-API
- Security
- Service Discovery
- Voice Control
- BritishGasHive-Using-Ruby
- Dropbox Bundle
A good source of inspiration and tips from users gathered over the years. Be aware that things may have changed since they were written and some examples might not work correctly.
Please update the wiki if you do come across any out of date information.
- Rollershutter Bindings
- Squeezebox
- WAC Binding
- WebSolarLog
- Alarm Clock
- Convert Fahrenheit to Celsius
- The mother of all lighting rules
- Reusable Rules via Functions
- Combining different Items
- Items, Rules and more Examples of a SmartHome
- Google Map
- Controlling openHAB with Android
- Usecase examples
- B-Control Manager
- Spell checking for foreign languages
- Flic via Tasker
- Chromecast via castnow
- Speedtest.net integration