Applies To:
  • CitectSCADA 1.00 1.01 1.10 1.11 1.20 2.00 2.01 3.00

Summary:
How do I setup communications with the MODBUS protocol? 

Solution:
The serial drivers PCxI, MCxI, COMxI or COMx may be used.

Setup the PLC with the appropriate communication parameters i.e. baud rate, parity, protocol and station number. e.g 9600 baud, EVEN parity, 8 data bits, 1 stop bits, RTU mode and Modbus Port address 1.

I/O Devices form
Name: User supplied unique name
Number: Network wide I/O device number
Address: PLC unit number starting from 1
Protocol: MODBUS
Port name: Use the "Port name" from the Ports form

Citect.ini option

[MBPLUS]
StringReverse = 0
Do not reverse bytes in words of strings.

MaxBits = 2000 (bits)
Maximum number of bits that can be read in one request.

Pad = 0
Send this number of PadChar at the beginning of each request.

PadChar = 255
Value of PadChar.

Standard citect.ini options

[MODBUS]
MaxPending = 2
Block = 50 bytes
Retry = 2
Delay = 0
TimeOut = 4000 milliseconds
PollTime = 0
WatchTime = 30 seconds

Files

  • MODBUS.DLL - The MODBUS driver for windows
  • MODBUS.DBF - The MODBUS variable template

MODBUS Variables

Digital
00001 Output Coils 1 to 99999
10001 Input status 1 to 99999
Integer/Long/Real/String
30001 Input registers 1 to 99999
40001 Output registers 1 to 99999
 

Keywords:
 

Attachments