site-logo

Lintouch, the opensource HMI

Modbus/TCP Plugin

Author: Lintouch Development Team
Version: 1.8.1
License: GPL2
Download: http://lintouch.org/download/lsp-modbus-1.8.1

Lintouch ModbusTCP Server Plugins lets you connect to ModbusTCP based devices. It can work either in the slave mode (ModbusSlave Plugin) - also known as the server mode - listening for the connections coming from ModbusTCP master devices at the specified port (default TCP 502), or in the master mode (ModbusMaster Plugin) - also known as the client mode - connecting to a remote ModbusTCP slave device. You can learn more about Modbus at http://www.modbus.org.

The ModbusTCP slave supports the following modbus functions:

  • READ_COILS
  • READ_DISCRETE_INPUTS
  • READ_HOLDING_REGISTERS
  • READ_INPUT_REGISTERS
  • WRITE_SINGLE_COIL
  • WRITE_SINGLE_REGISTER
  • WRITE_MULTIPLE_COILS
  • WRITE_MULTIPLE_REGISTERS
  • MASK_WRITE_REGISTER
  • READWRITE_MULTIPLE_REGISTERS

The ModbusTCP master uses the following functions (i.e. the ModbusTCP slave on the other side of the connection should support them for the proper function):

  • READ_COILS
  • READ_DISCRETE_INPUTS
  • READ_HOLDING_REGISTERS
  • READ_INPUT_REGISTERS
  • WRITE_SINGLE_COIL
  • WRITE_SINGLE_REGISTER

The Modbus variables recognized by the plugins are bits and numbers. Each variable has to define the address property. This property uses the following addressing scheme:

  • COn for coils (bits)
  • DIn for discrete inputs (bits)
  • HRn for holding registers (numbers)
  • IRn for input registers (numbers)

where *n* stands for the address of the variable within the modbus slave address space as defined by the Modbus specification: 0-1999 for the bit data types, 0-124 for the number data types. *n* can contain leading and trailing whitespaces.