Colway Solutions
Modbus Member Logo

Overview: Modbus Device Simulator

The Modbus TCP Device Simulator is a Windows console application that can be used as a Modbus TCP device for you to get started with using the Tester. It has the following capabilities:

  • Simulates a Modbus TCP device by listening for connection requests on port 502.
  • Supported on Windows XP and Windows Vista.
  • Supports the following Modbus Function Codes:
  • Read Coils (FC 01)
  • Read Discrete Inputs (FC 02)
  • Read Holding Registers (FC 03)
  • Read Input Registers (FC 04)
  • Write Single Coil (FC 05)
  • Write Single Register (FC 06)
  • Write Multiple Coils (FC 15)
  • Write Multiple Registers (FC 16)
  • Simulates a database consisting of Modbus points of all four types (Coil, Discrete Input, Holding Register, Input Register). The holding registers are further organised so that they can be read in the following formats:
  • Hexadecimal (2-byte value). E.g. 0x8ABC
  • Short Integer (2-byte signed decimal value). E.g. -30020
  • Unsigned Short Integer (2-byte unsigned decimal value). E.g. 35516
  • Integer (4-byte signed decimal value). E.g. -12345678
  • Unsigned Integer (4-byte unsigned decimal value). E.g. 12345678
  • Float (4-byte IEEE 754 single precision real value). E.g. 124.35
  • How to launch the Device Simulator

    You can launch the simulator using one of two ways:

    1. Choose menu item Tools->Start Device Simulator->Modbus TCP from within the Tester
    2. Using Windows Start Menu: Go to Start Menu->All Programs->Modbus Protocol Tester and select Modbus TCP Slave Simulator

    Address map of the Device Simulator

    The device simulator has a virtual internal database as below:
    Address Range Data Type Startup Value
    0 - 15 Coil 0,0,1,1 | 0,0,0,0 | 1,1,1,1 | 0,1,0,1
    0 - 15 Discrete Input 1,1,0,0 | 1,1,1,1 | 0,0,0,0 | 1,0,1,0
    0 - 9 Holding Registers 0x1101, 0x2202, 0x3303, 0x4404, 0x5505
    0x6606, 0x7707, 0x8808, 0x9909, 0xAA0A
    0 - 9 Input Registers 0x2202, 0x4404, 0x6606, 0x8808, 0xAA0A
    0x1101, 0x3303, 0x5505, 0x7707, 0x9909
    20 - 29 Holding Register (Float) 12.34f, 56.78f, 278.94f, 981.23f, 32.97f
    40 - 49 Holding Register
    (4-byte Unsigned Integer)
    12345678, 22114433, 33998877, 22112211, 0x55eeff66
    60 - 63 Holding Register (String) 'COLWAY'

    Related Information

    Topic link How To: Configure Modbus Protocol Tester for Modbus TCP communication
    Topic link How To: Make a connection to your Modbus device
    Topic link How To: Setup Modbus Data Group Forms for Data Acquisition
    Topic link How To: Change values of Modbus variables from Data Group Form
    Privacy Policy Site Map FAQ Contact Us