Quick Start

On this page

Connect your first torque controller in about 10 minutes, then use this guide as the reference for connection settings, message revisions, tags, scripting and the supported messages (MIDs).

What the module does

The OpenProtocol module connects Ignition to tightening controllers and fastening systems that implement Open Protocol (Atlas Copco and other makers). Once a controller connection is configured, the module keeps the connection alive, subscribes to the data you choose, and publishes everything it receives as Ignition tags for dashboards, history, alarming and MES integration.

  • No tag configuration. Data appears in the OpenProtocol tag provider, one folder per connection, as soon as the controller sends it.
  • Self-healing connections. Automatic reconnect with back-off, re-subscription, keep-alive and acknowledgements. No scripting is needed to keep data flowing.
  • Revision control. Pick the Open Protocol revision per subscription, or let Auto find the highest one the controller supports.
  • Scripting. The system.openprotocol functions send any supported command: select parameter sets and jobs, enable or disable tools and more.
  • Independent connections. Each controller connection runs on its own threads, so a slow or unreachable controller never delays the others.

Before you start

  • The module is installed and shows Running (Installation chapter).
  • The controller is reachable from the gateway machine: ping <controller-ip> works and the Open Protocol port (default 4545) is open. Test from the gateway, not from your laptop.
  • Only one client can hold an Open Protocol connection to most controllers. Disconnect other Open Protocol clients (tool data systems, MES, test tools) first.
  • Without a licence the module runs 2 connections while the gateway is in trial (Installation chapter, Licensing).

Create your first connection

  1. Open the gateway web interface and go to Connections > OpenProtocol > Connections.

  2. Click Create Connection +. The dialog has three steps; only the first is required, because the defaults in steps 2 and 3 work with every controller.

  3. Step 1, Connection Info: enter a Name, the controller’s IP / Host and the Port (4545). Leave Enabled on so the connection starts when you save. The Description is optional.

  4. Save. The connection status moves from Disconnected to Connected within a few seconds; the connection list shows how many subscriptions are active. Saving an existing connection reconnects it, so new settings take effect.

Connection settings

Setting Default Meaning
Name none Unique connection name. It becomes the connection’s tag folder and the name used in scripts.
Description none Optional free text.
IP / Host none Controller IP address or host name.
Port 4545 TCP port of the controller’s Open Protocol server.
Enabled On Start the connection when it is saved.
Keep Alive (ms) 7000 Interval of the MID 9999 keep-alive sent when the connection is otherwise idle. Also part of the time after which a silent link counts as lost (Keep Alive + Timeout, at least 10 s).
Timeout 5 Seconds to wait for the TCP connect and for each reply before resending.
Retry 3 Connect attempts per round before the connection backs off.
Max Channels 1 Number of spindles or channels to publish (Channel_00, Channel_01, …). Messages for higher channels are ignored.
Acknowledge Mode Auto Auto negotiates with the controller; application acknowledge uses MID 0005/0062-style acks; link-layer acknowledge uses MID 9997/9998 with header sequence numbers. See “Communication behaviour”.
Communication Revision (MID 0001) 1 Revision of the MID 0001 communication start (1 to 6, or Auto). See “Message revisions”.
Allow writes On On: scripts can send the commands that change the controller (listed in “Commands and Allow writes”). Off: those commands are refused and nothing is sent; requests and subscriptions still work.
Subscribe on connect On Master switch. Turn it off to establish subscriptions only from scripts.
Subscriptions Standard set Step 3 of the dialog: one row per subscription family with a Subscribe box and a Revision. Multi-spindle result and User data are off by default. The In use and State columns are read-only: the revision the controller really sends and the subscription state (Active, Pending, Rejected, Off).

Message revisions

Open Protocol messages come in revisions; a higher revision carries more data. For subscriptions, the revision you request decides the layout the controller sends. For example, Last tightening result (MID 0061) revision 3 adds the parameter set name and torque unit, revision 7 the compensated and decimal final angle, revision 8 post-view torque.

  • Revision 1 (default). Works with every controller. New connections start here.
  • A specific revision. Requested exactly as chosen. If the controller rejects it, the subscription shows Rejected and nothing is changed for you. Pick a lower revision or Auto.
  • Auto. Requests the highest revision the module decodes and steps down one revision at a time until the controller accepts. MID 0004 error 74 (“subscribed MID revision unsupported”) and 97 (“MID revision unsupported”) trigger the step-down; any other error leaves the subscription Rejected with the error code shown.
  • 998, multistage. A special Last tightening result layout with stage results instead of the revision 7/8 angle fields. Selectable explicitly; Auto never picks it.

