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.

Program Start at Reboot

Featured Replies

Posted

I want to run a program at reboot (power failure) so I can manually reset the value of a couble program variables that need to be persisted. I'll upgrade to 3.1.? when I have time but system is rock solid and I don't need another project now :-)

 

Easy enough to say run at startup but what "if" condition should I use? Device status, schedule etc?

There is no requirement for anything to be in the If. The following Program which is marked to run at startup sets $IVar4 to 10

 

If

- No Conditions - (To add one, press 'Schedule' or 'Condition')

 

Then

$IVar4 = 10

 

Else

- No Actions - (To add one, press 'Action')

 

EDIT: 3.1.10 has been solid except for a network resource issue that is fixed by applying 3.1.11 on top of 3.1.10. 3.1.10 has to be installed first as 3.1.11 is a firmware only fix. 3.1.11 is required only if having a problem with Network Module network resources not working when the WeatherBug module is not installed.

I want to run a program at reboot (power failure) so I can manually reset the value of a couble program variables that need to be persisted. I'll upgrade to 3.1.? when I have time but system is rock solid and I don't need another project now :-)

 

Easy enough to say run at startup but what "if" condition should I use? Device status, schedule etc?

 

That is what the "init" value for the variables does. Whatever program sets your variables in the first place just needs to simultaneously init the value. No need to run a program at reboot, the variable will automatically go to the init value.

 

The program below is an example. The program sets the variable and then it immediately changes the init value so it will persist through a power failure. You should do this with all variables you want to persist through a power failure. The only time you shouldn't do it is if you want a power failure to cause the variable to be different. Then right a program that runs only at startup.

 

If
  - No Conditions - (To add one, press 'Schedule' or 'Condition')

Then
       $iOdd.Even.Day  = $iDay.of.Month
       $iOdd.Even.Day %= 2
       $iOdd.Even.Day Init To $iOdd.Even.Day

Else
  - No Actions - (To add one, press 'Action')


  • Author

...just assumed program had to have a condition. Thanks for information about 3.1.?, UD always has solid software and the best support of any product I've ever purchased.

 

I've had HS for years starting in X10 days -- only use it today for interface to DSC panel so I'm look forward to upgrading to variables, implementing DSCLink and retiring HS 2.x. We'll see if 3.x adds any value but I doubt it since all I read is Zwave as in waving goodbye :-)

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.