Author Topic: ALTUI & DataStorage Providers  (Read 9980 times)

Offline alekseyzp

  • Newbie
  • *
  • Posts: 11
  • Karma: +0/-0
Re: ALTUI & DataStorage Providers
« Reply #30 on: December 05, 2016, 08:11:00 am »
I'm only the second week of trying to deal with VeraEdge. I assume you mean this:
http://forum.micasaverde.com/index.php?topic=35953.0

Offline akbooer

  • Beta Testers
  • Master Member
  • *****
  • Posts: 6206
  • Karma: +276/-70
  • "Less is more"
Re: ALTUI & DataStorage Providers
« Reply #31 on: December 05, 2016, 09:08:10 am »
Sorry to be unclear.  No, not that, but @amg0's first post of this thread.
3x Vera Lite-UI5/Edge-UI7, 25x Fibaro, 23x TKB, 9x MiniMote, 2x NorthQ Power, 2x Netatmo, 1x Foscam FI9831P, 9x Philips Hue,
Razberry, MySensors Arduino, HomeWave, AltUI, AltHue, DataYours, Grafana, openLuup, ZWay, ZeroBrane Studio.

Offline amg0

  • Moderator
  • Master Member
  • *****
  • Posts: 3099
  • Karma: +206/-8
Re: ALTUI & DataStorage Providers
« Reply #32 on: December 01, 2017, 04:37:50 pm »
I am now releasing a beta for IFTTT integration as a data storage provider.
the beta is available as of now on github https://github.com/amg0/altui

if you go to a particular device / variable and click on the histogram icon you can select a data storage provider. you can now select IFTTT
if you do so, you will have to enter 2 parameters
a) the Web Hook Key as given to you by IFTTT when you prepare the WebHook applet
b) the event name that you chose when you prepare the WebHook applet
do not forget to click on the histogram icon again to save your choices

then, in IFTTT you create a " if THIS then THAT" applet and select webhook as the THIS.
in terms of the THAT, you can chose what you want, for me I use google sheet such that I can record data in a google sheet. but tons of other kind of THAT actions are possible. very large set of possibilities.

IFTTT provides the concept of ingredients on the webhook applet and ALTUI will call the webhook service of IFTTT with the following elements ( which are decided by IFTTT, this is not a choice of ALTUI ) :

- OccuredAt: the timestamp
- Eventname : the event name you have chosen
- value1: the altuiid of the VERA device sending the notification
- value2: the string <service>:<variable>
- value3: the string <old>:<new>

in the THAT applet configuration , you can choose how to use the THIS input ingredients to perform the THAT action.  in my google sheet example I just chose to add a new line to my spreadsheet

sample screen shots are attached to illustrate:
« Last Edit: December 01, 2017, 05:49:08 pm by amg0 »

Offline amg0

  • Moderator
  • Master Member
  • *****
  • Posts: 3099
  • Karma: +206/-8
Re: ALTUI & DataStorage Providers
« Reply #33 on: December 04, 2017, 12:14:33 pm »
ALTUI & IFTTT integration tutorial

This step by step tutorial will guide you through the new ALTUI IFTTT integration to log in a google sheet any watched device variable changes.

https://github.com/amg0/ALTUI/raw/master/Docs/IFTTT%20and%20VERA%20integration.pdf

Offline amg0

  • Moderator
  • Master Member
  • *****
  • Posts: 3099
  • Karma: +206/-8
Re: ALTUI & DataStorage Providers
« Reply #34 on: December 13, 2017, 02:44:54 pm »
Multiple data providers

Starting with v 2.07.2270 , ALTUI will support one or more data output streams whenever a device's variable changes.
The user interface to set this up will slighly change such that the user can really select one or several different data providers for a given variable.

That means it is now possible to send all data values changes to both a thingspeak graph , and an IFFF action for instance

Offline dklinkman

  • Full Member
  • ***
  • Posts: 129
  • Karma: +1/-0
Re: ALTUI & DataStorage Providers
« Reply #35 on: January 04, 2018, 04:55:48 pm »
Quick question.  How does one delete the datastorage provider from a variable?  Like if I configured the wrong variable?  I can't figure it out.  :o
VeraPlus, UI7, ALTUI on Chrome, Lots of devices and plugins including MQTT and MySensors.  Also playing around with openLuup

