RUTX09 Input/Output

From Wiki Knowledge Base | Teltonika Networks
This is the approved revision of this page, as well as being the most recent.
Main Page > RUTX Routers > RUTX09 > RUTX09 Manual > RUTX09 WebUI > RUTX09 Services section > RUTX09 Input/Output

The information in this page is updated in accordance with firmware version RUTX_R_00.02.04.1.

Summary[edit | edit source]

Inputs and outputs are used for monitoring and controlling a connected device or receiving signals from that device in order to trigger certain events. This chapter is an overview of the Input/Output section for RUTX09 devices.

If you're having trouble finding this page or some of the parameters described here on your device's WebUI, you should turn on "Advanced WebUI" mode. You can do that by clicking the "Basic" button under "Mode", which is located at the top-right corner of the WebUI.

Networking rutx manual webui basic advanced mode v1.gif

Characteristics

The router's input/output pins can be found inside the power socket:

Networking rutx manual input output status pinout v1.png


The electric characteristics for the input and output pins are as follows:

  • Digital non-isolated input:
    • logic low: 0 - 5 V
    • logic high: 8 - 40 V
  • Digital open collector output: 30 V, 300 mA

Status[edit | edit source]

The Status page displays the current states of the device input and output:

Networking rutx manual input output status v2.png

You can invert Input pin by clicking on slider in Inversion column and switch Output pin state by clicking on slider in State column.

Status from command line


You can also obtain the status of the input or output from the command line. List of ubus possible values in RUTX09 devices:

ioman.gpio.din1
ioman.gpio.dout1

Call command ubus call value status :

root@Teltonika-RUTX09:~# ubus call ioman.gpio.dout1 status
{
        "value": "0",
        "direction": "in",
        "bi_dir": false,
        "invert_input": false
}
  • din1 is the input:
    • "value": "0" means low level state.
    • "value": "1" means high level state.
  • dout1 is the output:
    • "value": "0" means low level state.
    • "value": "1" means high level state.

Post/Get[edit | edit source]

Enabling Post/Get will allow you to send HTTP POST/GET requests to device which controls the state of the output. The figure below is an example of the Post/Get configuration section and the table below provides information on the fields contained in that section:

Networking rutx manual input output post get v1.png

Field Value Description
Enable off | on; default: off Turns Post/Get on or off.
Username string; default: none Username used for authentication in POST/GET queries.
Password string; default: none Password used for authentication in POST/GET queries.

Post/Get examples[edit | edit source]


It is possible to turn the output on and off by using a valid HTTP POST/GET syntax. Use a web browser or any other compatible software to submit HTTP POST/GET strings to the device.

Below is a table containing syntax examples of this usage:

Action POST/GET URL
Turn Output state to high http://192.168.1.1/cgi-bin/io_state?username=user1&password=user1&pin=dout1&state=on
Turn Output state to low after 5 seconds for 3 seconds http://192.168.1.1/cgi-bin/io_state?username=user1&password=user1&pin=dout1&state=on&delay=5&time=3

Overview:

  • 192.168.1.1 - device default LAN IP address; replace it in accordance with your own configuration.
  • username - login name from Post/Get configuration.
  • password- password from Post/Get configuration.
  • state - turn Output on or off.
  • delay - defines a delay (in seconds) after which the specified action will be performed.
  • time - defines a window of time during which the action will take place. For instance, if you post an on action while specifying time=5, the output will turn on and stay on for 5 seconds before turning off.

Delay and time parameters can be used together. For example, if delay is 10, time is 5, action is on, then 10 seconds after the execution of the command, the output will switch to on (or stay in on state if it was already that way), then after 5 more seconds it will switch to off state. In this case the overall command execution time is 15 seconds.

Scheduler[edit | edit source]

With the help of the output Scheduler you can configure a timetable of when the output should be enabled or disabled based on date and time. By default everything is unset.

Networking rutx manual input output output scheduler v2.png

Io juggler[edit | edit source]

The Io juggler page is used create automated actions based on Input state and conditions.

General[edit | edit source]


The General section allows you to create automated Actions based on selected Inputs and their trigger state. The figure below is an example of Conditions section.

Networking rutx manual input output iojuggler general v1.png


Modify Input configuration[edit | edit source]


You can find explanation about fields in the table below this illustration.

Networking rutx manual input output iojuggler general modify v1.png

Field Value Description
Enabled off | on; default: off Changes current profile to specified one when action triggers.
Trigger interval positive integer; default: none Specifies what is the shortest amount of seconds between triggers.
Trigger Rising | Falling | Both; default: Rising Specifies on which trigger state this rule will be activated.
Add actions actions; default: none Specifies actions which have to be met for rule to be executed. Actions are optional.
Add conditions conditions; default: none Specifies conditions which have to be met for action to occur. Conditions are optional.

