iRidi for EPSNET
a toolkit for creating control interfaces for Teco and iNELS using the EPSNET protocol
Documentation updated 01.01.2024
Description
iRidi for EPSNET is a toolkit for creating a home or office control interface based on Teco (Tecomat) or iNELS equipment that supports the EPSNET protocol.
Connection
Equipment configuration and settings required for iRidi to control equipment using the EPSNET protocol.
PLC connection methods
Different connection methods support local operation and operation over the Internet:

- Local connection

-
Internet connection
-
A local connection works only on the automation site's local network. It uses UDP. The connection is established between the control panel and the controller through a network router.
-
An Internet connection lets you connect to the controller over the Internet. To operate in this mode, the network router must have a static IP address or use a DDNS service.
You can add an EPSNET driver by importing a CSV file or entering the data manually.
Importing a CSV file (*.csv)
Universal import from CSV File lets you import drivers from a table in CSV format.
For detailed instructions on creating a CSV file and importing it into iRidi Studio, follow this link.
Adding an EPSNET driver to iRidi
EPSNET cannot automatically generate a list of devices that can be controlled, so add them manually.

Drag the selected driver from DEVICE BASE to PROJECT DEVICE PANEL.
- Host - controller IP address
- Port - UDP control port, 61682
- Update Time (ms) - data update interval
A convenient way to create commands for the EPSNET driver is to use an export file in .PUB format, generated by Mosaic (TECO) and IDM (iNELS).
1(a). Prepare Mosaic:
If you have already generated a *.pub file (compiled the project), delete the previous *.pub file before generating it again; otherwise, the addresses in the project will be duplicated.

1(b). Prepare IDM iNELS:
Make sure IDM is connected to the controller; otherwise, export is not possible.

2. Select the variables to export in the device's control software: "Unit/device manager". You must specify the NAMES of the exported variables:
3. Open "Project setup" and specify the path for saving the export file. The tab may be named '... of SCADA' or 'RELI':
4. To export the .pub file to the PC, reload the configuration onto the controller:
5. Open the *.pub file in a text editor. It contains a list of addresses in a format supported by iRidi:

Commands & Feedbacks
The data from the *.PUB file must be transferred to iRidi to control EPSNET registers. Configure the registers by examining the lines in the PUB file, each of which corresponds to one register:
DAC2_04M_OUT1_ON R B 18237 .1 BOOL PUB_INOUT
| | | | | |
|_"Name" | | | |_"Type" | read only (IN)
| | | |_read and write (INOUT)
"Register"_| |_"Address"
|
"Bit"_|
An EPSNET register in iRidi Studio:

- Name - register name
- Type - data type; see the mapping table
- Register - register type
- Address - register number
- Bit - bit number within the byte (for Bool)
Add all required registers to the iRidi project, selecting parameters from the corresponding values in the *.PUB file.
A register with the PUB_INOUT property can be read and written; create it in the Commands and Feedback tabs.
A register with the PUB_IN property can only be read; create it only in the Feedback tab.
Type (in the PUB file and iRidi Studio):
| PUB file | iRidi Studio | Description | Range |
|---|---|---|---|
| BOOL | Bool | Boolean | 0…1 |
| SINT | Signed 8 bit | Short integer | -128…127 |
| INT | Signed 16 bit | Integer | -32 768…32767 |
| DINT | Signed 32 bit | Double integer | -2147483648…2147483647 |
| USINT | Unsigned 8 bit | Unsigned short integer | 0…255 |
| UINT | Unsigned 16 bit | Unsigned integer | 0…65535 |
| UDINT | Unsigned 32 bit | Unsigned double integer | 0…4294967295 |
| REAL | Float 32 bit | Real (single precision) | ±2.9E-39…±3.4E+38 |
| LREAL | Float 64 bit | Long real (double precision) | IEC 559 |
| TIME | Time | Duration | 24d 20:31:23.647 |
| DATE | Date | Data (only) | from 1.1.1970 00:00:00 |
| TIME_OF_DAY (TOD) | Time of Day | Time of day (only) | 24d 20:31:23.647 |
| DATE_AND_TIME (DT) | Date Time | Data and time of day | from 1.1.1970 00:00:00 |
Commands and feedback channels must be linked to the project's graphic items to control equipment:
- Link a command to a graphical item and specify the value to send to the register when the item is pressed
- Link a feedback channel to a graphical item to display the register state
To link a command or channel to a graphical item, use
drag&drop
- dragging.
To quickly create a Feedback with the same settings as a Command, right-click the Command and select "Create Feedback". You can create Feedbacks for several registers at once.
Changing connection settings
You need to change connection parameters when you disconnect from the automation site's Wi-Fi network and start using 3G or another Wi-Fi network. For control to continue working, switch from the local IP address to the Internet router's public IP address.
Switching is not automatic; you need to press the connection mode selection button. For remote access, the automation system's control ports must be made public. To do this, configure Port Forwarding on the Internet router. A VPN can provide a secure connection.
-
Download the template (*.js) (right-click and save the target), then add it to the script editor using (+) Add Script from file
-
Configure the script parameters as shown in the example:
function Internal_1() {
IR.GetDevice("EPSNET (UDP)").SetParameters({Host: "192.168.0.100", Port: 61682, UpdateTime: 1000});
}
function External_1() {
IR.GetDevice("EPSNET (UDP)").SetParameters({Host: "215.110.10.10", Port: 61682, UpdateTime: 1000});
}
Copy the driver name from Project Device Panel; copy the parameter list exactly as shown in the example.
- Select the button that will switch between the Internal and External parameters. Open the macros editor for the Press event (Object Properties > Programming), select the Script call command, and double-click to add it. Select the name of the function the button will call:

