Skip to main content
Glama
fieldpuppet

fieldpuppet

Official

Read raw Modbus values

read_registers
Read-onlyIdempotent

Read raw Modbus values from one table to verify byte order, scaling, or addresses before relying on engineering values. Returns table, start address, and values without changing device state.

Instructions

Read raw values straight from one Modbus table of a device, exactly as a client would receive them: 0 or 1 for coil and discrete, unscaled 16-bit words (0-65535) for holding and input. Use it to verify byte order, scaling or addresses; use read_points for engineering values by name. Addresses no point covers read 0, even on strict devices. Changes nothing and is not recorded in the traffic log. Returns the table, start address and list of values.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "device_id": "<device_id>",
      "table": "<table>",
      "address": "<address>",
      "quantity": "<quantity>"
    },
    "name": "read_registers"
  }
}

Input Schema

NameRequiredDescriptionDefault
tableYesModbus table: coil and discrete hold bits, holding and input hold 16-bit registers.
addressYesZero-based address of the first value.
quantityYesHow many consecutive values to read.
device_idYesId of a running device, as returned by create_device, clone_device or list_devices.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed4 schema fields changedv0.1.2
    • addedInput schema / properties / address / description
      Added value: +"Zero-based address of the first value."
    • changedInput schema / properties / device_id / description
      Previous value: -"Device id as returned by create_device or list_devices."New value: +"Id of a running device, as returned by create_device, clone_device or list_devices."
    • addedInput schema / properties / quantity / description
      Added value: +"How many consecutive values to read."
    • addedInput schema / properties / table / description
      Added value: +"Modbus table: coil and discrete hold bits, holding and input hold 16-bit registers."
  2. First observedv0.1.1

TDQS

A4.7/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnly, idempotent and non-destructive, so the safety profile is covered. The description adds genuinely useful context beyond them: requests are not recorded in the traffic log (relevant given get_traffic_log exists), unmapped addresses return 0 rather than erroring, and the return shape is stated. Loses one point only because batching/exception behavior and rate/connection limits are unmentioned.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Information is front-loaded (what you get first, then when to use it, then the sibling alternative, then side effects and return shape). Every sentence carries distinct content with no repetition.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

A read-only tool with four fully documented required parameters and no output schema; the description covers value semantics, the non-logging side effect, the unmapped-address edge case, and the return payload — nothing an agent needs to invoke it correctly is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so baseline is 3; the description goes further by explaining what each table's values actually mean (bits vs unscaled registers), which helps the agent interpret the `table` choice and the resulting values. It does not add much on address/quantity beyond the schema's own bounds.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource (read raw values from one Modbus table) plus the exact value representation per table type (0/1 bits, unscaled 16-bit words 0-65535), which separates it cleanly from read_points' engineering values.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives explicit when-to-use ('verify byte order, scaling or addresses') and names the alternative ('use read_points for engineering values by name') with the condition that selects it. It even covers the edge case where an address has no associated point.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.