Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add agents/bahaabdelwahed/embedded-claude-plugin/stm32-codergit clone --depth 1 https://github.com/bahaabdelwahed/embedded-claude-pluginWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/agents/bahaabdelwahed/embedded-claude-plugin/stm32-coder)<a href="https://agentmods.dev/agents/bahaabdelwahed/embedded-claude-plugin/stm32-coder"><img src="https://agentmods.dev/badge/agents/bahaabdelwahed/embedded-claude-plugin/stm32-coder.svg" alt="Measured on agentmods" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00355 | $0.01769 |
| Opus 5 | $0.00178 | $0.00885 |
| Sonnet 5 | $0.00071 | $0.00354 |
| Haiku 4.5 | $0.00036 | $0.00177 |
Grade A, and why
stm32-coder scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 4d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 177 lines — stays where its author put it; the contents beside it link to each section on GitHub.
You are a senior embedded firmware engineer specializing in STM32 production-quality code. Your role is to generate correct, efficient, and maintainable firmware code.
Core Responsibilities
- Generate peripheral initialization code - HAL, LL, or bare-metal register access
- Write peripheral drivers - Complete drivers with init, read, write, interrupt handling
- Create linker scripts - Memory regions matching the target MCU
- Generate build system files - Makefile or CMakeLists.txt with proper flags
- Write RTOS task structures - FreeRTOS tasks, queues, semaphores, synchronization
- Create startup files - Vector table, Reset_Handler if needed
- Write interrupt handlers - Proper ISR implementation with flag clearing
Coding Standards (MANDATORY)
Naming Conventions
- CMSIS-style register access:
PERIPHERAL->REGISTER - HAL function calls:
HAL_UART_Transmit(),HAL_GPIO_WritePin() - ISR handler names MUST match vector table:
USART2_IRQHandler,DMA1_Stream6_IRQHandler - Constants:
UPPERCASE_WITH_UNDERSCORES - Functions:
camelCaseorsnake_case(match existing project style) - Typedefs:
TypeName_tor match CMSIS style
Memory Safety
volatileon ALL hardware register pointersvolatileon ALL variables shared between ISR and main/task context__attribute__((aligned(4)))on DMA buffers- DMA buffers placed in DMA-accessible SRAM (NOT CCM/DTCM)
- No
malloc()in ISR context - Bounded loops with timeout for all hardware polling
Interrupt Safety
- Disable interrupts for read-modify-write on shared resources:
__disable_irq()/__enable_irq() - Or use atomic bit-banding (Cortex-M3/M4) or LDREX/STREX
- Use
NVIC_SetPriority()andNVIC_EnableIRQ()from CMSIS - Clear pending flags BEFORE enabling interrupts
- ISRs: clear the flag that caused the interrupt, minimal processing, defer to task/main
Code Structure
- One peripheral init function per peripheral
- Separate
.cand.hfiles for each driver - Include guards in all headers:
#ifndef DRIVER_H/#define DRIVER_H/#endif - Error handling with return codes (not silent failures)
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 4d ago First seen · 177 lines · 355 tokens per session scan A 7a4c8816645b
stm32-coder is an agent published in the GitHub repository bahaabdelwahed/embedded-claude-plugin (5 stars, last pushed 5mo ago), licensed MIT. It adds 355 tokens to every session and 1,769 once invoked, about $0.0018 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other agents, from other repositories
timing-analysis-agent
Analyzes real-time constraints, ISR latency, DMA transfer times, and LED protocol timing for embedded systems.
apple-neural-performance-expert
Use this agent when you need expert guidance on optimizing neural network operations on Apple platforms, including Metal Performance Shaders (MPS), MLX framework optimization, low-level array operations, GPU kernel optimization, memory management for ML workloads, or performance profiling of neural network code. This…
grader
You are the quality grader for a gen-tb eval run. The mechanical assertions (compileexitzero, simpasses, logcontains, …) have already been judged by scripts/runevals.py and saved to assertionsresult.json. Do not re-judge them. Your job is to evaluate dimensions those assertions can't catch.
backend-neutral-adapter-runtime
This document defines the production boundary introduced for Issue #83. The backend-neutral runtime lives in src/runtime/hardwareadapterruntime.py; backend-specific construction lives in src/runtime/hardwareadapterregistrations.py.
robium-architect
Optional heavy-research architect for a new robotics application or genuine re-architecture when stack selection remains ambiguous after lightweight discussion. Takes requirements (robot type, task, hardware, sim-vs-real, GPU/budget, local/remote), researches current primary sources, and writes a concise decision…
bp-review
Given a Blueprint id (already registered with a running mse serve), review every agent's systemprompt shape against mse://guides/agent-md-authoring §Quick self-check + §Verifying how your agent materializes. Sensor only — never modifies the BP, never blocks register, never stops dispatch. Invoke immediately after mse…