The Communication Revision (MID 0001) selects the revision of the controller’s MID 0002 reply. Revision 6 is the one that tells the module whether the controller supports link-layer acknowledge with sequence numbers; with Acknowledge Mode Auto the module then switches to link-layer acknowledge automatically. Leave it at 1 unless you want that: every controller accepts revision 1.

To choose a revision, check your controller’s Open Protocol documentation for the revisions it implements and pick the highest one that carries the fields you need. Not sure? Choose Auto, save, and read the In use column. A controller may answer a higher request with a lower revision instead of rejecting it; In use always shows the revision actually received, and the data is decoded at that revision.

If a connection set to Auto never connects (some older controllers close the socket or stay silent on a revision they do not know instead of answering “revision unsupported”), set the communication revision to 1. A revision Auto stepped down to is kept until the connection is saved; a controller firmware upgrade is not noticed before that.

Warning: Changing the revision changes which fields carry values. Once a MID has been received, tags for every field of every revision exist. Fields that the revision in use does not send have quality Bad_NotFound. Review bindings and alarms on those tags when you change a revision.

Subscriptions and acknowledgements

Each time a connection starts, the module establishes the enabled subscriptions and acknowledges every pushed data message automatically. After a reconnect, all subscriptions are re-established at the revision they settled on. The families, their MIDs, the revisions the module decodes and whether each is on by default are listed in the reference chapter “Commands” of this guide, as lines named Subscription <family>.

A fixed revision is used exactly as chosen. If the controller does not support it, the subscription shows Rejected (74): revision N unsupported, the gateway log has one WARN line naming the connection and the subscription, and the module does not try another revision. Only Auto steps down.

With link-layer acknowledge (MID 9997/9998 and header sequence numbers), the per-subscription data acks are replaced by MID 9997 as the specification requires; subscribe requests are still answered with MID 0005/0004.

Tags and data

Data is published to the managed tag provider OpenProtocol, one folder per connection. The gateway lists the provider and its tag count under Services > Tags; the tags themselves are in the Designer’s tag browser. Tags are created when the connection starts and filled as messages arrive.

[OpenProtocol]
└── Station12                       <- connection name
    ├── _Status/                    <- the status tags every Innorobix module has
    ├── Diagnostics/                <- connection health
    └── Channel_00/                 <- spindle / channel 1 (Max Channels)
        ├── Info/      ChannelId, StationId, SpindleId, Revision, SequenceNumber
        ├── Status/    LastRxTs, LastTxTs
        └── Messages/
            ├── MID_0061_LastTighteningResult/   Torque, Angle, tightening_status, batch_counter ...
            ├── MID_0071_Alarm/ ...
            └── MID_0035_JobInfo/ ...

Status tags

Each connection folder has a _Status folder with the same status tags every Innorobix module offers:

Tag Meaning
Connected True while the connection to the controller is up.
State Connecting, Connected, Reconnecting, Disabled, Not licensed, Standby or Stopped. Standby is an enabled connection on the backup node of a redundant pair, which does not connect (see the Compatibility chapter, Redundancy). Not licensed is an enabled connection that the licence does not let run (expired, or beyond the number of connections the key allows); Disabled is one you disabled.
LastError The last connection or protocol error.
LastUpdate Time of the last message from the controller.
ReconnectCount How often the connection was lost, including a first connect that failed. Equals Diagnostics/ReconnectCount.
LicenseState The module licence as this connection sees it.
ProtocolErrors Present and always 0.

A connection whose name contains ., /, brackets or other characters Innorobix status tags cannot use, or starts with _, has no _Status folder; rename it if you want one (renaming moves the tag folder, so update your bindings).

Diagnostics tags

The Diagnostics folder holds the connection’s health:

