Run and Manage SDK scripts using the Web Interface

The SDK page in the web interface is a centralised place from which to load, manage and execute SDK scripts.

Enable the SDK service

Main Menu
Services
Side Menu
SDK
Administration
Job Management
Testing
Administrative status

Test SDK with a 'Hello World' Script

Side Menu
SDK
Administration
Job Management
Testing
SDK Testing
				
					printf("hello world\n");
				
			
Result

Your script says:

hello world

Configuration

The job management system is made up of three parts: a script, an event trigger and your jobs themselves.

Scripts

The first step to using this tool for automation purposes would be creating some basic tasks in the form of scripts which can do things like specific functions such as sending an SMS, mounting a USB stick or listening to a serial interface – all while returning results that tell us whether they were successful.

Triggers

Triggers allow you to start the action at a certain point in time or when something happens. Triggers can be based on programmable events happening inside your router, like incoming calls and other various things which happen with interfaces powered up/off etc. A trigger can also be initiated through the command line interface (CLI).

Jobs

For each job, a script can be assigned and executed when the trigger event occurs for that particular task. Scripts can be linked to different triggers under a Job.

Job Management

Main Menu
Services
Side Menu
SDK
Administration
Job Management
Testing

Adding a Script

Main Page
Scripts
Add a new Script
Name
Hello_World
Description
Hello World Test Script
Arguments
Action
printf(“hello %s\n”, argv[1]);

Adding a Trigger

Main Page
Triggers
Add a new Trigger
Name
Trigger_Event
Type
Event
wan-up

Adding a Job

Main Page
Jobs
Add a new Job
Name
wan-up-hello-world
Trigger
Trigger_Event
Scripts
Hello_World
Arguments
world

Debug

View the output from the script after it executed.

Main Menu
Services
Side Menu
SDK
Administration
Job Management
Testing
Main Page
Troubleshooting
Select job
wan-up-hello-world
Click
View
Output
				
					hello world
=== job 0 ended at 2022-10-04 04:46:00 (with exit code 0)