Jump to content
View in the app

A better way to browse. Learn more.

Universal Devices Forum

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Triggering Events to send messages

Featured Replies

Posted

I currently have a program to trigger a text notification for my garage door when the Garage sensor is status off or on.

If
Status 'Garage-Sensor' is off
and $GarageDoorOpen is 0
Then 
Send Notification 'Text' content 'GarageDoorOpen'
$GarageDoorOpen =1
Set 'OutdoorModule' On
$Garage_Light_On = 1
Wait 10 Minutes
Set 'OutdoorModule' Off
$Garage_Light_On = 0

Else

The notification works fine, but also triggers the following program which causes two text messages.

I assumed since the time is stated in the if statement this  program it would not trigger, but it does.  Am I missing something?

Time is 9:00pm
And 
(Status 'Garage-Sensor' is off
And $Garage_Light_On is 0
And $GarageDoorOpen is 1
)
Then 
Set 'GarageRelay'  On
$GarageDoorOpen =0
Else
Send Notification 'Text' content 'GarageDoorOpen'

Thanks.

The Program will trigger with a False evaluation invoking the Else clause.

 

EDIT: at a minimum a change in Garage-Sensor state will trigger the Program. The variables $Garage_Light_On and $GarageDoorOpen could trigger the Program as well if they are State variables.

Edited by LeeG

If you only want the then/else to run at 9pm then one way is to move everything except the time is 9pm to a separate program that is disabled, and run that program at 9pm.

 

Sent from my Nexus 7 using Tapatalk

  • Author

Thanks for the replys.  I will give it a shot tonight.

Edited by 3gdigital

Guest
This topic is now closed to further replies.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.