Skip to main content
Glama

read_register_with_fields

Read a register and parse its individual fields using SVD metadata and the actual hardware value.

Instructions

Read register and parse fields (combining SVD and actual read) / 读取寄存器并解析字段(结合 SVD 和实际读取).

Args: device_name: Device name / 设备名称 peripheral_name: Peripheral name / 外设名称 register_name: Register name / 寄存器名称

Returns: Register value and field parsing result / 寄存器值和字段解析结果

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_name": "<device_name>",
      "peripheral_name": "<peripheral_name>",
      "register_name": "<register_name>"
    },
    "name": "read_register_with_fields"
  }
}

Input Schema

NameRequiredDescriptionDefault
device_nameYes
register_nameYes
peripheral_nameYes

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.3.0

TDQS

B3/5.0
Behavior3/5

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

No annotations are supplied, so the description carries the full burden. It does disclose a genuinely useful behavioral trait — that the result combines SVD metadata with a live hardware read — but says nothing about prerequisites (connected target, halted CPU), behavior on unknown register names, or side effects of the read.

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

Conciseness4/5

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

The purpose is front-loaded in one sentence and the Args/Returns block is short. The bilingual duplication doubles the length without adding meaning, but the overall shape is efficient and easy to scan.

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

Completeness3/5

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

An output schema exists, so the return explanation is redundant but harmless. For a three-required-parameter hardware read with no annotations and undocumented parameters, the definition leaves out the connection and naming preconditions an agent needs to call it successfully.

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

Parameters2/5

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

Schema description coverage is 0%, so the description must compensate, and it does not: it merely restates the three parameter names in English and Chinese without explaining formats, expected values, or whether names must match SVD entries exactly.

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

Purpose4/5

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

The description gives a specific verb and resource ('Read register and parse fields') and adds a distinguishing mechanism note ('combining SVD and actual read'), which separates it from a pure SVD lookup or a raw value parser. It stops short of naming the sibling alternatives it should be chosen over, so it is clear but not fully differentiated.

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

Usage Guidelines2/5

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

There is no when-to-use guidance at all: nothing says to prefer this over parse_register_value for interpreting an already-read value, or over read_registers for multiple registers. The agent must infer the selection rule from names alone.

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