Each button press now applies the corresponding connection settings.
Equipment control

To control equipment, configure Commands and Feedbacks. To send a command, drag it onto a graphical item and specify the Value to send. To display feedback, drag the Feedback onto a graphical item and specify how to display its Value.
For more information about graphical items, see Graphical item types.
The available command and feedback channel settings are shown below:
BOOL
A BOOL (Bool) register is controlled by a logical zero or one. When configuring it, you must select the bit to control in addition to the register number.
Command
| Type | Value * | Description |
|---|---|---|
| Bool | 0...1 | BOOL data type and value to write |
| Register | X, Y, S, R, E, D0, D1, D2, Unknown | register type from the *.PUB table |
| Address | 0...n | register number |
| Bit | 0...7 | bit number within the byte |
*Value - specify this when dragging the command onto a graphical item
Feedback
| Type | Bool | BOOL data type |
|---|---|---|
| Register | X, Y, S, R, E, D0, D1, D2, Unknown | register type from the *.PUB table |
| Address | 0...n | register number |
| Bit | 0...7 | bit number within the byte |
| Value * | 0...1 | bit state |
- Value - received by the feedback channel; use it to display the value on items
SINT, INT, DINT, USINT, UINT, UDINT
8, 16, and 32-bit data registers are controlled using a range of values:
Command
| Type | Value * | Description |
|---|---|---|
| Signed 8 bit | -128...127 | SINT data type and value to write |
| Signed 16 bit | -32 768...32767 | INT data type |
| Signed 32 bit | -2147483648...2147483647 | DINT data type |
| Unsigned 8 bit | 0...255 | USINT data type |
| Unsigned 16 bit | 0...65535 | UINT data type |
| Unsigned 32 bit | 0...4294967295 | UDINT data type |
| Register | X, Y, S, R, E, D0, D1, D2, Unknown | register type from the *.PUB table |
| Address | 0...n | register number |
- Value - specify this when dragging the command onto a graphical item
Feedback
| Type | Value * | Description |
|---|---|---|
| Signed 8 bit | -128...127 | SINT data type and possible value |
| Signed 16 bit | -32 768...32767 | INT data type |
| Signed 32 bit | -2147483648...2147483647 | DINT data type |
| Unsigned 8 bit | 0...255 | USINT data type |
| Unsigned 16 bit | 0...65535 | UINT data type |
| Unsigned 32 bit | 0...4294967295 | UDINT data type |
| Register | X, Y, S, R, E, D0, D1, D2, Unknown | register type from the *.PUB table |
| Address | 0...n | register number |
- Value - received by the feedback channel; use it to display the value on items
REAL, LREAL
32 and 64-bit floating-point data registers are controlled using a range of values. Unlike integer registers, they accept fractional values (and return fractional values from the controller):
Command
| Type | Value * | Description |
|---|---|---|
| Float 32 bit | ±2.9E-39…±3.4E+38 | REAL data type and value to write |
| Float 64 bit | IEC 559 | LREAL data type |
| Register | X, Y, S, R, E, D0, D1, D2, Unknown | register type from the *.PUB table |
| Address | 0...n | register number |
- Value - specify this when dragging the command onto a graphical item
Feedback
| Type | Value * | Description |
|---|---|---|
| Float 32 bit | ±2.9E-39…±3.4E+38 | REAL data type and possible value |
| Float 64 bit | IEC 559 | LREAL data type |
| Register | X, Y, S, R, E, D0, D1, D2, Unknown | register type from the *.PUB table |
| Address | 0...n | register number |
- Value - received by the feedback channel; use it to display the value on items
STRING
Command
| Type | Value * | Description |
|---|---|---|
| Register | X, Y, S, R, E, D0, D1, D2, Unknown | register type from the *.PUB table |
| Address | 0...n | register number |
| Value * | string123 | string to write to the register |
- alue - specify when dragging the command onto a graphical item
Feedback
| Type | Value * | Description |
|---|---|---|
| Register | X, Y, S, R, E, D0, D1, D2, Unknown | register type from the *.PUB table |
| Address | 0...n | register number |
| Value * | string123 | string received from the register |
- Value - received by the feedback channel; use it to display the value on items
TIME, DATE, TIME_OF_DAY, DATE_AND_TIME
Time and date can be read and written. The format used for writing must exactly match the specified format. It is recommended to set the time and date using the controller and only display the received data in the application.
Command
| Type | Value * | Description |
|---|---|---|
| Time | 24d 20:31:23.647 | TIME data type |
| Date | 1.1.1970 00:00:00 | DATE data type |
| Time of Day | 24d 20:31:23.647 | TIME_OF_DAY (TOD) data type |
| Date Time | 1.1.1970 00:00:00 | DATE_AND_TIME (DT) data type |
| Register | X, Y, S, R, E, D0, D1, D2, Unknown | register type from the *.PUB table |
| Address | 0...n | register number |
- Value - specify this when dragging the command onto a graphical item
Feedback
| Type | Value * | Description |
|---|---|---|
| Time | 24d 20:31:23.647 | TIME data type |
| Date | 1.1.1970 00:00:00 | DATE data type |
| Time of Day | 24d 20:31:23.647 | TIME_OF_DAY (TOD) data type |
| Date Time | 1.1.1970 00:00:00 | DATE_AND_TIME (DT) data type |
| Register | X, Y, S, R, E, D0, D1, D2, Unknown | register type from the *.PUB table |
| Address | 0...n | register number |
- Value - received by the feedback channel; use it to display the value on items
JavaScript can generate a date and time value based on the control panel's current time