Skip to main content
Glama

send_frame

Transmit a single CAN frame on an open device session. Use it for one-off bus messages and call periodic_stop first if a hardware periodic task owns the TX path.

Instructions

Transmit one CAN frame on an open session.

    Requires open_device first. Puts a single frame on the bus; for repeating
    the same frame use periodic_start, for multi-step scripts use run_scenario.
    Fails while a hardware periodic task owns the TX path — call periodic_stop
    first. Returns JSON Result (error.code on failure).
    

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": "<device>",
      "arbitration_id": "<arbitration_id>",
      "data": "<data>"
    },
    "name": "send_frame"
  }
}

Input Schema

NameRequiredDescriptionDefault
dataYesHex payload, e.g. "01 02 03" or "010203" (classic CAN max 8 bytes)
deviceYesDevice alias from config / list_devices
is_extendedNoTrue for 29-bit extended ID; default false (11-bit)
arbitration_idYesCAN arbitration ID (integer, not hex string)

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed4 schema fields changedv0.1.4
    • addedInput schema / properties / arbitration_id / description
      Added value: +"CAN arbitration ID (integer, not hex string)"
    • addedInput schema / properties / data / description
      Added value: +"Hex payload, e.g. \"01 02 03\" or \"010203\" (classic CAN max 8 bytes)"
    • addedInput schema / properties / device / description
      Added value: +"Device alias from config / list_devices"
    • addedInput schema / properties / is_extended / description
      Added value: +"True for 29-bit extended ID; default false (11-bit)"
  2. First observedv0.1.3

TDQS

A4.5/5.0
Behavior4/5

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

The annotations already declare non-read-only, non-idempotent, non-destructive, open-world behavior, so the safety profile is covered. The description adds real value beyond them: a hard prerequisite tool, a specific failure condition tied to periodic tasks, and the failure result shape (JSON Result with error.code). It stops short of describing bus-level failure modes (timeouts, arbitration errors) or whether the frame is echoed, which keeps it at 4 rather than 5.

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 core action is front-loaded in sentence one, followed by the prerequisite, the alternatives, and the blocking condition in descending order of importance. Every sentence carries operational information; nothing is padding despite the multi-line layout.

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?

For a four-parameter transmit tool with an output schema and full annotation coverage, the description supplies everything an agent needs before calling: prerequisite, alternatives, blocking state. Output-schema detail needn't be repeated, and the mention of error.code is a bonus rather than a gap.

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%: the schema already documents the hex payload format, the extended-vs-11-bit flag, the integer arbitration ID, and the device alias. The description adds no parameter-level meaning beyond 'one frame', so the baseline 3 applies.

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 ('Transmit one CAN frame') plus the scoping constraint ('on an open session'). The single-frame scope immediately distinguishes it from periodic_start (repeating) and run_scenario (multi-step scripts), so an agent can pick it without opening any schema.

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?

Explicitly names the prerequisite (open_device first), routes repeating traffic to periodic_start and scripted sequences to run_scenario, and states the when-not case: it fails while a hardware periodic task owns the TX path, so call periodic_stop first. This is exactly the when/when-not/alternatives pattern.

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