Skip to main content
Glama

call_stack

Read-only

Retrieve the call stack, and optionally local variables, from a halted ARM Cortex-M target to trace execution flow and inspect frame-level state during Keil uVision debugging.

Instructions

Call stack (và biến cục bộ nếu locals=true). Chỉ khi chip đang dừng.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "call_stack"
  }
}

Input Schema

NameRequiredDescriptionDefault
localsNo
max_framesNo

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?

Annotations already declare readOnlyHint=true and destructiveHint=false, so the safety profile is covered. The description adds the meaningful operational constraint that the core must be stopped, but it does not say what happens if it is running (error, empty result?) nor anything about frame truncation when the stack is deeper than max_frames.

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?

Two short clauses, front-loaded with the resource then the state constraint, with zero filler. It is arguably too terse rather than bloated, but no sentence is wasted.

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?

For a simple two-parameter read tool with no output schema this is close to adequate, but the agent still lacks return-shape expectations (frame list format), truncation behavior, and the error behavior when the chip is running, all of which the description could cheaply supply.

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 0%, so the description must compensate; it explains locals clearly (adds local variables to the output) but says nothing about max_frames beyond its self-describing name, and gives no default or truncation semantics. Coverage of one of two parameters is partial.

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?

States a specific resource and operation: retrieves the call stack, optionally including local variables when locals=true. That is clear enough to distinguish it from siblings like read_registers or read_vars, though it never explicitly contrasts itself with rtos_tasks or snapshot.

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

Usage Guidelines4/5

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

Includes an explicit precondition, 'Chỉ khi chip đang dừng' (only when the chip is halted), which tells the agent a when-not condition for invocation. It does not name alternatives or say what to do first (e.g. halt the target) or which sibling covers running-target inspection.

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