Skip to content

Connect to Omron CJ2, CS1, CP1 and NJ/NX controllers (FINS)

eaxScadaHow-to guideStarterProEnterpriseView as Markdown

Migrated page, not yet verified against the current code. Treat values, paths and examples as indicative until this notice is removed.

Read and write the memory of an Omron CJ2, CS1, CP1 or NJ/NX controller from eaxScada over FINS, through the CPU’s Ethernet port or an Ethernet Unit, by memory-area address as the programming software writes it (D100, CIO 0.00, W10.03, E0_100). The protocol id in the configuration is FINS.

Supported controllers, as the Drivers catalogue names them (Omron CJ2M, CJ2H, CS1, CP1E, CP1L, CP1H, NJ/NX (FINS)):

  • CS/CJ series: CS1, CJ1, CJ2M and CJ2H, on the built-in EtherNet/IP port or an Ethernet Unit;
  • CP series: CP1E, CP1L and CP1H, on the built-in Ethernet port or an Ethernet option board;
  • NJ/NX series with FINS enabled on the built-in EtherNet/IP port, reading the memory for CJ-series units (see Set up an NJ/NX).

Over FINS/UDP (the default) or FINS/TCP, port 9600 unless changed.

In the controller’s programming software, on the Ethernet port or Ethernet Unit settings, then transfer them and restart the unit:

  1. IP address of the port. Note it: it is the connection’s Controller IP address.
  2. FINS node number. By default the node is the last number of the IP address (192.168.250.1 is node 1) and the address conversion is automatic (dynamic). Keep that unless your network needs another node: then note the node, it becomes the Controller FINS node.
  3. FINS/UDP port: 9600 by default. For FINS/TCP, enable the FINS/TCP server connections on the unit; the port is 9600 too unless changed.
  4. Static address conversion (an IP address table, or a fixed node table): the controller answers FINS/UDP to port 9600 of the sender, so set eaxScada’s Local UDP port to 9600 (see Networks, units, ports and byte order).
  5. Writes from the network. If eaxScada is to write, the controller must accept FINS writes from it: on a CJ2, turn FINS write protection off, or put eaxScada’s FINS node in the list of nodes allowed to write.

Then open UDP port 9600 (FINS/UDP) or TCP port 9600 (FINS/TCP) between the eaxScada server and the controller, in both directions for UDP.

An NJ/NX controller answers FINS only for the memory it shares with CJ-series units. In its programming software:

  1. On the built-in EtherNet/IP port, enable FINS (FINS/UDP, port 9600).
  2. Turn on the memory used for CJ-series units you need (CIO, WR, HR, DM, EM).
  3. Give each variable you want to read an AT specification in that memory, for example %D100 or %W10.03, and map the address in eaxScada (D100, W10.03).

Variables are not read by name, and NJ/NX controllers have no A, T or C area over FINS: an address in those areas is refused when you save the mapping.

  1. In the Studio, Drivers → Add connection, and in Connects to choose Omron CJ2M, CJ2H, CS1, CP1E, CP1L, CP1H, NJ/NX (FINS).
  2. Fill in the settings:
Field Default Range What to enter
Controller IP address empty required The IP address of the CPU’s Ethernet port or of the Ethernet Unit, for example 192.168.250.1.
Port 9600 1-65535 The port FINS uses on the controller.
Transport FINS/UDP FINS/UDP or FINS/TCP As enabled on the controller.
Controller series CS/CJ (CS1, CJ1, CJ2M, CJ2H) CS/CJ, CP, NJ/NX It decides the memory areas and ranges addresses are checked against, and the largest read.
Controller FINS node (DA1) automatic 1-254 Empty (automatic): the last number of the controller’s IP address over FINS/UDP, the node the controller gives over FINS/TCP.
eaxScada FINS node (SA1) automatic 1-254 Empty (automatic): the last number of the eaxScada server’s IP address over FINS/UDP, the node the controller assigns over FINS/TCP. It must differ from the controller’s node on the same network.
  1. Create connection, then Test connection. The test reads the controller’s model and its mode: a success names the model and version, the node that answered and the mode (PROGRAM, MONITOR or RUN). A node that answers but refuses the model read still proves a controller speaks FINS there; no answer at all says which node was asked, and, over FINS/UDP, to check the IP address, the FINS node and the local port.

