OpenGarage Forums Comments, Suggestions, Requests Check to see door is open before closing with IFTTT and apilio.io Reply To: Check to see door is open before closing with IFTTT and apilio.io

#532

bgnome
Participant

Now with IFTTT, I required an applet that sets Opengarage_status and an applet that will CLick the button for OG. After that, you can make up any applet to open or close your garage door based on whatever trigger you want.

So on IFTTT:

Applet: Whenever OpenGarage changes status, send to apilio.io
Trigger: Receive a web request
Event Name: opengarage
Action: Make a web request
URL: (Copy “Set value” link from Opengarage_status variable but replace “your-value-goes-here” with Value1 from IFTTT ingredients list)
Method: Get

Applet: Web request to click button for OpenGarage
Trigger: Receive a web request
Event Name: Click
Action: Make a web request
URL: (Use the link that triggers a button press on your OG set up previously)

Example of an applet to close the door
Applet: If garage door is open at 10:00 PM, then close door
Trigger: Every day at
Time: 10pm
Action: Make a web request
URL: (Use “Evaluate” link from close_door logicblock)
Method: Get

Example of an applet to open the door
Applet: If You say “Alexa trigger garage door open”, then check and open garage door
Trigger: Say a specific phrase
Phrase: garage door open
Action: Make a web request
URL: (Use “Evaluate” link from open_door logicblock)
Method: Get

The first applet fires everytime OG sends IFTTT a notification. Value1 will be something like “My OpenGarage just closed!” and is stored under Opengarage_status. Whenever an applet triggers one of the logicblocks, it checks to see if Opengarage_status contains “OPENED” or “closed” then if the argument is positive, will send a Click back to IFTTT. If there is a negative result, I have it send Already_open or Aleady_closed to IFTTT which then sends the appropriate notification, but this is optional.

This process could be cleaner if we could get the garage door status directly from Blynk or the OG and then send the button click based on that value. However, I could not figure out how to read a value in IFTTT without some sort of trigger or send that same value once it was read. Once I figured out that the opengarage event that is sent to IFTTT by the OG when activated actually contains the text for the notification in Value1, I figured I could use that as my conditional flag for apilio.io. I am hoping that eventually an independent open and close function get incorporated into the firmware or we get a native IFTTT service, but so far it has been a lot of fun figuring this stuff out.

  • This reply was modified 7 years, 3 months ago by bgnome.