Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

Computer Network 5. Modbus

1,848 views

Published on

Introduction to Modbus.

Published in: Technology
  • Be the first to comment

Computer Network 5. Modbus

  1. 1. Felix Lin
  2. 2. OSI Model Modbus Application Layer Presentation Layer Session Layer Transport Layer Network Layer Data Link Layer Physical Layer Modbus NA NA/Ports NA/TCP NA/IP RS-232/MAC Serial/Ethernet Mapping
  3. 3. • Published by Modicon in 1979 • Modbus is a Protocol, NOT RS232 or RS485 neither • Use for communication between individual equipment • RTU/ASCII • Usually over RS232, RS485 or TCP/IP. • Take TCP 502 port to use
  4. 4. • ADU – Application Data Unit – Maxima size is 256Byte (inherited from RS485) • PDU – Protocol Data Unit – Maxima size is 253Byte (ADU – 1Byte Server Address – 2Byte CRC) • Use big-endian representation
  5. 5. Primary tables Object type Type Discretes Input Single bit RO Coils Single bit RW Input Registers 16- bit word RO Holding Registers 16- bit word RW
  6. 6. • Public – Data Access (Read/Write) • Bit Access • Word Access(16bits) – Diagnostic – Other • User Defined • Reserved for Exception (128~255)
  7. 7. Code Description Type Bit Access 0x01 Read Coils Read 0x02 Read Discrete Inputs Read 0x05 Write Single Coil Write 0x15 Write Multiple Coils Write Word Access (16bits) 0x03 Read Holding Registers Read 0x04 Read Input Register Read 0x06 Write Single Register Write 0x10 Write Multiple Registers Write
  8. 8. Code Name 0x01 ILLEGAL FUNCTION 0x02 ILLEGAL DATA ADDRESS 0x03 ILLEGAL DATA VALUE 0x04 SERVER DEVICE FAILURE 0x05 ACKNOWLEDGE 0x06 SERVER DEVICE BUSY 0x08 MEMORY PARITY ERROR 0x0A GATEWAY PATH UNAVAILABLE 0x0B GATEWAY TARGET DEVICE FAILED TO RESPOND
  9. 9. • http://www.modbus.org/

×