Actions[edit | edit source]


The Actions section lets you manage your created Actions for IO Juggler inputs. The figure below is an example of Actions section.

Networking rutx manual input output iojuggler actions v1.png

Modify action[edit | edit source]


Networking rutx manual input output iojuggler actions modify v1.png

Above is an example of what action configuration window looks like. Below is a table with detailed explanations on how to configure the action and what each of the fields mean. To avoid redundancy, screenshots for the other actions will not be provided, since the structures, syntax and the overall look of the configuration windows for each action are very similar. Instead, only tables containing information on how to edit each action will be provided.

Profile[edit | edit source]

Field Value Description
Type Profile Changes current profile to specified one when action triggers.
Execution delay positive integer; default: none How many seconds will pass before the action is excecuted after it's triggered.
Profile profile; default: default Choose a profile that will be applied when the action triggers.
Add conditions conditions; default: none Specifies conditions which have to be met for action to occur. Conditions are optional.


Email[edit | edit source]

Field Value Description
Type Email Sends email when action triggers.
Subject string; default: none Subject of email.
Text message string; default: none Text message to be sent in email. Below this field you can find device information and their codes, which can be included in messages to send device information.
Execution delay positive integer; default: none How many seconds will pass before the action is excecuted after it's triggered.
Email user email user; default: none Configured email user.
Recipient's email address string; default: none Email receiver(s).
Add conditions conditions; default: none Specifies conditions which have to be met for action to occur. Conditions are optional.
SMS

Field Value Description
Type SMS Sends sms when action triggers.
Text message string; default: none Text message to be sent in sms. Below this field you can find device information and their codes, which can be included in messages to send device information.
Execution delay positive integer; default: none How many seconds will pass before the action is excecuted after it's triggered.
Recipients Single number | Group; default: Single number How many recipients will get the message.
Single number: Recipient's phone number number; default: none SMS receiver.
Group: Phone group phone group; default: none SMS receivers.
Add conditions conditions; default: none Specifies conditions which have to be met for action to occur. Conditions are optional.

Note: this table has coloring scheme to indicate which fields can be seen with different configuration.

Output[edit | edit source]

Field Value Description
Type Output Changes Output state when action triggers.
Execution delay positive integer; default: none How many seconds will pass before the action is excecuted after it's triggered.
Control output; default: Output(4) Specifies the output of which the state will be changed.
Revert integer; default: 0 After how many seconds the state will revert. If left 0 or empty the state will not revert.
Maintain off | on; default: on Maintain this IO state after reboot.
Invert off | on; default: off On action inverts pin state.
State copying off | on; default: off Copies the state from selected input to selected output.
State High | Low; default: High Specifies what state the output pin will be set to.
Add conditions conditions; default: none Specifies conditions which have to be met for action to occur. Conditions are optional.


HTTP[edit | edit source]

Field Value Description
Type HTTP Sends HTTP request when action triggers.
Execution delay positive integer; default: none How many seconds will pass before the action is excecuted after it's triggered.
Method Get | Post; default: Get Specifies the output of which the state will be changed.
URL string; default: none URL to send request to.
Verify off | on; default: off Verifies the validity of certificates, only works for https.
Parameters string; default: none Parameters and their value from device for usage in Post or Get requests. Possible values: Time stamp, UNIX time, WAN MAC, Wired WAN IP, Network info, Product code, LAN MAC address, LAN IP address, Serial number, Current FW version, Monitoring status, Input Name, Input state change trigger, RSCP, ECIO, SIM slot in use, CELLID, RSRQ, SINR, RSRP, SIM State, SIM pin state, Modem model, IMSI, Modem serial number , Network State, Data connection state, Connection type, Mobile IP, Operator name, Signal strenght, IMEI, ICCID, Neighbour cells, Network serving.
Add conditions conditions; default: none Specifies conditions which have to be met for action to occur. Conditions are optional.


Script[edit | edit source]

Field Value Description
Type Script Runs script when action triggers.
Execution delay positive integer; default: none How many seconds will pass before the action is excecuted after it's triggered.
Specify path Upload a script | Specify path; default: Upload a cript Selection to upload a script or specify its absolute path in device.
Upload a script: Custom script -(interactive button) Shows file upload window on click.
Specify path: Script file string; default: none Absolute path to script file in device.
Arguments string; default: none Optional arguments which can be provided for the script. You can include device information with values given below this input field.
Add conditions conditions; default: none Specifies conditions which have to be met for action to occur. Conditions are optional.

Note: this table has coloring scheme to indicate which fields can be seen with different configuration.

Reboot[edit | edit source]

Field Value Description
Type Reboot Reboots device when action triggers.
Execution delay positive integer; default: none How many seconds will pass before the action is excecuted after it's triggered.
Add conditions conditions; default: none Specifies conditions which have to be met for action to occur. Conditions are optional.
Change sim

