Skip to main content
Glama

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
MXMCP_WORKSPACENoProject state directory.~/.mxmcp
MXMCP_CUBEMX_ROOTNoCubeMX installation directory. If CubeMX is not installed, standalone mode is used instead.C:\Program Files\STMicroelectronics\STM32Cube\STM32CubeMX
MXMCP_MAX_ENGINESNoMaximum number of simultaneously resident JVMs (one per open project).3

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
}
resources
{
  "subscribe": false,
  "listChanged": false
}

Tools

Functions exposed to the LLM to take actions

NameDescription
project_listA

List CubeMX projects known to this server (id, MCU, toolchain, whether a warm engine is attached and whether a saved .ioc exists).

project_getA

Describe one project: MCU, toolchain, saved .ioc path and (optionally) the full IOC summary (active IPs, pin count, ProjectManager settings).

project_createA

Create a CubeMX project. Give exactly one of mcu (part number or db RefName, e.g. STM32F103C8T6), board (e.g. NUCLEO-F030R8) or ioc (existing .ioc to clone). Optionally set toolchain and output_dir. The project is immediately saved as /projects//project.ioc.

project_openA

Attach a warm CubeMX engine to a known project and reload its .ioc (or a different .ioc). Needed after a server restart; other tools open lazily too.

project_closeA

Close the warm engine of a project (frees a JVM; saved .ioc is untouched).

project_saveB

Snapshot the live engine configuration into the project .ioc (config saveas + saveext, so default-valued parameters are persisted too).

project_save_asA

Duplicate a project's saved .ioc into a new project id and open it.

project_deleteC

Forget a project; optionally delete its workspace files.

project_diffB

Structural diff between a project's .ioc and another project or .ioc file (added/removed/changed keys).

project_load_mcuA

Re-target an existing project to another MCU (CubeMX keeps compatible pins/peripherals where possible, same as the GUI load <mcu>).

project_load_boardA

Load a board configuration into a project (default peripherals with allmodes, or bare pinout with nomode).

project_export_scriptB

Serialize the current configuration into a replayable CubeMX CLI script (export script). This is the exact command list that recreates the project.

project_import_configA

Import another .ioc into the live project (import config), then re-save.

catalog_indexA

Counts for the local CubeMX database: MCUs per family, boards, IP mode files, config files and FreeMarker templates. Use before searching.

mcu_searchA

Search MCUs by part number or RefName (STM32F103C8T6, STM32F103C(8-B)Tx) or by prefix (STM32G4). Returns flash/RAM/core/package and the exact RefName to pass to load.

mcu_infoA

Full record for one MCU from db/mcu/.xml: attributes, memory, and every IP instance with its CubeMX IP version and config file.

family_listA

List STM32 families present in the database with MCU counts.

family_mcusA

List the MCUs of one family (e.g. STM32H7) with memory/package metadata.

board_searchB

Search ST boards (NUCLEO/DISCO/EVAL) by name fragment.

board_listA

List every board known to the board manager (name, mcu, vendor, source pdsc).

ip_libraryA

List the IP mode-definition files under db/mcu/IP (e.g. ADC-STM32F4xx_Cube_Modes.xml). Filter by family or name fragment.

template_listB

List the FreeMarker code templates shipped in db/templates (used by the generator; also the source for user-template override).

mcu_pin_functionsB

Alternate-function table for an MCU read straight from the MCU XML (no engine). Optional pin substring filter. Use get functions/ set pin via the engine for live availability.

firmware_packagesA

List installed STM32Cube firmware packages in the local repository (these are what project generate copies Drivers from).

pinout_getA

Read the live pinout (get pinout): every pin with its current signal. Filter with only_configured to drop Reset_State/Power pins.

pin_functionsB

List every selectable function of a pin (get functions <pin>), e.g. PA9 -> TIM1_CH2, USART1_TX, GPIO_Output ...

pin_setA

Assign a peripheral signal to a pin (set pin <pin> <signal>). Signals must exist in pin_functions; GPIO_Input/GPIO_Output/GPIO_Analog/GPIO_EXTIn are always valid for GPIO pins.

pin_resetA

Free one pin (exact name) or every pin matching a regex (reset pin). Use after pin_set to undo a misassignment.

pin_clear_allA

Remove every pin mapping (clearpinout), then optionally re-save the .ioc.

pin_lockA

Lock or unlock a pin so generation keeps (or may change) its mapping (lock pin <pin> <locked>).

pin_reserveA

Reserve a pin (marks it used without assigning a peripheral) via set pinreservation.

mode_listB

Peripheral modes: available (what the MCU can do), all (every leaf mode) or mapped (what is currently enabled).

