CODESYS network variable lists (NVL)
Exchange data with CODESYS-based controllers through network variable lists, without programming a communication protocol on the PLC.
codesys_nvl
Network variable lists are the simplest way to send data out of a CODESYS controller: the PLC broadcasts a list of variables over UDP, and receivers take it over with the same declaration. PLCGateway is such a receiver and can also send a list back to the PLC.
The declaration of the list is pasted into the device form, so the variables appear with their names and types and can be browsed. Large lists are split into telegrams the way CODESYS does it, and a watchdog marks the values as stale when no telegram arrives.
- Driver id
codesys_nvl- Connection
- UDP 1202 · unicast / broadcast / multicast
- Address browsing
- yes
- Writing
- yes
What PLCGateway reads and writes
- BOOL, BYTE to LWORD, SINT to LINT, REAL, LREAL
- TIME, DATE, TIME_OF_DAY, DATE_AND_TIME
- STRING(n) and WSTRING(n)
- One-dimensional arrays
- A send list for values written by PLCGateway
- Unicast, broadcast and multicast; several lists on one port
Address examples
| Address | Meaning |
|---|---|
rTemperature | Variable of the received list |
aValues[3] | Array element |
tx.bStartCmd | Variable of the send list (writable) |
@12 · @0.3 | Raw byte offset / bit |
Controllers and devices
Equipment that is typically connected with this driver.
Connect in a few steps
In CODESYS add a network variable list (sender) with the variables to send; switch off checksum and acknowledgement.
Add a CODESYS NVL device in PLCGateway with the port and list identifier and paste the same declaration.
Browse the variables and add them as tags; optionally declare a send list for values that go back to the PLC.
Use the values in screens, history, alarms and OPC UA.
Questions and answers
Which controllers use CODESYS?
Hundreds of PLC brands are built on CODESYS, for example WAGO PFC, ABB AC500 V3, Schneider Electric Modicon M241/M251/M262, Eaton XC300, Festo CPX-E-CEC and soft PLCs on Raspberry Pi or industrial PCs.
Is NVL better than OPC UA?
NVL is lightweight and needs no server on the PLC, ideal for cyclic process values. If the controller has an OPC UA server and symbolic browsing of the whole application is needed, the OPC UA client is the better choice.
What happens when the PLC stops sending?
After the watchdog time the values get the quality Stale, so screens, alarms and OPC UA clients see that the data is old.
Connect your machines
Tell us which controllers you run; we show you PLCGateway with your own addresses.
Product and model names are trademarks of their owners. They are named only to show which equipment the drivers communicate with; PLCGateway is not affiliated with these companies.