Offline amg0

  • Moderator
  • Master Member
  • *****
  • Posts: 3099
  • Karma: +206/-8
Re: ALTUI & DataStorage Providers
« Reply #36 on: January 04, 2018, 05:55:06 pm »
Quick question.  How does one delete the datastorage provider from a variable?  Like if I configured the wrong variable?  I can't figure it out.  :o
Unselect  it from the menu list ( Ctrl click for multiple selection ), then close to save

Offline dklinkman

  • Full Member
  • ***
  • Posts: 129
  • Karma: +1/-0
Re: ALTUI & DataStorage Providers
« Reply #37 on: January 05, 2018, 12:14:52 am »
That works. THANK YOU!!.  I'm getting too old for this  :-\ :-\ :-\ :-\.
VeraPlus, UI7, ALTUI on Chrome, Lots of devices and plugins including MQTT and MySensors.  Also playing around with openLuup

Offline dmckenna

  • Full Member
  • ***
  • Posts: 196
  • Karma: +8/-2
Re: ALTUI & DataStorage Providers
« Reply #38 on: January 05, 2018, 05:02:57 am »
Hi,

Has any used webhooks to send a request BACK to Altui/Vera ? If so how have you done it ?

Thinking about an application to use a Google Home/Alexa number/name IFTTT ingredient to set a Vera multistring variable that could then be picked up by PLEG in due course. e.g. OK Google, set the 'living room' temperature to '22'

Any suggestions ?

David

Offline dmckenna

  • Full Member
  • ***
  • Posts: 196
  • Karma: +8/-2
Re: ALTUI & DataStorage Providers
« Reply #39 on: March 22, 2018, 05:40:38 am »
AMG0,

Do you have any ideas on how to configure ALTUI to pass the value of a switch position/variable through to Webhooks ?

I've got a very clonky and non-elegant work around using PLEG but thought I'd ask if there's a more direct/seamless way with ALTUI that you've discovered......

Purpose - Virtual Switch (VS) device on Vera to control an IFTTT device.

Method - Create a Virtual Switch, configure ALTUI/Webhooks/IFTTT as detailed in this thread

Result - The iFTTT device responds to every state change of the Virtual Switch as opposed to On for On and Off for Off. e.g If the device is turned off manually and the VS is still in the On Position, then by clicking the VS to Off this actually then turns the state of the device to On - states become out of sync.

Workaround -  Configure IFTTT recipes for both On AND OFF states. Use PLEG to detect a trigger on the VS, use 2 actions in LUUP to send the native IFTTT maker and trigger keys for either ON or OFF. Use Vera IFTTT integration to detect when the IFTTT device state is changed locally and send that state back to Vera so devices are in sync. It works but it's not elegant and needs a lot of configuration for one device.

So.....could ALTUI do a better job ?

Thanks

David


Offline amg0

  • Moderator
  • Master Member
  • *****
  • Posts: 3099
  • Karma: +206/-8
Re: ALTUI & DataStorage Providers
« Reply #40 on: March 22, 2018, 10:46:20 am »
AMG0,

Do you have any ideas on how to configure ALTUI to pass the value of a switch position/variable through to Webhooks ?

I've got a very clonky and non-elegant work around using PLEG but thought I'd ask if there's a more direct/seamless way with ALTUI that you've discovered......

Purpose - Virtual Switch (VS) device on Vera to control an IFTTT device.

Method - Create a Virtual Switch, configure ALTUI/Webhooks/IFTTT as detailed in this thread

Result - The iFTTT device responds to every state change of the Virtual Switch as opposed to On for On and Off for Off. e.g If the device is turned off manually and the VS is still in the On Position, then by clicking the VS to Off this actually then turns the state of the device to On - states become out of sync.

Workaround -  Configure IFTTT recipes for both On AND OFF states. Use PLEG to detect a trigger on the VS, use 2 actions in LUUP to send the native IFTTT maker and trigger keys for either ON or OFF. Use Vera IFTTT integration to detect when the IFTTT device state is changed locally and send that state back to Vera so devices are in sync. It works but it's not elegant and needs a lot of configuration for one device.