mode_catalogA

Offline catalogue of every IP mode in the shipped database (274 IPs: peripheral/service/middleware/LPBAM), with per-version mode lists, parameter counts and the IP type. Works without starting the engine.

mode_setB

Enable a peripheral mode (set mode <IP> <mode>), e.g. USART1 Asynchronous, RCC Crystal/Ceramic Resonator, TIM3 PWM Generation CH1.

mode_resetC

Disable one mode of a peripheral (reset mode).

mode_checkB

Ask CubeMX whether a mode is currently enabled (check mode enabled).

sub_modesB

Raw sub-mode state dump for one peripheral (get sub-modes), useful for compound modes such as SYS/NVIC.

peripheral_listB

Every IP instance the loaded MCU provides, with its CubeMX IP version (get mcu peripherals).

ip_param_getB

Read one IP parameter (get ip parameters <ip> <param>).

ip_param_setA

Set an IP parameter (set ip parameters <ip> <param> <value>). Also registers the name in <IP>.IPParameters so the value is persisted by project_save (CubeMX only writes listed parameters).

ip_params_setC

Set several IP parameters at once and register them all in IPParameters.

ip_params_dumpA

Dump every persisted parameter of the selected IPs from the saved .ioc (the authoritative view after project_save).

ip_user_nameA

Rename an IP instance (set username <ip> <name>), which changes the MX_/HAL_ symbol prefix in generated code.

gpio_paramsA

GPIO parameters for one pin or all pins, read from the saved .ioc (GPIOParameters list, label, mode, lock state).

gpio_setB

Set a GPIO parameter (GPIO_Label, GPIO_Mode, GPIO_PuPd, GPIO_Speed, GPIO_OutputLevel...). Uses the engine when the CLI branch accepts it and otherwise edits the .ioc and reloads it, which produces the same file the GUI writes.

clock_getB

Clock tree state: derived frequencies (HCLK/SYSCLK/PCLK/...) and the RCC settings that produce them, read from the saved .ioc plus live reads.

clock_setB

Program the clock tree. Accepts explicit RCC parameters or the friendly keys: sysclk_hz, pll_mul, pll_source, sysclk_source, ahb_div, apb1_div, apb2_div, hse_mhz, hsi_mhz, lse_khz, lsi_khz. Runs clock resolution so CubeMX re-solves the tree, then saves and returns the derived frequencies.

clock_resolveC

Run CubeMX's clock issue resolver (clock resolution) and re-save.

clock_param_possible_valuesB

Query the allowed values of one RCC parameter (get mode_param_possvalue).

project_optionsC

Read the ProjectManager section of the saved .ioc (toolchain, FW package, heap/stack, file layout, user-code guards...).

project_set_optionC

Set project manager options: name, path, toolchain (STM32CubeIDE/EWARM/MDK-ARM/Makefile/CMake), compiler (GCC/Starm-Clang), toolchain_location, couple_files_by_ip, generate_under_root, custom_fw_path, stack_size, heap_size, structure (Advanced/Basic), copy_library (copy all/copy only/copy as reference).

project_generateB

Generate the complete project (CubeMX code + firmware drivers + IDE project files) for a toolchain, exactly like project generate. CubeMX may need a my.st.com login to download a missing firmware package; this is reported in warnings with status KO.

generate_codeA

Generate only the CubeMX application code into a directory (generate code <dir>, no drivers/IDE files). mode may force the all-in-main or one-file-per-IP layout first.

project_csvA

Export the current pin configuration to CSV (csv pinout <file>), the same file the GUI passes to board layout tools.

project_reportA

Produce a human readable report of the configuration (MCU, active IPs, pin map, clock settings, project settings) from the saved .ioc.

project_filesC

List generated files under the project output directory (glob filter).

pack_statusA

Enumerate every software pack/component visible to the project as structured JSON (pack status <file>): pack ids, component ids, selected flags and dependency status. Filter with query.

pack_enableB

Enable a CMSIS-Pack component (pack enable <vendor> <pack> <version> <class> <group> [variant] [-resolve]) and run pack validate.

pack_disableC

Disable a CMSIS-Pack component and validate the selection.

pack_validateB

Apply every component enabled since the last validate (pack validate) and persist the .ioc.

swmgrB

Software manager: refresh the package catalogue, install/remove a STM32Cube firmware package or CMSIS-Pack, change the repository path or proxy, check connectivity.

xcubedlC

Download an X-CUBE pack by name (xcubedl <packname>).

loginA

Log in to my.st.com for firmware/pack downloads (login <email> <password> <remember y|n>).

logoutB

