Skip to main content
Glama
ESP32 DevOps MCP Server
by JosephR26

esp32_component_benchmark

Benchmark ESP32-connected components over I2C, SPI, or UART to measure latency, throughput, polling rate, error rate, and stability; report statistics and separate measured from documented maximums.

Instructions

STAGE 13 (PERFORMANCE CHARACTERISATION). Measures response latency, transaction time, throughput, polling rate, repeated-read consistency, error rate and communication stability for a component. Reports min/max/mean/median/standard deviation and separates the MEASURED maximum (what this setup actually sustained, a floor on the hardware) from the DOCUMENTED maximum (the datasheet figure, unverified). It never claims a hardware limit from a measurement.

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": {
      "component": "<component>"
    },
    "name": "esp32_component_benchmark"
  }
}

Input Schema

NameRequiredDescriptionDefault
csNoChip-select GPIO (SPI, required for SPI)
rxNoRX GPIO (UART)
txNoTX GPIO (UART)
sclNoSCL GPIO (I2C)
sdaNoSDA GPIO (I2C)
baudNoUART baud rate
misoNoMISO GPIO (SPI)
modeNoSPI mode 0-3
mosiNoMOSI GPIO (SPI)
portNoSerial port (optional)
sclkNoSCLK GPIO (SPI)
addressNoI2C address (optional)
clockHzNoSPI clock in Hz
componentYesComponent profile id, part number or alias
interfaceNoInterface to benchmark over (default: I2C)I2C
timeoutMsNoRequest timeout in ms (optional)
benchmarksNoBenchmark ids or names to run (optional — runs all if omitted)
iterationsNoIterations per benchmark, 1-200. Capped at the profile limit for the component.
frequencyHzNoI2C frequency in Hz

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.3.0

TDQS

A3.8/5.0
Behavior4/5

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

With no annotations, the description carries the full load and does well: it discloses that results are statistical (min/max/mean/median/stddev), that measured maxima are a floor rather than a hardware limit, and that documented datasheet figures are unverified. It does not disclose runtime cost, whether repeated polling can disturb the device, or any permission/port preconditions — meaningful gaps for a long-running measurement tool.

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?

Three sentences, front-loaded with the stage label and the metric list, ending with the epistemic caveat that matters most. Nothing is redundant, though the ALL-CAPS emphasis and stage tag consume space without adding agent-relevant information.

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?

There is no output schema, and the description compensates by explaining precisely what the report contains and how to interpret the measured-versus-documented distinction. Combined with 100% schema coverage on all 19 parameters, an agent has enough to select and invoke this correctly; the main omission, expected runtime, is minor.

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

Parameters3/5

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

Schema description coverage is 100%, so every one of the 19 parameters is already documented in structured form, establishing a baseline of 3. The description adds only that the subject is 'a component' and that benchmarks are run against it; it gives no extra guidance on the benchmarks array, iteration budgeting, or interface selection beyond what the schema already says.

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 opens with a specific verb ('Measures') and enumerates the exact metrics produced — latency, transaction time, throughput, polling rate, repeated-read consistency, error rate, stability — for a component. It is clearly distinct from discovery/probe tools, but it never names or contrasts esp32_benchmark, esp32_quick_benchmark, which look like the closest siblings.

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

Usage Guidelines3/5

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

The 'STAGE 13' label implies this belongs late in a workflow after identification/probing, and the emphasis on measured-vs-documented maxima hints it is for characterisation rather than quick checks. However, there is no explicit when-to-use/when-not statement and no routing to esp32_quick_benchmark or esp32_benchmark when a lighter run would suffice.

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