PLC Integration Guide: OPC UA

Complete step-by-step guide for integrating Acaysia with industrial PLCs via OPC UA.

Overview

Acaysia integrates with industrial PLCs through OPC UA (Open Platform Communications Unified Architecture), the industry standard for secure, vendor-neutral communication. This guide covers the complete integration process, from initial setup to production deployment.

Supported Platforms: Any PLC with OPC UA support, including Allen-Bradley, Siemens, ABB, Schneider Electric, Honeywell, Emerson, and others.

Prerequisites

Hardware Requirements

  • PLC with OPC UA server capability (built-in or via gateway)
  • Ethernet connectivity between Acaysia server and PLC network
  • Network infrastructure supporting required bandwidth

Software Requirements

  • OPC UA server software (typically included with modern PLCs)
  • Acaysia Edge Runtime v2.0+
  • Security certificates for encrypted communication

Network Requirements

  • TCP port 4840 (default OPC UA port) open between Acaysia and OPC server
  • Recommended: Dedicated VLAN for control system communication
  • Static IP addresses for reliable connectivity

OPC UA Setup

OPC UA provides secure, standardized communication between Acaysia and your control system. This is the recommended integration method for most deployments.

Step 1: Configure OPC UA Server

The specific steps vary by vendor, but typically involve:

  1. Enable OPC UA server feature on your PLC or gateway
  2. Configure security certificates (recommended: Basic256Sha256)
  3. Define which tags are exposed to OPC UA clients
  4. Set appropriate read/write permissions

Step 2: Configure Acaysia Connection

# Example Acaysia configuration (acaysia.yaml)
connection:
  type: opc_ua
  endpoint: opc.tcp://192.168.1.100:4840
  security_mode: SignAndEncrypt
  security_policy: Basic256Sha256
  certificate: /etc/acaysia/certs/client.pem
  private_key: /etc/acaysia/certs/client.key

tags:
  - name: reactor_temperature
    node_id: ns=2;s=Reactor1.Temperature.PV
    type: float
    access: read
  - name: reactor_setpoint
    node_id: ns=2;s=Reactor1.Temperature.SP
    type: float
    access: write

Step 3: Security Certificate Exchange

  1. Generate a certificate for the Acaysia client (or use provided certificates)
  2. Import Acaysia's certificate into your OPC UA server's trusted list
  3. Import the OPC UA server's certificate into Acaysia's trusted list
  4. Verify secure connection establishment

Alternative Protocols

While OPC UA is recommended, Acaysia supports additional protocols for specific use cases.

EtherNet/IP

For applications requiring faster update rates or direct tag access:

Parameter Recommended Value Notes
RPI (Requested Packet Interval) 100ms Adjust based on control requirements
Connection Type Class 3 (Connected) Ensures reliable delivery
Timeout Multiplier 4x 400ms timeout at 100ms RPI

Modbus TCP

For legacy systems without OPC UA support:

  • Standard Modbus TCP port: 502
  • Supports function codes 3, 4, 6, and 16
  • Configure register mapping in Acaysia

MQTT

For edge deployments and cloud connectivity:

  • Standard MQTT brokers supported (Mosquitto, HiveMQ, etc.)
  • TLS encryption recommended
  • JSON payload format with configurable topic structure

Tag Mapping

Proper tag mapping ensures Acaysia can read process variables and write control outputs correctly.

Required Tags

Acaysia Variable Typical PLC Tag Data Type Access
Temperature PV Reactor1_TIC_PV REAL Read
Temperature SP Reactor1_TIC_SP REAL Read/Write
Pressure PV Reactor1_PIC_PV REAL Read
Flow Rate PV Reactor1_FIC_PV REAL Read
Control Output Reactor1_CV_Out REAL Write
Mode Select Acaysia_Mode DINT Read/Write
Important: Always implement a hardware interlock that allows operators to disable Acaysia control outputs independently of the software interface.

Testing & Validation

Before enabling closed-loop control, thoroughly validate the integration in shadow mode.

Validation Checklist

  • Verify all process variables read correctly (compare with HMI values)
  • Confirm tag update rates meet requirements
  • Test write operations in manual mode
  • Verify failsafe behavior on communication loss
  • Document network latency and jitter measurements
  • Confirm operator override functionality

Communication Diagnostics

# Check connection status
acaysia-cli connection status

# View tag values in real-time
acaysia-cli tags watch --interval 1s

# Test write operation (use with caution)
acaysia-cli tags write Reactor1_Mode 1 --confirm

Troubleshooting

Common Issues

Connection timeout errors

Check network connectivity with ping and verify firewall rules. Ensure the OPC UA server is running and accepting connections. Verify the endpoint URL is correct and accessible from the Acaysia server.

Certificate errors

Verify that certificates are properly exchanged between Acaysia and the OPC UA server. Check certificate expiration dates. Ensure the security policy matches on both ends. Try temporarily lowering security to diagnose (not recommended for production).

Tag not found errors

Verify node IDs match exactly (case-sensitive for most servers). Check that tags are exposed to OPC UA clients. Use an OPC UA browser tool to verify tag availability. Ensure the namespace index (ns=X) is correct.

Intermittent data quality issues

This often indicates network congestion or electromagnetic interference. Check for duplicate IP addresses, verify cable integrity, and consider using managed switches with QoS for industrial traffic prioritization.

Write operations fail

Confirm write permissions are configured on the OPC UA server. Verify the PLC is in the appropriate mode to accept writes. Check that no other system has exclusive write access to the target tags. Verify the Acaysia mode tag is set correctly.

Ready to Get Started?

Our team can help you plan and execute your Acaysia integration.

Contact Us