End the my.st.com session (logout).

cliC

Run any CubeMX CLI command verbatim in the project engine and return its output (OK/KO plus payload). Covers the entire command language: get/set/reset/lock/check/csv/generate/project/config/pinout/switch/unset/export/import/NVIC/dma/pack/swmgr/clock/... Optionally save afterwards.

cli_batchB

Run several CLI commands in order (stops at the first KO unless continue_on_error). Ideal for replaying project_export_script output.

cli_helpB

Per-family usage tables straight from the engine (running the bare command prints its sub-command list).

ioc_getA

Read raw keys from the saved .ioc: one key, or all keys with an optional prefix (e.g. 'RCC.' or 'PA9.').

ioc_setA

Write raw keys into the saved .ioc and reload it into the engine. Used for values the CLI cannot address (GPIO parameters, custom constants).

ioc_deleteB

Delete one key from the saved .ioc and reload it.

ioc_exportB

Copy the project .ioc to an arbitrary path (shareable artifact).

ioc_importA

Import an external .ioc as a new project (loads it and normalises it through a save).

verifyA

Cross-check live engine state against the saved .ioc: MCU, every pin signal, active IP modes, plus an optional generation run. Returns a problem list (empty = consistent).

dma_queryC

Inspect the DMA request/stream map of the project (CubeMX dma ... service): list_all, list, list_briefly, list_periph, list_controller, available_streams, available_periph_requests, available_controller_requests, used_flows, delete_all.

dma_mutateB

Change DMA assignment: add/delete a request, set its flow, or set one DMA parameter (Priority/Mode/... exactly as CubeMX names them).

mdma_queryC

Inspect MDMA (dual-port DMA, H7/U5/N6...) requests and channels via the CubeMX mdma ... service.

mdma_mutateC

Change MDMA assignments/parameters (add_request, add_channel_request, delete_request, delete_channel, set_param).

gic_queryB

Read the GIC interrupt controller (STM32MP1/MP2) through CubeMX: interrupt list, per-IP interrupts, enable state and triggering mode.

gic_mutateC

Change GIC interrupt routing (enable/disable, enable state, triggering mode, priority, security).

nvic_readB

Read NVIC state: enabled interrupts, an IP's interrupts, the priority group, and per-IRQ priority / subpriority / handler-generated / enable state / group / preempt source.

nvic_writeC

Change NVIC: enable/disable an interrupt, set priority/subpriority/group/preempt source/handler-generated flag, or the priority group.

mmtB

Drive the Memory Mapping Tool (H7RS/U5/N6 TrustZone-style memory map): dump free/AppReg/HRange/HRegion, reserve SW/HW regions, reset reserved, load/save pre-config files, enable ThreadX layout.

lpbamC

