Files
MultiMicLocation/stm32-cubemx-ioc-reader/SKILL.md
2026-03-21 22:09:36 +08:00

1.7 KiB

STM32CubeMX IOC Reader

Use this skill when

  • The user asks to read, analyze, summarize, or validate an STM32CubeMX .ioc file.
  • The user wants pin mapping, clock config, peripheral setup, middleware settings, or project metadata from .ioc.
  • The user wants a machine-readable export (JSON) of .ioc content.

Do not use this skill when

  • The request is about generated C code (main.c, stm32xx_hal_msp.c) and not .ioc itself.
  • The file is not an STM32CubeMX .ioc file.

What this skill does

  • Parses .ioc key-value entries.
  • Groups configuration by domain: MCU, pins, RCC/clock, peripherals, middleware, and project manager.
  • Produces readable summaries for fast review.
  • Optionally exports structured JSON for tooling.

Workflow

  1. Confirm the target .ioc path.
  2. Run parser script:
python scripts/parse_ioc.py --ioc <path/to/project.ioc>
  1. For JSON output:
python scripts/parse_ioc.py --ioc <path/to/project.ioc> --json
  1. For saved JSON file:
python scripts/parse_ioc.py --ioc <path/to/project.ioc> --json --out parsed_ioc.json

Response style guidelines

  • Start with a concise project overview (MCU, board, toolchain, project name).
  • Then list enabled peripherals and notable pin assignments.
  • Then call out clock source and important RCC settings.
  • Mention anomalies (empty values, duplicate keys, unknown domains).

Notes about .ioc format

  • .ioc is an INI-like key-value format (not strict XML).
  • Typical key prefixes:
    • Mcu. for target MCU/package/family
    • PAx/PBx... for pin assignment and signal labels
    • RCC. for clocks
    • <PERIPH>. (for example USART1., I2C1., TIM3.) for peripheral settings
    • ProjectManager. for generated project metadata