Skip to main content
Glama
h666zhang

vscode-cube-mcp

by h666zhang

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
ST_CUBEMX_EXENoFull path to the STM32CubeMX executable. Defaults to STM32CubeMX in PATH or common Windows installation locations.STM32CubeMX
ST_CUBEMX_TIMEOUTNoTimeout in seconds for the CubeMX subprocess. Default is 240.240
ST_CUBEMX_ALLOWED_ROOTSNoAllowed root directories for .ioc and generated paths, separated by os.pathsep (; on Windows). Defaults to the current working directory..

Instructions

Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.

This server publishes no instructions, or was last inspected before Glama recorded them.

Capabilities

Features and capabilities supported by this server

Protocol revision2025-11-25

CapabilityDetails
tools
{
  "listChanged": false
}
prompts
{
  "listChanged": false
}
resources
{
  "subscribe": false,
  "listChanged": false
}
experimental
{}

Tools

Functions exposed to the LLM to take actions

NameDescription
cubemx_scriptA

执行任意 CubeMX 脚本命令序列(逃生通道,原样传给 -q)。

常用命令示例: config load "C:/path/proj.ioc" set mode USART1 Asynchronous set pin PB13 GPIO_Output set gpio parameters PB13 GPIO_Label=LED config saveas "C:/path/proj.ioc" project generate

cubemx_loadA

加载 .ioc 工程并回读关键配置(只读,不修改任何文件)。

参数: ioc: 工程 .ioc 文件绝对路径(须在允许目录内)

cubemx_configureA

加载 .ioc,依次执行 set 命令,最后 saveas 写回原文件。

参数: ioc: 工程 .ioc 文件绝对路径(会被写回,先备份再调用) commands: 命令列表,如 ["set mode USART1 Asynchronous", "set pin PB13 GPIO_Output"]

cubemx_generateA

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

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

cubemx_export_pinoutA

加载 .ioc 并导出当前引脚配置 CSV(只读,CSV 写系统临时目录后读回)。

参数: ioc: 工程 .ioc 文件绝对路径

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription

No resources

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