Manage LPBAM / multi-context projects (the GUI's Low Power Banana workflow): list, add, delete, rename, select a configuration or the active MX project.

portingC

Port a configuration onto another MCU / manage the import engine: try_auto (import another .ioc into the current MCU), try/try_and_log, report, compatibility rules, import options and logs, and the MCUs-DB hack mode used to patch database entries.

selectorsC

Use CubeMX's headless selector tables: enumerate/inspect the MCU finder columns and filters, the board-manager peripheral tables, and the example (X-CUBE) library selections.

ioc_compareB

Compare two .ioc files with CubeMX's own differ (cpload project1/2 + cpexport) and return the report text.

value_checkA

Ask CubeMX whether a parameter value is legal for an IP right now (possible_value ip parameters / not_a_possible_value ip parameters) — this evaluates the XML condition expressions (IP dependencies, semaphores, die variants) instead of guessing.

mode_patternC

Get the value pattern CubeMX expects for a mode parameter (get mode_param_pattern <ip> <mode> <parameter>).

submode_stateA

Inspect a mode-tree branch: sub-mode enable state and available sub-modes (get sub-mode-state / get sub-modes), the same data the peripheral diagram uses.

ide_bridgeB

Service hooks around the main window: simulate the CubeIDE open action, query a plugin's error state, refresh an IP's UI, toggle the tooltip log, toggle user analytics, and read the code-generator mode / IP dependencies / BSP status / MCU peripherals.

complianceB

Run CubeMX's own consistency checks: xts/xtest suites, check mcu modes (mode availability for the current pin map), the all-MCU mode and XML audits, a single mode check, and the pinout keep-placement check.

runtime_propsB

Read or write the JVM system properties / environment of the running CubeMX engine and change its log level at runtime.

product_dbB

Query the parametric MCU-finder database (the data behind the product selector: attributes, CPN/RPN commercial names, resources, features) read-only. CubeMX downloads it to ~/.stmcufinder; use swmgr / the GUI database refresh to obtain it.

command_catalogA

The extracted CLI registry: every command string CubeMX registers, which jar/class registers it, its arity and its help text. Use it to discover what cli can run; command=<name> returns the exact usage.

rtos_schemaB

The RTOS user-object schema CubeMX ships (tasks/queues/timers/semaphores/mutexes/events per CMSIS RTOS v1 & v2), including every field, its default, allowed values, the JS enabled-condition, and how the objects are stored in the .ioc.

rtos_statusB

Read the project's RTOS state: active mode, the .ioc prefix, every stored object per type, the FreeRTOS config scalars, and whether the RTOS row is present.

rtos_objectsB

List the RTOS objects stored in the project with their fields decoded according to the shipped schema (field order from rtos_apis.xml).

rtos_object_writeA

Add / update / delete an RTOS object (task, queue, timer, semaphore, mutex, event) with schema validation and the GUI's unique-name rule, then let CubeMX reload and re-save the project so the .ioc is canonical.

rtos_configB

Read or set FreeRTOS configuration scalars (configUSE_TIMERS, configTOTAL_HEAP_SIZE, configMAX_PRIORITIES…), registering each key in IPParameters exactly like the GUI does.

middleware_listB

Every middleware instance CubeMX can integrate (from MiddleWareConstants), the template hooks each one generates, which are active in the project, and how to enable or register a custom one.

middleware_addB

Integrate a middleware instance (set mode <name> <mode>) or register a custom X-CUBE middleware (add mw with root/mode/config/template paths).

standalone_infoA

Report whether the standalone (no-installation) path is active, what the bundled data pack contains, and which capabilities are available offline.

standalone_createB

Create a project for an MCU using only the bundled database (marketing part numbers are resolved to the db reference name).

standalone_openC

Load a .ioc into the standalone engine (no CubeMX needed).

standalone_pinA

Bind (or reset) a pin signal with real validation against the MCU pinout: only signals the pin advertises are accepted, GPIO_* variants are expanded from the db IOModes, and a signal can only be bound once.

standalone_signalsB

List the signals a pin can carry (offline, from the bundled MCU xml) and what it is bound to now.

standalone_modeC

Enable a peripheral/middleware mode, validated against the IP's mode list from db/mcu/IP/*_Modes.xml.

standalone_paramB

Set an IP parameter and register it in .IPParameters (the same persistence rule CubeMX uses).

standalone_nvicB

Configure an interrupt in the standalone project (priority, subpriority, enabled state) and persist it in the NVIC. line.

standalone_viewB

Full standalone project state (MCU, pins, IP parameters, NVIC, options, validation problems) plus the .ioc text.

standalone_validateA

Validate the standalone project: pin/signal legality, duplicate signal bindings, and IPs that do not exist on the MCU.

standalone_generateB

Generate a C project (main.c/main.h/MSP/IRQ/Makefile) entirely offline from the bundled HAL config model — no CubeMX installation involved.

standalone_mcuA

Search the bundled MCU database, or dump one device's pins and IPs (works with no CubeMX installation).

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription
READMEServer overview and tool list
CLI referenceComplete CubeMX command language notes

TDQS

C2.9/5.0

Scored across 113 tools

Disambiguation2/5

The set has many overlapping paths to the same outcome: `cli` can perform nearly every other operation, while `standalone_*` tools mirror the main project/pin/mode/parameter workflow. Additional overlaps exist between `project_diff` and `ioc_compare`, `verify` and `compliance`, `project_create` and `standalone_create`, and different search/list tools for MCUs, boards, and signals.

Naming Consistency3/5

Most tools use lower snake_case and many share a clear domain prefix such as `project_`, `pin_`, `mode_`, `clock_`, and `standalone_`. However, action ordering and granularity vary between noun_verb, verb_noun, bare abbreviations, and noun-only names (`generate_code`, `project_generate`, `swmgr`, `login`, `rtos_status`, `middleware_add`).

Tool Count1/5

113 tools is far beyond an appropriate MCP surface for a single server, even for a complex CubeMX automation domain. The duplicate standalone path, generic CLI escape hatches, and many specialized query/mutate pairs make the set unwieldy for agent tool selection.

Completeness5/5

The surface covers project lifecycle, MCU/board discovery, pinout, modes, IP parameters, clocks, generation, packs, software packages, authentication, DMA/MDMA/GIC/NVIC, RTOS, middleware, standalone operation, and verification. There are no obvious major lifecycle or CRUD gaps for CubeMX configuration and generation.

Maintenance

ActivityMaintained
ResponsivenessNo recent community issues