Tag (under <connection>/Diagnostics) Meaning
Connected True while the TCP session is up; false as soon as the module has seen it end (see Communication behaviour).
LastError Last connection or handshake problem; cleared once the controller accepts the handshake.
LastRxTimestamp, LastTxTimestamp Last message received and sent.
ReconnectCount, LastDisconnectReason How often and why the connection dropped.
AckMode, AckModeSwitchCount Acknowledge mode in use and how often Auto switched it.
KeepAlivePolicy Keep-alive policy reported by the controller, when known.
CommunicationRevision MID 0001 revision in use.
Subscriptions/<Family>/Revision Revision the controller is sending for that subscription (empty when not active).
Subscriptions/<Family>/State Active, Pending, Off or Rejected (code), for example Rejected (97): revision 007 unsupported.

Message data

Each channel has a folder Channel_00 (Channel_01 and so on up to Max Channels) with the message data.

  • Every field of every revision of a MID has a tag from the first message of that MID on, so the tag set does not change when you change revision. Fields the revision in use does not send carry quality Bad_NotFound with no value, so you can tell “not sent at this revision” from a real empty value.
  • Values are decoded at the revision the controller actually sent. A controller newer than the module (for example MID 0061 revision 10) is decoded at the highest revision the module knows.
  • MID 0061 parameterset_id (revision 1 name) and parameterset_number (revision 2 and later) always carry the same value.
  • Text fields keep the controller’s space padding; date and time fields are Date tags; list fields (stage results, object data) are JSON text.

Communication behaviour

  • Handshake. On connect the module sends MID 0001 at the Communication Revision and expects MID 0002 (accepted) or MID 0004 (rejected). Any other valid message from the controller is also taken as a live session.
  • Keep-alive. MID 9999 is sent whenever nothing has been sent or received for the Keep Alive interval.
  • Lost connection, detection times. The module checks every connection once a second, whatever the Keep Alive setting.
    • The controller closes the connection, or the socket fails (controller restart, a reset, a failed send): the connection shows as lost within about 1 s (_Status/State leaves Connected and shows Reconnecting; Diagnostics/Connected is false) and the first reconnect attempt follows at the next check.
    • The link goes silent without any error (a pulled cable, a switch that failed): the network reports nothing, so the module judges by what it receives. Once the controller has answered at least one keep-alive in the session, the link counts as lost when nothing at all has been received for the larger of Keep Alive + Timeout and 10 s after a keep-alive was sent. With the defaults (7000 ms, 5 s) that is 12 s, plus up to 1 s for the next check. The keep-alives the module sends itself do not count as traffic.
    • A controller that never answers a keep-alive (the keep-alive is optional on some controllers): there is nothing to judge silence by, so the module keeps the earlier rule: nothing sent or received in either direction for 3 times the Keep Alive interval (at least 5 s), at two checks one Keep Alive interval apart, and the log says once per connection that the controller does not answer keep-alives. A silent cable on such a controller is found much later (or by the operating system after minutes).
  • Alarm for a silent link. [OpenProtocol]<connection>/Diagnostics/LastRxTimestamp is written on every message received. Diagnostics/Connected stays true on a silent link until the module has judged it lost, so do not alarm on that tag alone.
    • Controller that answers keep-alives (the log has no “does not mirror MID 9999” line): the normal gap between two received messages is the keep-alive answer, about one Keep Alive interval. Alarm on this expression, true when the link is silent: secondsBetween({[OpenProtocol]<connection>/Diagnostics/LastRxTimestamp}, now()) > 25, or when the tag’s quality is not good or its value is null. 25 s is safe with the default Keep Alive; raise it if you set Keep Alive above 15 s.
    • Controller that never answers keep-alives (the log says so once per connection): an idle station receives nothing, so there is no traffic to judge by and a LastRxTimestamp alarm would fire on a healthy idle connection. Use a threshold above the longest normal idle time of the station (for example the longest gap between two tightenings plus a margin), or accept that a silent cable is found by the module’s earlier rule or by the operating system.
  • Reconnect. After a drop the module closes the connection, discards everything still waiting to be sent (a command accepted before the drop is never sent after the reconnect; the innorobix.openprotocol.write log says it was not sent), reconnects with back-off (1 s, doubling up to 5 min), repeats the handshake and re-subscribes. The back-off also applies when the controller accepts the connection and then ends the session before it ran stably (for example another client already holds the session, MID 0004); it starts over only after a session that ran for the stabilisation window (at least 5 s, twice the Keep Alive interval). Stopping a connection sends MID 0003.
  • One request at a time. Open Protocol allows one outstanding request per connection; commands are queued and serialised automatically. A request is sent up to 3 times when the controller does not answer, then the connection is re-established.
  • Acknowledge modes. Auto (default) uses link-layer acknowledge when the controller’s MID 0002 reports sequence-number support (needs Communication Revision 6 or Auto), otherwise application acknowledge, and falls back if the controller rejects the chosen mode. Application acknowledge is classic Open Protocol: subscription data is acknowledged with its ack MID (0062, 0072 …) and commands are answered with MID 0005/0004. Link-layer acknowledge gives every message a header sequence number and acknowledges it with MID 9997 (or MID 9998 with an error code such as 0003, invalid sequence number); the specification recommends it for controllers that support it.

