PLC Simulator
Modbus function reference

Modbus Function Code 04 — Read Input Registers

Read 16-bit read-only register values

04
Load in Modbus sandbox

Data model

Input registers (3xxxx reference family)

Access

Read 16-bit read-only register values

Protocol quantity

1–125 registers

Worked example

Read the PDU field by field.

Read one input register at protocol address 8. The normal response returns value 10.

Typical use: Polling measured or status values that the server exposes as read-only input registers.

Example protocol data units

Request PDU

04 00 08 00 01

Normal response PDU

04 02 00 0A

PDU examples omit the Modbus TCP MBAP header and the Modbus RTU unit-address/CRC envelope. Multi-byte values are shown in network byte order.

Common implementation mistakes

  • Using function 03 because both objects are 16-bit
  • Attempting to write an input register
  • Ignoring signed, scale and unit metadata

Run the reference

Turn a protocol table into evidence.

Compose the request publicly, then use Pro for advanced graded exceptions, saved fixtures, complete history and project sharing.

Open sandbox

Technical reference and worked-example guide

Modbus function code 04 input-register guide: field reference

Direct answer

The reader can construct and inspect a function 04 transaction, separate protocol offset from documentation notation and validate returned words against a known device state.

Written for pLC programmers and technicians reading measurement or status registers from Modbus servers.

an industrial communications bench used to compare serial and Ethernet evidence, requests, responses, addressing and device state while studying Modbus function 04 requests, input-register addressing and data interpretation
System map / 02

NODE 01observable

Definition

Client, server unit identity, function 04, starting address, quantity, protocol data unit, response byte count, register notation and data type.

NODE 02observable

Signal path

Documented measurement through zero-based protocol offset, request frame, server lookup, returned words, byte or word order, scaling and engineering value.

NODE 03observable

Worked example

A bounded valid request returns the documented number of registers and a value matching a known input condition.

NODE 04observable

Limits

First and last valid address, excessive quantity, illegal address, timeout, exception, stale data, signed value and floating-point word order.

NODE 05observable

Common mistake

A transport, identity, function, offset, quantity, exception, byte-order, data-type, scaling or freshness mismatch.

NODE 06observable

Verification

The request verified with a current map, captured exchange and independent process evidence.

Answer surface / 07

What does Modbus function code 04 do?

It reads one or more input registers from a Modbus server using a starting protocol address and quantity.

Are Modbus 3xxxx labels sent in the request?

No. Documentation labels are conventions; the request carries a zero-based register offset defined by the device map.