So.....could ALTUI do a better job ?

Thanks

David

did you go through the doc in this post ?http://forum.micasaverde.com/index.php/topic,35860.msg335963.html#msg335963

Do you have any ideas on how to configure ALTUI to pass the value of a switch position/variable through to Webhooks ?
this is exactly what ALTUI's IFTTT data provider implementation does.  on a device's variable value change , the value is pushed to IFTTT with a web service ( http GET to a target url). You do not have to use IFTTT, you can accomplish this with other type of destinations (other than IFTTT) thanks to the open ALTUI data provider architecture which lets you dynamically add other data providers to ALTUI.  a few forum members did this already ( akbooer ,etc. )

I may not answer well your out of sync problem but it sounds to me it is something to be addressed somewhere else in VERA. the VS and the device should be kept in sync by other mean ( lua polling ? )
« Last Edit: March 22, 2018, 10:51:25 am by amg0 »

Offline powisquare

  • Full Member
  • ***
  • Posts: 139
  • Karma: +1/-0
Re: ALTUI & DataStorage Providers
« Reply #41 on: July 25, 2018, 06:18:45 am »
Quick question.  How does one delete the datastorage provider from a variable?  Like if I configured the wrong variable?  I can't figure it out.  :o
Unselect  it from the menu list ( Ctrl click for multiple selection ), then close to save

Am having trouble unselecting from the menu list. If I click 'away' from the menu it goes grey but closing or resaving does not seem to work. If I click on the menu list the service remains highlighted in blue.

Offline akbooer

  • Beta Testers
  • Master Member
  • *****
  • Posts: 6206
  • Karma: +276/-70
  • "Less is more"
Re: ALTUI & DataStorage Providers
« Reply #42 on: July 26, 2018, 03:06:08 am »
Am having trouble unselecting from the menu list. If I click 'away' from the menu it goes grey but closing or resaving does not seem to work. If I click on the menu list the service remains highlighted in blue.

It is as @amg0 said below:  ctrl-click (or cmd-click, depending on your OS preference.)

However, the trick is to save the change properly.  You HAVE to remember to click on the red 'Graph' icon to close the sub-window.  If you have deselected the last (or only) storage provider for that variable, then the icon will revert to its normal background colour.
3x Vera Lite-UI5/Edge-UI7, 25x Fibaro, 23x TKB, 9x MiniMote, 2x NorthQ Power, 2x Netatmo, 1x Foscam FI9831P, 9x Philips Hue,
Razberry, MySensors Arduino, HomeWave, AltUI, AltHue, DataYours, Grafana, openLuup, ZWay, ZeroBrane Studio.

Offline powisquare

  • Full Member
  • ***
  • Posts: 139
  • Karma: +1/-0
Re: ALTUI & DataStorage Providers
« Reply #43 on: July 26, 2018, 06:23:33 am »
Ty ak

Offline germano.veiga

  • Newbie
  • *
  • Posts: 1
  • Karma: +0/-0
Re: ALTUI & DataStorage Providers
« Reply #44 on: November 05, 2018, 07:11:14 am »
Good Evening.
I have been posting data (W) to emoncms, and I realized that there was a discrepancy between the measured kwh in the device and the accumulated Kwh provided by emoncms (feed is , PHPTimeSeries).

I explored a little, and I think the problem might be that ALTUI is not triggering whenever the data goes from xx Watt to 0 Watt.
Emoncms holds the previous value and therefore keeps accumulating.

I had made a workaround using the KWh directly from the device, but nevertheless I just want to let you know.
The example below is a towel heater that goes offline @08:00, and as you see the new value was not catched by emoncms (i double checked, and the towel heater is actually off 0.00watt in ALTUI).

I have the same behavior with FIBARO switches, plugs, and several other device brands (everspring, aeotec).

Thank you in advance.
Germano


2018-11-05 05:53:29, 0
2018-11-05 06:13:08, 0
2018-11-05 06:29:11, 187
2018-11-05 06:33:23, 64
2018-11-05 06:54:11, 0
2018-11-05 07:14:04, 188
2018-11-05 07:15:17, 0
2018-11-05 07:36:33, 0
2018-11-05 07:54:04, 192