A connection whose IP address is empty, whose port, nodes, networks or units are out of range, or whose two nodes are the same is refused before anything is sent.

The Networks, units, ports and byte order section of the form holds settings you rarely change:

Field Default Range Means
Controller network (DNA) 0 0-127 0: the local network.
Controller unit (DA2) 0 0-255 0: the CPU Unit.
eaxScada network (SNA) 0 0-127 0: the local network.
eaxScada unit (SA2) 0 0-255
Local UDP port 0 (any) 0-65535 The UDP port eaxScada sends from. Set 9600 when the controller’s address conversion is static. Not used over FINS/TCP.
32/64-bit word order Low word first (controller default) low first, high first How DINT, UDINT, REAL, LINT and LREAL are split over their words.
String byte order First character in the high byte (controller default) high first, low first How the two characters of each STRING word are stored.

In the connection’s Communication Timing, Request Timeout (2000 ms when unset) is how long a command waits for its response, and Retry Count (0-10) is how many times a read with no response is sent again. A write is never sent again.

In the stored configuration the settings are host, port, transport (udp, tcp), series (CS/CJ, CP, NJ/NX), dest_network, dest_node, dest_unit, src_network, src_node, src_unit, local_port, word_order (low_first, high_first), string_byte_order (high_first, low_first) and simulated.

Addresses are written as in the programming software, in upper or lower case, with a space allowed after the area. A word is a decimal number; a bit is .00 to .15.

Area Word Bit Also written
CIO (core I/O) CIO 100 CIO 0.00 0.00, 100 (a bare number is CIO)
Work W10 W10.03 WR10
Holding H0 H0.15 HR0
Auxiliary A448 A448.00 AR448
Data memory D100 D100.05 DM100
Extended data memory, by bank E0_100 E10_5.03 EM2_100, E0:100 (bank in hexadecimal, 0-18)
Timer T12 (present value) T12 with BOOL: the completion flag TIM12
Counter C3 (present value) C3 with BOOL: the completion flag CNT3
STRING of n words D200[10] - E0_100[20]

The ranges the driver accepts, by controller series:

Area CS/CJ CP NJ/NX
CIO 0-6143 0-6143 0-6143
W 0-511 0-511 0-511
H 0-1535 0-511 0-1535
A 0-1471 0-959 none
D 0-32767 0-32767 0-32767
T, C 0-4095 0-4095 none
EM banks 0-18 (hexadecimal) bank 0 only (CP1H) 0-18 (hexadecimal)

A given CPU can have less memory than its series (a CP1E has far fewer D words than a CJ2H). An address the controller does not have is answered with an address error: that tag is BAD with the controller’s words, and its neighbours are not affected.

The server checks the address and the data type against the connection’s series when the mapping is saved, and the driver checks them again before every read and write. The Studio shows the same errors as you type.

Data type Words Notes
BOOL one bit A bit address (D100.05), or a timer or counter (T12, C3) for its completion flag.
INT, UINT, WORD 1 16-bit signed, unsigned, raw bits. A timer or counter present value takes one of these.
DINT, UDINT (also DWORD), REAL 2 From the address on, low word first unless the connection says high word first.
LINT, LREAL 4 Same word order.
STRING n The length in words is in the address: D200[10] is 10 words, up to 20 characters. 1-500 words.

eaxScada’s own type names are accepted too: Bool, Int16, UInt16, Int32, UInt32, Float32, Int64, Float64, String.

