Skip to main content
Glama

esp32_gpio_write

Configure an ESP32 GPIO pin as output, input, or input_pullup and optionally set it high or low to control connected hardware, limited to firmware-allowed pins.

Instructions

Set a GPIO pin mode (output, input, input_pullup) and optionally drive it high or low. Pass value only, mode only, or both. Only pins in the firmware allow list can be changed.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pinYesGPIO number, for example 2.
modeNoPin mode to apply before the value.
valueNoDigital level: 1 high, 0 low.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.6/5.0
Behavior3/5

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

With no annotations, the description carries the full behavioral burden. It discloses the allow-list restriction and that mode is applied before value, but does not explain error behavior when a pin is disallowed, whether changes persist, or hardware side effects of driving a pin.

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?

The description is three tightly scoped sentences with no filler. The core operation, optional parameter combinations, and allow-list constraint are all front-loaded and each sentence earns its place.

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?

The tool is simple and the schema is rich, so most invocation details are covered. Yet as an unannotated hardware mutation, the description lacks important context about failure modes, persistence, and side effects, which keeps it at a minimum-viable level.

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 the schema already documents each parameter. The description adds useful combination semantics by stating that value only, mode only, or both are valid, which goes beyond the individual field descriptions.

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 states a specific verb and resource: setting a GPIO pin mode and optionally driving it high or low. It does not explicitly distinguish this from the sibling esp32_gpio_read, but the write/drive framing makes the purpose clear.

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?

It gives useful usage constraints: you may pass value only, mode only, or both, and only firmware-allow-listed pins can be changed. However, it does not explicitly say when to use this tool versus esp32_gpio_read or other siblings, leaving alternative selection to inference.

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