Field Value Description
Type Change sim Changes active sim card when action triggers.
Execution delay positive integer; default: none How many seconds will pass before the action is excecuted after it's triggered.
Flip off | on; default: off Switches to a different sim card.
Off: Target Sim1 | Sim2; default: Sim1 Switches to a selected sim card.
Add conditions conditions; default: none Specifies conditions which have to be met for action to occur. Conditions are optional.

Note: this table has coloring scheme to indicate which fields can be seen with different configuration.

Conditions[edit | edit source]


The Conditions section lets you manage your created Conditions for IO Juggler Actions. The figure below is an example of Conditions section.

Networking rutx manual input output iojuggler conditions v1.png

Modify condition[edit | edit source]


Networking rutx manual input output iojuggler conditions modify v1.png

Above is an example of what condition configuration window looks like. Below is a table with detailed explanations on how to configure the condition and what each of the fields mean. To avoid redundancy, screenshots for the other conditions will not be provided, since the structures, syntax and the overall look of the configuration windows for each condition are very similar. Instead, only tables containing information on how to edit each condition will be provided.

Boolean group[edit | edit source]

Field Value Description
Condition type Boolean group A type of condition.
Boolean type AND | NAND | OR | NOR; default: AND Type of boolean condition.
Add conditions conditions; default: none Specifies conditions which have to be met for action to occur. Conditions are optional.


I/O[edit | edit source]

Field Value Description
Condition type I/O A type of condition.
I/O inputs/outputs; default: Output(4) Specifies the I/O to which the condition is listening to.
State High | Low; default: High Specifies in what state the pin has to be.



Minute[edit | edit source]

Field Value Description
Condition type Minute A type of condition.
Inverted function off | on; default: off Inverts the selected condition type. Makes the condition true if the time/date is outside the specified interval.
Interval off | on; default: off Switches between a specific value and a time interval.
Off: Minute integer [0..59]; default: none Specifies minute at which the action can occur.
On: Start minute integer [0..59]; default: none Specifies starting minute of the interval at which the action can occur.
On: End minute integer [0..59]; default: none Specifies ending minute of the interval at which the action can occur.

Note: this table has coloring scheme to indicate which fields can be seen with different configuration.

Hour[edit | edit source]

Field Value Description
Condition type Hour A type of condition.
Inverted function off | on; default: off Inverts the selected condition type. Makes the condition true if the time/date is outside the specified interval.
Interval off | on; default: off Switches between a specific value and a time interval.
Off: Hour integer [0..59]; default: none Specifies hour at which the action can occur.
On: Start hour integer [0..59]; default: none Specifies starting hour of the interval at which the action can occur.
On: End hour integer [0..59]; default: none Specifies ending hour of the interval at which the action can occur.

Note: this table has coloring scheme to indicate which fields can be seen with different configuration.

Weekday[edit | edit source]

Field Value Description
Condition type Weekday A type of condition.
Inverted function off | on; default: off Inverts the selected condition type. Makes the condition true if the time/date is outside the specified interval.
Interval off | on; default: off Switches between a specific value and a time interval.
Off: Weekday weekday; default: Monday Specifies weekday at which the action can occur.
On: Start weekday weekday; default: Monday Specifies starting weekday of the interval at which the action can occur.
On: End weekday weekday; default: Monday Specifies ending weekday of the interval at which the action can occur.

Note: this table has coloring scheme to indicate which fields can be seen with different configuration.

Month day[edit | edit source]

Field Value Description
Condition type Month day A type of condition.
Month override off | on; default: off If the option is selected and the specified day is not in the month then the condition uses the last day of the month.
Interval off | on; default: off Switches between a specific value and a time interval.
Off: Day of the month integer [1..31]; default: none Specifies day of the month at which the action can occur.
On: Start day of the month integer [1..31]; default: none Specifies starting day of the interval of the month at which the action can occur.
On: End day of the month integer [1..31]; default: none Specifies ending day of the interval of the month at which the action can occur.

Note: this table has coloring scheme to indicate which fields can be seen with different configuration.

Year[edit | edit source]

Field Value Description
Condition type Year A type of condition.
Inverted function off | on; default: off Inverts the selected condition type. Makes the condition true if the time/date is outside the specified interval.
Interval off | on; default: off Switches between a specific value and a time interval.
Off: Day of the year integer [1..366]; default: none Specifies day of the year at which the action can occur.
On: Start day of the year integer [1..366]; default: none Specifies starting day of the interval of the year at which the action can occur.
On: End day of the year integer [1..366]; default: none Specifies ending day of the interval of the year at which the action can occur.

Note: this table has coloring scheme to indicate which fields can be seen with different configuration.