This Configuration Guide shows how to configure an automated fallback upon the change of a profile.
Situation
An INSYS Smart Device is located at a remote place. It is necessary to change the configuration of this device from remote. In case of a failure during the modifications to the configuration, it might happen that the device becomes inaccessible. This would require to reset the device on-site. To avoid this, you can use an automated fallback to the previous profile (configuration).
Solution
It is prerequisite that you have access to the web interface of the router. You’ll first make a copy of the working profile as a basis for your modifications. You’ll then add a timer and an event that restores the previous (working) profile after a certain time to the new copied profile. You can then make the necessary modifications. After activating the modified profile, a timer will start. If the timer expires it will trigger an event that restores the previous (working) profile in case the modifications have made the device inaccessible. If the modifications turn out to work well, you can delete the timer and the event again and continue to operate the device with the new, modified profile (configuration).
Failed to generate image: Could not find Java executable +-----------+ +-----------+ | running | copy&rename | fallback | | profile |------------>| profile | +-----------+ +-----------+ | ^ |add fallback event | |add other modifications | v | +-----------+ | | modified | | | profile | | +-----------+ activate| | | |activate | v | +-----------+ | | timer | | | starts | | +-----------+ | | | v | /-----------\ +-----------+ | profile | no wait | timer | |accessible?|------------>| expires | \-----------/ +-----------+ |yes | |remove fallback event |before timer expires v +-----------+ | new | | profile | +-----------+
-
Open web interface of the router using a browser: 192.168.1.1 [1]
-
In the Administration → Profiles menu, select the Running profile under Create profile from and click on Create profile.
-
Rename the Running_copy profile to Fallback_profile by editing the name.
-
Click on Save settings.
-
In the Events → Timer menu, add a new timer () and edit it ().
-
Enter a Description, select Interval timer and enter an appropriate fallback interval. [2]
-
Click on Save settings.
-
In the Events → Events menu, add a new event () and edit it ():
-
Description: Fallback event
-
Event: Timer expired
-
Timer: select above added fallback timer
-
Action: Activate profile
-
Activate profile: select the Fallback_profile
-
-
Click on Save settings.
-
Now proceed with your modifications to the configuration.
-
When finished, activate the profile by clicking the blinking gear in the title bar ().
If your device becomes inaccessible due to the modifications to the profile now, you just need to wait until the fallback timer expires to get access to the device again that will then run with the fallback profile.
Please note that the fallback profile will be activated while the modified profile will still remain opened for editing. |
If your new configuration turns out to operate well, proceed as follows to remove the timer and event again:
-
In the Events → Events menu, remove the fallback event ().
-
In the Events → Timer menu, remove the fallback timer ().
-
Activate the profile by clicking the blinking gear in the title bar ().
We’ve prepared the following ASCII configuration file for adding the timer and event. Copy and paste it to your text editor or download it using the link below.
The ASCII configuration file will add a timer to an already existing list of timers using the function [last]. Then, an action will be added that uses this timer as a triggering event.
events.timer.timer.add
events.timer.timer[last].active=1
events.timer.timer[last].description=Fallback timer
events.timer.timer[last].type=interval
events.timer.timer[last].interval_hh=00
events.timer.timer[last].interval_mm=30
events.event_config.event.add
events.event_config.event[last].active=1
events.event_config.event[last].description=Fallback event
events.event_config.event[last].event_type=ev_timer
-----LUA-----
cli("events.event_config.event[last].event_timer_name=timer"..cli("events.timer.timer.size").."")
-----LUA-----
events.event_config.event[last].event_action_type=act_profile
events.event_config.event[last].event_action_profile=Fallback_profile
A short Lua script is used to determine the size of the timer list and use it to compose the timer name of the added timer. Refer to the Configuration Guide Adding a List Parameter to a Profile Using Lua to find out more about Lua and adding an ASCII configuration file.
Back to the Configuration Guides for icom OS Smart Devices
Back to overview