Skip to main content
Version: 8.3

SECS/GEM Equipment Connections

Connection Types​

Equipment connections can be configured using either Ethernet or serial communication, depending on what the equipment supports. Ethernet connections use the HSMS protocol (SEMI E37) over TCP/IP and are the preferred option due to higher performance and reliability. Serial connections use the SECS-I protocol (SEMI E4) over an RS-232 connection and require the equipment to be directly connected to the Ignition Gateway server.

Equipment Connection Properties​

When setting up an equipment connection through either ethernet or serial, there are various properties that can be configured. For more details on adding a connection, see the Creating an Equipment Connection example.

Common Properties​

Property NameDescription
Equipment NameThe name of the equipment connection.
Equipment DescriptionA description of the equipment connection.
EnabledEnables or disables communication between the Gateway and the equipment. Default is TRUE.
Device IDA unique integer identifier defined by the equipment. Default is 0.
Database ConnectionThe database connection used for configuration data and message auditing.
Database Table PrefixAn optional prefix added to database table names to distinguish records for different equipment connections.
SECS Definition Language (SDL) FileThe SDL file used to validate SECS messages. If not specified, the default messages.sdl file is used.
T3 Reply TimeoutThe number of seconds to wait for an expected SECS reply message. Default is 45.

Ethernet/HSMS Connection Properties​

These properties apply only to equipment connections that use the Ethernet/HSMS connection type.

Property NameDescription
Active IP AddressIP Address of the equipment to connect to when in Active mode. Default is localhost.
Active PortThe Port number of the equipment to connect to when in Active mode, which must match the port number used to create the Simulator. Default is 5000.
Passive IP AddressIP Address of the equipment to connect to when in Passive mode. Default is localhost.
Passive PortThe Port number that an Equipment will connect to if the SECS/GEM module is in passive mode. Default is 5000.
Connection ModeThe method used to connect to Equipment.
  • ACTIVE: Will attempt to connect to the equipment at the given Active IP Address and Active Port. Default.
  • PASSIVE: Will listen for a connection from the equipment at the given Passive IP Address and Passive Port.
  • ALTERNATING: Will switch between Active mode and Passive mode until a connection is made.
T5 Connect Separation TimeoutThe number of seconds which must elapse between successive attempts to connect to the equipment after disconnection. Default is 10.
T6 Control Transaction TimeoutThe number of seconds which a control transaction (such as LinkTest or Select) may remain open before it is considered a communications failure. Default is 5.
T7 Not Selected TimeoutThe number of seconds which a TCP/IP connection can remain in NOT SELECTED state (i.e. no HSMS activity) before it is considered a communications failure. This timeout is only used for Passive Connection Mode. Default is 10.
T8 Network Intercharacter TimeoutThe maximum number of seconds between successive bytes of a single HSMS message before it is considered a communications failure. This applies to HSMS messages received from the equipment. Default is 5.
Keep Alive TimeoutThe number of seconds interval for sending LinkTest control messages for testing a connection. Automatically reconnects if the test fails. A value of 0 will disable it. Default is 300.

Serial/SECS-I Connection Properties​

These properties apply only to equipment connections that use the Serial/SECS-I connection type.

Property NameDescription
Serial Port NameThe name of the serial port. Default is COM1.
Data Bit RateThe bit rate of data that is being sent and received. Default is BR_9600.
Possible values are:
  • BR_9600
  • BR_4800
  • BR_2400
  • BR_1200
  • BR_19200
  • BR_150
T1 Inter-Character TimeoutThe maximum number of seconds allowed for interruptions between characters being sent. Default is 0.5.
T2 Protocol TimeoutThe maximum number of seconds for a lack of protocol response. Default is 10.
T4 Inter-Block TimeoutThe maximum number of seconds allowed for interruptions in multi-block messages. Default is 45.
Retry LimitThe maximum number of send retries allowed. Default is 3.

Database Tables​

SECS/GEM creates several database tables to store equipment connection information, message history, and errors. These tables support auditing and diagnostics and are not required for normal module operation.

The tables created for an equipment connection depend on the selected database connection and optional table prefix.

caution

Ignition does not perform automatic maintenance on SECS/GEM database tables. Some tables can grow large over time, so it's recommended that users manage retention, pruning, or partitioning as needed.

SECSGEM_EquipmentInfo​

The SECSGEM_EquipmentInfo table stores summary information for all equipment connections that use the same database connection. This table is created once per database connection and does not use a table prefix.

Each row represents a single equipment connection.

Column NameDatatypeDescription
EquipmentStringThe name of the equipment connection.
PrefixStringThe table prefix used by the equipment connection.
StatusStringThe current status of the equipment connection.
SDL FileStringThe SDL file associated with the equipment connection. If none is uploaded, the default messages.sdl file is used.

Messages​

The Messages table stores SECS messages that are sent or received by an equipment connection. If a table prefix is specified, it is included in the table name. Multiple equipment connections can share the same prefix and write to the same Messages table.

prefixMessages​

Column NameDatatypeDescription
IDAuto-incrementing integerThe unique row identifier.
EquipmentStringThe name of the equipment connection.
StreamFunctionStringThe SECS Stream and Function. For example, S1F1.
DirectionStringIndicates whether the message was sent or received.
RequestResponseStringIndicates whether the message is a request or a response.
CommonIDStringAn identifier used to associate related messages.
TxIDIntegerThe transaction identifier for the message.
ReplyIntegerIndicates whether the message expects a reply.
MessageStringThe SECS message represented as JSON.
TimeSentReceivedDateTimeThe date and time the message was sent or received.

Errors​

The Errors table records errors that occur during SECS/GEM communication. If a table prefix is specified, it is included in the table name. Multiple equipment connections can write to the same Errors table when they share a prefix.

prefixErrors​

Column NameDatatypeDescription
IDAuto-incrementing integerThe unique row identifier.
EquipmentStringThe name of the equipment connection.
StreamFunctionStringThe SECS Stream and Function associated with the error, if applicable.
ErrorTypeStringThe category of error, such as connection, timeout, or validation errors.
ErrorStringThe error message.
TimeDateTimeThe date and time the error occurred.

SECS/GEM Equipment Page​

The SECS/GEM Equipment page displays all configured equipment connections, their current status, and message activity.

AttributeDescription
Active ConnectionsThe total number of active equipment connections.
Errored ConnectionsThe total number of errored equipment connections.
Aggregate ThroughputThe combined message throughput across all connections.
NameThe equipment connection name.
TypeThe type of equipment connections, either Ethernet/HSMS Connection or Serial/SECS-I Connection.
Sent MessagesThe total number of messages sent to the equipment.
Received MessagesThe total number of messages received from the equipment.
StatusThe current connection status. If a connection becomes faulted or disconnected, its status is shown as Not Connected.

SECS/GEM Equipment Details​

Clicking the three dots menu to the right of an equipment connection and selecting View Details will show more detailed information for that particular piece of equipment.

Messages Sent​

AttributeDescription
ThroughputThe messages per second the system is currently sending.
AverageThe average messages sent per second from when the equipment was first enabled.
TotalThe total messages sent.

Messages Received​

AttributeDescription
ThroughputThe messages per second the system is currently receiving.
AverageThe average messages received per second from when the equipment was first enabled.
TotalThe total messages received.