Scripting reference

All functions live in system.openprotocol and are available in Gateway, Designer and Vision Client scopes (Client and Designer calls are forwarded to the Gateway). Replies arrive asynchronously: the controller answers with MID 0005 (accepted) or MID 0004 (error), and requested data is published to the connection’s tags.

system.openprotocol.sendMID(device_name, rev_id, station_id, channel_id, mid_number, *parameters)
Argument Meaning
device_name Connection name as configured in the gateway.
rev_id MID revision to send, for example '2'. Empty string means the highest revision the module supports for that MID.
station_id, channel_id Header station and spindle; empty string means 1.
mid_number Four-digit MID as a string, for example '0018'.
parameters Data-field values in the order of the MID’s fields. Fields whose layout has a two-digit parameter ID are preceded by that ID (for example '01', value); the per-MID helpers do this for you.
# Select parameter set 5
system.openprotocol.sendMID0018('Station12', '', '', '', '005')

# Select job 2 (revision 1 layout)
system.openprotocol.sendMID0038Rev1('Station12', '', '', '02')

# Generic form of the parameter-set selection
system.openprotocol.sendMID('Station12', '', '', '', '0018', '005')

# Disable and enable the tool
system.openprotocol.sendMID0042('Station12', '', '', '')
system.openprotocol.sendMID0043('Station12', '', '', '')

Warning: Pass numbers zero-padded to the field width ('005', not '5'). Text shorter than its field is padded with spaces at the start; if your controller expects text padded at the end, pass it at full field width. Values longer than the field are rejected.

Every MID has a helper sendMID<mid> (for some MIDs sendMID<mid>Rev<n>, which has no rev_id). Each takes (device_name, rev_id, station_id, channel_id, ...) followed by the fields of the message. The reference chapter “Commands” lists every MID with its direction, revisions and the helper names. sendMID0140Rev9999 is disabled: it throws an error and sends nothing. sendMID0021 accepts a parameterset_id for compatibility; MID 0021 itself carries no data.

Commands and Allow writes

A script function sends either a request (data, subscribe, unsubscribe, acknowledge) or a command. A command changes the controller: MIDs 0018, 0019, 0020 (parameter set and batch), 0038, 0039, 0127 to 0130 and 0140 (jobs), 0042 to 0047 (tool), 0050, 0150, 0155 to 0157 (identifiers), 0078, 0082 (alarm acknowledge, time), 0110, 0111, 0113 (display and light), 0200, 0224, 0225 (relays and digital inputs), 0270 (reboot), 2503, 2504 and 2606. A MID that is not on this list counts as a command. Starting and stopping the communication session (MID 0001, 0003), data requests, subscriptions and acknowledges are not commands: they are sent with Allow writes off too. MID 2500 and 2501 (tightening program download and upload, also asked for through MID 0006, 0008 or 0009) are never sent.

  • With Allow writes on, the connection sends every command a script gives it.
  • With Allow writes off, a command raises the error “Allow writes is off for connection ‘’; nothing was sent” and nothing goes to the controller. Requests, subscriptions and the module’s own traffic are not affected.
  • Saving the connection applies the setting at once.
  • The call returns when the command is queued. The controller’s answer is not returned to the script; it is logged (see “Troubleshooting and logs”).
  • Allow writes decides whether a script may send a command. It does not decide whether the plant is in a state where the command is safe. Keep interlocks and release decisions in the PLC or MES.

