Skip to main content
Glama
h666zhang

vscode-cube-mcp

by h666zhang

cubemx_generate

Generate HAL code from an STM32CubeMX .ioc file. Optionally set a target directory to avoid overwriting your existing project.

Instructions

加载 .ioc 并执行 project generate 生成 HAL 代码。

参数: ioc: 工程 .ioc 文件绝对路径 project_dir: 生成目标目录;留空则在 .ioc 所在目录生成。 强烈建议指向副本/测试目录,避免覆盖现有工程。

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
iocYes
project_dirNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior4/5

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

With no annotations, the description carries the transparency burden. It warns about overwriting existing projects, a key behavioral side effect, and clarifies the default output destination. However, it doesn't disclose prerequisites, error handling, or whether the .ioc file itself is modified, so it is strong but not exhaustive.

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 compact and front-loaded with the action, followed by a clear parameter list. Every sentence earns its place, including the practical warning about avoiding overwrites, with no redundant or vague text.

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

Completeness4/5

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

For a simple two-parameter tool with an output schema, the description covers purpose, parameters, and the main risk. It lacks explicit comparisons to sibling tools, but the generate operation is self-evident, so the overall guidance is sufficient for an agent to invoke it correctly.

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

Parameters5/5

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

Schema description coverage is 0%, yet the description thoroughly explains both parameters: ioc as an absolute path, and project_dir with its optional behavior and strong recommendation to use a copy. This adds significant meaning beyond the schema's bare property titles.

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?

The description clearly states it loads a .ioc file and executes project generate to produce HAL code, using a specific verb and resource. This distinguishes it from siblings like cubemx_load or cubemx_configure by focusing on the generation step.

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 description implies usage via 'load .ioc and generate HAL code' and provides practical parameter guidance (recommending a copy/test directory), but it does not explicitly discuss when to choose this tool over alternatives or mention any exclusions. Usage context is present but not fully elaborated.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/h666zhang/vscode-cube-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server