agentsclimarketplace

Stm32 hal ll integration

Skill easyzoom/aix-skills/skills/stm32-hal-ll-integration

Use when integrating, configuring, or debugging STM32 HAL, LL, CubeMX generated code, clocks, GPIO, DMA, NVIC, peripheral handles, or Cube firmware examplesFrom its SKILL.md

Install
npx -y skills add easyzoom/aix-skills --skill stm32-hal-ll-integration

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

One thing to look at

  • 24 stars24 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.

SKILL.md

3.1 KB, 643 tokens by cl100k_base, as published. Nobody here has run it

STM32 HAL LL Integration

Overview

Use this skill to debug STM32 projects by separating Cube-generated configuration, clock tree, pin mux, HAL handle state, DMA, and interrupt routing. STM32 bugs often come from generated configuration drift.

When To Use

Use this skill when:

  • The user is working with STM32CubeMX, STM32CubeIDE, HAL, LL, or Cube firmware examples.
  • The issue involves clock configuration, GPIO alternate functions, DMA, interrupts, peripheral init, callbacks, low power, or generated code regions.
  • A peripheral works in polling but fails with DMA/interrupts, or works until Cube regenerates files.

Do not use this skill for non-STM32 MCUs or pure protocol logic. Use the matching protocol or peripheral skill instead.

First Questions

Ask for:

  • STM32 part number, board, Cube package version, IDE/toolchain, and HAL version.
  • .ioc settings, clock tree, pin mux, DMA streams/channels, and NVIC priorities.
  • Peripheral instance, HAL/LL mode, generated init code, callbacks, and logs.
  • Whether user code is inside preserved USER CODE regions.
  • Current symptom, return code, error flags, and register snapshot if available.

Debug Workflow

  1. Freeze Cube configuration. Inspect .ioc, generated init functions, clock tree, pin mux, DMA, and NVIC.

  2. Prove clocks and pins. Confirm peripheral clock enable, GPIO alternate function, speed, pull, and external signal presence.

  3. Check HAL handle state. Inspect handle init, state, error code, MSP init, callbacks, and return codes.

  4. Add interrupt or DMA carefully. Verify IRQ handler names, priorities, DMA request mapping, cache policy, and callback completion.

  5. Compare HAL and LL boundaries. Do not mix direct register/LL changes with HAL state machines unless the ownership is explicit.

  6. Protect generated code. Keep edits in user regions or separate files so Cube regeneration is safe.

Common Failures

  • Peripheral clock or GPIO alternate function is missing.
  • DMA request/channel mapping is valid on another STM32 family, not this one.
  • IRQ handler is not linked or has the wrong name.
  • HAL callback never fires because interrupt enable is missing.
  • Direct register writes break HAL's state machine assumptions.
  • User edits outside preserved regions are lost after Cube regeneration.

Verification

Before claiming STM32 integration works:

  • State part number, Cube package, HAL version, and relevant .ioc settings.
  • Confirm clock, pin, DMA, and NVIC configuration.
  • Confirm HAL return codes, callbacks, and error flags.
  • Confirm behavior survives a Cube regeneration if generated code was touched.

Example

User:

STM32 UART DMA 收不到回调。

Agent:

  1. Checks .ioc, DMA request, NVIC enable, IRQ handler, and MSP init.
  2. Verifies HAL state and error code after starting reception.
  3. Fixes interrupt/DMA routing before changing UART protocol code.

What ships with it

Read from the repository

Just SKILL.md. No reference files, no scripts.

Keep looking

Skills are one crate of 325,949. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.