Troubleshooting and logs

The module logs to the gateway log (Status > Diagnostics > Logs, filter openprotocol). In normal operation it writes only a few INFO lines per connection start or stop, nothing per message. WARN is reserved for situations that need attention (a rejected subscription, a controller that stopped answering, an unreachable controller); repeating conditions are logged at most once per 5 minutes and continue at DEBUG.

Every command a script sends is logged by the logger innorobix.openprotocol.write (the Ignition user is not logged): an INFO line with the connection, MID, revision and parameters when it is queued, an INFO line when the controller accepts it (with the attempt that was answered), and a WARN line when the controller rejects it (with the MID 0004 error code and its text), when it gets no answer within the connection’s Timeout and is sent again (up to 3 attempts in all: a controller that executed the command but answered late can execute it again), when the last attempt gets no answer (the controller may or may not have executed it), or when Allow writes refused it. The refusal is logged once per connection and MID every 5 minutes, then at DEBUG. The password of MID 2503 is never logged.

Level Use it for
INFO (default) Connection start and stop, connects and disconnects, and every command sent.
DEBUG Subscriptions and revision negotiation, retries, reconnect details. The Channel logger logs every message sent to and received from a controller.
TRACE Field-level decoding detail.
Symptom What to check
Stuck in Disconnected or Connecting IP address and port; controller powered and reachable (ping); firewall. Diagnostics/LastError shows the reason.
Connects, then drops repeatedly Another Open Protocol client holds the controller (most accept one). Check Diagnostics/LastDisconnectReason.
“Handshake rejected (0004/97)” The controller does not support the Communication Revision; choose 1 or Auto.
Subscription shows Rejected (97) or (74) The controller does not support that revision; choose a lower revision or Auto.
No result tags updating Is the connection Connected and the subscription Active? Perform a tightening: results arrive on completion.
Some tags have quality Bad_NotFound That field is not part of the revision in use; choose a higher revision if the controller supports it.
A command raises “Allow writes is off” Turn on Allow writes in the connection settings (step 2).
A command has no effect Read the command lines in the log (below): a MID 0004 answer shows the controller’s error code and text. Check the revision and value formatting against the controller documentation.
Connection shows Not licensed The gateway is in trial mode or the licence has ended. See Installation and licensing.

Send us a message through the contact form (topic: A module) with a description or screenshot of the symptom, a screenshot of the connection settings (all three steps), the relevant tags including Diagnostics, and the gateway logs, ideally with the Channel logger at DEBUG while the problem occurs.

Known limitations

  • MID 2601 (Mode ID upload reply) and MID 2603 (Mode data upload reply) are decoded in the R2.8 layout; the R2.10 layout with per-record name lengths is not supported.
  • MID 0061 revision 999 (“Light”) is not supported and is not offered for selection.
  • The module does not define these spec revisions: 0001/0002 rev 7, 0012 rev 2 to 4, 0013 rev 3 and 4, 0033 rev 4, 0040 rev 6 and 7, 0041 rev 6 and 7, 0042/0043 rev 2, 0045 rev 2, 0065 rev 8, 0071 rev 3, 0074 rev 2, 0076 rev 3, 0140 rev 2, 0214 rev 2. Received messages at a higher revision are decoded at the highest revision the module knows.
  • Revision 2 of MID 0071 includes the alarm text field defined in R2.8; R2.10 controllers send it at revision 3, which is not supported.

Operator interface and maintenance

Innorobix provides an optional Perspective project for rapid deployment of monitoring and control screens: devices grouped by line and process, connection status in the header, and data panels for tightening results, job information and other subscribed data. Contact Innorobix for the Traceability Package.

To update the module, obtain the latest version and release notes from Innorobix, install and test it on a development gateway first, then upgrade production through Install or Upgrade a Module. Settings and connections are preserved. The module does not update automatically; module versions must increase for Ignition to accept an upgrade.

Typical next steps: store each tightening result row in SQL with a transaction group or a gateway script (traceability), put an Ignition alarm on the tightening status tag (failed-torque alerts), and bind Perspective views to the result tags (dashboards).

Generated from the module's documentation for version 8.11.0. Questions: contact us.