A STRING mapping (D200[10], data type STRING) is read and written as text:

  • Read: the whole string is read in one command. The text ends at the first NUL character. It is shown in the Tag Mappings grid’s value column, in quotes, with the read’s quality and time. A read that fails is BAD; the last text is never shown as GOOD. Screens and the tag engine hold numbers, so a screen does not display the text.
  • Write: printable ASCII only (space to ~), at most 2 characters per word (20 for D200[10]). The text is padded with NUL to the full length and written in one MEMORY AREA WRITE, never split. A longer text or another character is refused before sending.
  • The tag’s write range applies first: Longest text (256 characters when empty) and Only these texts. Set Longest text to the string’s length so the operator sees the limit. See Limit tag writes.
  • A number written to a STRING tag, or text to any other tag, is refused.

Each device of the connection is polled at its own Device Scan Rate (ms) (scan_rate_ms, on the Polling & UNS tab): 250 ms for a connection created in the Studio, 100 ms when the setting is empty. See Scan rates.

Within a poll, neighbouring words of one area (gaps of up to 8 unmapped words) are read with one MEMORY AREA READ, up to the device’s Max Block Read Size and the series’ limit: 999 words on CS/CJ and NJ/NX, 256 on CP. A block the controller refuses for an address is read again tag by tag, so one bad address never makes its neighbours BAD. STRING tags and completion flags are read alone. With block reads off on the device, every tag is read alone. The connection’s delay between requests (inter_request_delay_ms) follows a read that sent a command only, not a tag served from a block already read: 20 words in one block at 100 ms take about 0.1 s, not 2 s.

Every response is matched to its command by its service id (SID) and source; any other frame is dropped and counted. After 3 timeouts in a row the controller is polled once every 5 s until it answers, and its tags say so.

A write goes through the same path as every other write: the server’s write policy and e-signature, the mapping’s read only flag and write range. Then the driver:

  • refuses before sending an invalid address or type, a value the type cannot hold, a BOOL other than 0 or 1, and the read-only memory: A0-A447 and A960 and up (only A448-A959 may be written), and timer and counter completion flags;
  • writes exactly the mapped address in one command: a BOOL with the bit area code, so only that bit changes and the other 15 bits of the word are never read and written back; a 2- or 4-word value or a STRING in one MEMORY AREA WRITE;
  • sends it once. A write succeeds only on the controller’s response to that command. A response with an error end code is a refusal, reported in words (for example read-only area or controller in RUN mode). A write whose response does not come, a lost UDP datagram included, or does not match its SID and source, is reported NOT CONFIRMED: the controller may or may not have applied it. eaxScada never repeats it on its own; check the value and write again yourself if needed.

The connection’s Controller link card (under its settings) and the driver diagnostics show:

Row Means
Connection FINS/UDP or FINS/TCP, address and port, series, eaxScada’s and the controller’s FINS addresses, and the model once read
Commands sent / answered FINS commands sent and responses matched to them
No answer in time commands whose response did not come within the request timeout
Error end codes answered responses with an error end code (address out of range, read-only area, wrong mode…)
Frames dropped (other SID or source) frames that answered no command in flight, or could not be read
Reads sent again reads repeated after no answer
Scan device the device’s scan rate, set and measured; marked when the measured rate is well above the set one

A link error stays shown until the controller answers again, plus a short hold, so the card does not flicker; the previous error is kept below the current one.

  • Browsing: the controller holds no tag names over FINS. Map each address.
  • NJ/NX variables by name: map them to memory for CJ-series units (AT specification) and read that memory.
  • Host Link (serial FINS), CV-series addresses, and routing through other networks beyond the network and node numbers set here.
  • Other memory areas: index registers (IR), data registers (DR) and task flags (TK). Only CIO, W, H, A, D, T, C and EM are read.
  • Showing a STRING’s text on a screen: the text is read into the tag mapping, not into the tag engine (see STRING tags).

A connection with Simulated on ("simulated": true) contacts nothing: an in-process controller holds the values in memory, so you can build screens and mappings before the controller is connected. The FINS simulator tools/fins-sim answers FINS/UDP and FINS/TCP on a test machine.