Schneider Electric LXM32M Modbus services Function Code, Function Code 3 Read Multiple Registers

Page 28

3 Basics

LXM32M

 

 

3.4Modbus services - "Function Code"

The table below provides an overview of the available Modbus serv- ices:

"Function

Meaning under Modbus

Meaning from device per-

Code"

 

spective

 

 

 

3

Read Multiple Registers

Reading a parameter

 

 

 

8

Diagnostics

Diagnostics

 

 

 

16

Write Multiple Registers

Writing a parameter

 

 

 

23

Read/Write Multiple Registers

Reading and writing parame-

 

 

ters

 

 

 

43

Read Device Identification

Subcode14

 

 

 

 

 

90

UMAS File Transfer (Upload)

 

 

 

3.4.1"Function Code" 3 (Read Multiple Registers)

This "Function Code" 3 (Read Multiple Registers) allows you to read several consecutive parameters, starting at any address.

Modbus request Structure of the Modbus request:

Field

Bytes

Value

Meaning

 

 

 

 

Function Code

1

3 = 03h

Read Multiple Registers

 

 

 

 

Starting Address

2

(various)

Address of the first parameter to be read

 

 

 

 

Quantity Of Regis-

2

2 * n

Number of 16 bit values to be read

ters

 

 

(1 parameter has the value 2 since a parameter

 

 

 

consists of a 32 bit value)

 

 

 

 

Modbus response Structure of the positive Modbus response:

Field

Bytes

Value

Meaning

 

 

 

 

 

Function Code

1

3

= 03h

Read Multiple Registers

 

 

 

 

 

Byte Count

1

4

* n

Number of data bytes

 

 

 

 

Registers Value

4 * n

(various)

Parameter values

 

 

 

 

 

Structure of the negative Modbus response

Field

Bytes

Value

Meaning

 

 

 

 

Function Code

1

03h + 80h = 83h

Read Multiple Registers

 

 

 

 

Exception Code

1

01h ... 04h

See chapter

 

 

 

"3.3.2 Modbus response to a Modbus request"

 

 

 

 

0198441113843, V1.01, 01.2012

28

Modbus-TCP module

Image 28
Contents LXM32M Important information Table of contents Diagnostics and troubleshooting Accessories and spare parts LXM32M About this manual Further reading Introduction Fieldbus products on the networkLXM32M Qualification of personnel Before you begin safety informationIntended use Hazard categories Basic information Standards and terminology Basics Modbus TCP technologyFunction principle Bus topologyNetwork service Snmp Client / server modelModbus TCP protocol Structure of a Modbus messageMbap header Field Length DescriptionModbus TCP communication Connection managementModbus response to a Modbus request Excep Name Description Tion CodeReading and writing parameters Address Value4 I/O scanning to Drive Profile Lexium 4.1 I/O scanning Output Byte Meaning Data type Parameter address4.2 I/O scanning Input Bit MeaningBit Signal Factory setting InputsParameter channel Ctrl Subindex Index Function Code 3 Read Multiple Registers Modbus services Function CodeField Bytes Value Meaning Function Code 8 Diagnostics Sub-function Code Diagnostics functionFunction Code 16 Write Multiple Registers Function Code 23 ReadWrite Multiple Registers Function Code 43 Encapsulated Interface Transport Object ID Object name ValueExamples Example of Function CodeLXM32M Installation of the module InstallationDescription Order no Electrical installation Pin Signal MeaningCommissioning Commissioning the deviceFirst Setup Switching on the device Power stage supply is switched offBootp / boot Bootp Manual assignment of the network addressManual / MAnu Manual Dhcp / dhcP DhcpIP address Ethernet module, byte Assignment of the network address via Bootp Assignment of the network address via Dhcp Setting the transmission rate Setting the protocolSetting the gateway Set the IP address of the gateway with the parametersMaster with Word Swap Setting the master for I/O scanning Setting I/O-ScanningActivating I/O scanning Setting the mapping for I/O scanning PLC Setting the web server Setting communication monitoring for I/O scanning0198441113843, V1.01 Operation Indication of the operating state Operating statesBit Name Meaning Changing the operating state Bit Name Meaning Operating stateOperating modes Indicating and monitoring the operating modeBit Name Description Starting and changing an operating mode Bit Name DescriptionOverview of operating modes MODE+ACTIONOperating mode Jog Operating mode Electronic Gear Operating mode Profile Torque 24 hOperating mode Profile Velocity 23 hOperating mode Profile Position Operating mode Homing Operating mode Motion Sequence LXM32M6 OperationExtended settings Web serverMain menu Submenu Content User interfaceAccessing the FTP server FTP serverFDR service Fast Device Replacement LXM32M Diagnostics and troubleshooting Fieldbus communication error diagnosticsStatus LEDs Color Status MeaningColor Meaning for EtherNet/IP Meaning for Modbus TCPError indication Excep Name Description Tion Code LXM32M Accessories and spare parts CablesLXM32M Glossary Units and conversion tablesTemperature RotationTorque Moment of inertiaTerms and Abbreviations LXM32M Index LXM32M