Skip to main content
skill Claude Code CX Codex Cursor GitHub Copilot

embedded-systems — Claude Code skill: what it does, how to install

Configure your coding assistant for microcontroller firmware, bare-metal C, and FreeRTOS applications. It helps structure drivers, ISRs, and low-power routines under tight memory limits.

Install into Claude Code · Skills CLI (Vercel) All methods and platforms ↓
npx skills add Jeffallan/claude-skills --skill embedded-systems -a claude-code
Open on GitHub

What embedded-systems does

The skill guides your coding assistant through a 6-step embedded engineering workflow: constraint analysis, task architecture, driver implementation, code validation, resource optimization, and timing verification. It targets microcontrollers like STM32 and ESP32. Code generation adheres to clean compilation with -Wall -Werror and static checks like cppcheck.

Prebuilt templates cover ARM Cortex-M bare-metal registers and FreeRTOS tasks. The skill insists on keeping interrupt service routines minimal. Hardware flags and shared buffers must use volatile. Blocking operations inside ISRs and unbounded dynamic memory allocation are explicitly forbidden.

Every implementation output includes hardware clock initialization, peripheral drivers, application tasks, and a resource summary for Flash, RAM, and power. Stack health is verified using uxTaskGetStackHighWaterMark(). The enforced structure prevents silent timing jitter before hardware testing begins.

What it helps with

  • write peripheral drivers and interrupt handlers for STM32 microcontrollers
  • create periodic FreeRTOS tasks with queue synchronization
  • implement DMA transfers and communication protocols like SPI, I2C, and UART
  • reduce firmware power consumption with hardware sleep modes

Example prompts for the agent

  • Write a bare-metal UART driver for STM32F4 using RX interrupts and a circular buffer
  • Create a periodic FreeRTOS task reading an ADC channel with stack headroom checks
  • Configure a hardware timer interrupt to toggle a GPIO pin at 1 Hz on STM32

How to install embedded-systems

1Skills CLI (Vercel)

npx skills add Jeffallan/claude-skills --skill embedded-systems -a claude-code

2Manually: put the files in place

~/.claude/skills/embedded-systems/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/embedded-systems/

From the same set61

The whole set →
laravel-specialist https://github.com/Jeffallan Configures the agent for Laravel 10+ and PHP 8.2+ development. It guides Eloquent modeling, Horizon queues, API resources, and Pest testing. Claude Code CX Codex Cursor +1 23,300installs golang-pro https://github.com/Jeffallan A Go skill for concurrent code, microservices, performance profiling, and idiomatic interfaces. Use it for goroutines, gRPC, benchmarks, and table-driven tests. Claude Code CX Codex Cursor +1 18,900installs php-pro https://github.com/Jeffallan Enforces PHP 8.3+ standards across Laravel and Symfony projects with strict typing, PHPStan level 9 checks, and automated Pest tests. Claude Code CX Codex Cursor +1 15,500installs flutter-expert https://github.com/Jeffallan Skill for building cross-platform apps with Flutter 3+ and Dart. Covers widgets, state management via Riverpod or Bloc, GoRouter navigation, and performance optimization. Claude Code CX Codex Cursor +1 14,300installs typescript-pro https://github.com/Jeffallan Implements advanced TypeScript type systems, branded types, and tRPC configurations. Use it when building type-first APIs or complex discriminated unions. Claude Code CX Codex Cursor +1 14,200installs kubernetes-specialist https://github.com/Jeffallan This skill helps create and validate Kubernetes manifests, set workload security, and troubleshoot failing pods. Use it for deployment and cluster operations. Claude Code CX Codex Cursor +1 14,100installs devops-engineer https://github.com/Jeffallan This skill creates Dockerfiles, CI/CD configs, Kubernetes manifests, and IaC templates. Use it for deployments, platform work, and incident response. Claude Code CX Codex Cursor +1 11,200installs wordpress-pro https://github.com/Jeffallan This skill builds WordPress themes, plugins, Gutenberg blocks, and WooCommerce features. Use it for REST API work, hooks, security checks, and performance tuning. Claude Code CX Codex Cursor +1 9,700installs

Similar

code-quality tursodatabase Correctness rules, Rust patterns, and anti-over-engineering guidance for coding agents working in your repo. Claude Code CX Codex Cursor +1 1,800installs python-debugpy openclaw Guides interactive Python debugging with pdb and debugpy remote attach. Useful for tracking down broken tests, state mutations, and headless processes. Claude Code CX Codex Cursor +1 332installs ctf-forensics ljagiello Digital forensics and signal analysis techniques for CTF challenges: disk images, memory dumps, PCAP files, steganography, Windows artifacts, and side-channel attacks. Claude Code CX Codex Cursor +1 9,000installs bash-scripting sickn33 A structured workflow for building shell scripts with defensive patterns, error handling, ShellCheck, and Bats tests. Claude Code CX Codex Cursor +1 2,400installs gpui-kit longbridge This skill guides AI coding assistants in building Rust desktop apps with the gpui-kit crate. Use it to implement UI components, manage state, handle focus, and write tests. Claude Code CX Codex Cursor +1 1,000installs migrate-to-shoehorn Matt Pocock Replaces as type assertions in tests with helpers from @total-typescript/shoehorn. Use it when tests need partial objects or deliberately invalid data. Claude Code 475,388installs write-swift emilkowalski This skill guides Swift coding, reviews, and migrations using the language’s current practices. Use it to investigate concurrency errors, hangs, data races, or retain cycles. Claude Code CX Codex Cursor +1 117,500installs megacave JuliusBrussee Switches agent responses to Classical Chinese (wenyan) to reduce terminal output. Activated via /megacave or /caveman wenyan. Claude Code CX Codex Cursor +1 24,400installs

Questions about embedded-systems

How to install embedded-systems in Claude Code?

Run npx skills add Jeffallan/claude-skills --skill embedded-systems -a claude-code in your terminal.

What does the embedded-systems skill do?

It sets guidelines and code patterns for microcontroller firmware, covering bare-metal register access, FreeRTOS task design, peripheral drivers, and memory optimization.

What constraints does the skill enforce on interrupt handlers?

The skill requires keeping ISRs short, using volatile for shared variables, avoiding blocking calls inside ISRs, and deferring heavy processing to RTOS tasks.

Source text

SKILL.md · MIT
---
name: embedded-systems
description: Use when developing firmware for microcontrollers, implementing RTOS applications, or optimizing power consumption. Invoke for STM32, ESP32, FreeRTOS, bare-metal, power optimization, real-time systems, configure peripherals, write interrupt handlers, implement DMA transfers, debug timing issues.
license: MIT
metadata:
  author: https://github.com/Jeffallan
  company: https://synergetic.solutions
  version: "1.1.0"
  domain: specialized
  triggers: embedded systems, firmware, microcontroller, RTOS, FreeRTOS, STM32, ESP32, bare metal, interrupt, DMA, real-time
  role: specialist
  scope: implementation
  output-format: code
  related-skills: 
---

# Embedded Systems Engineer

Senior embedded systems engineer with deep expertise in microcontroller programming, RTOS implementation, and hardware-software integration for resource-constrained devices.

## Core Workflow

1. **Analyze constraints** - Identify MCU specs, memory limits, timing requirements, power budget
2. **Design architecture** - Plan task structure, interrupts, peripherals, memory layout
3. **Implement drivers** - Write HAL, peripheral drivers, RTOS integration
4. **Validate implementation** - Compile with `-Wall -Werror`, verify no warnings; run static analysis (e.g. `cppcheck`); confirm correct register bit-field usage against datasheet
5. **Optimize resources** - Minimize code size, RAM usage, power consumption
6. **Test and verify** - Validate timing with logic analyzer or oscilloscope; check stack usage with `uxTaskGetStackHighWaterMark()`; measure ISR latency; confirm no missed deadlines under worst-case load; if issues found, return to step 4

## Reference Guide

Load detailed guidance based on context:

| Topic | Reference | Load When |
|-------|-----------|-----------|
| RTOS Patterns | `references/rtos-patterns.md` | FreeRTOS tasks, queues, synchronization |
| Microcontroller | `references/microcontroller-programming.md` | Bare-metal, registers, peripherals, interrupts |
| Power Management | `references/power-optimization.md` | Sleep modes, low-power design, battery life |
| Communication | `references/communication-protocols.md` | I2C, SPI, UART, CAN implementation |
| Memory & Performance | `references/memory-optimization.md` | Code size, RAM usage, flash management |

## Constraints

### MUST DO
- Optimize for code size and RAM usage
- Use `volatile` for hardware registers and ISR-shared variables
- Implement proper interrupt handling (short ISRs, defer work to tasks)
- Add watchdog timer for reliability
- Use proper synchronization primitives
- Document resource usage (flash, RAM, power)
- Handle all error conditions
- Consider timing constraints and jitter

### MUST NOT DO
- Use blocking operations in ISRs
- Allocate memory dynamically without bounds checking
- Skip critical section protection
- Ignore hardware errata and limitations
- Use floating-point without hardware support awareness
- Access shared resources without synchronization
- Hardcode hardware-specific values
- Ignore power consumption requirements

## Code Templates

### Minimal ISR Pattern (ARM Cortex-M / STM32 HAL)

```c
/* Flag shared between ISR and task — must be volatile */
static volatile uint8_t g_uart_rx_flag = 0;
static volatile uint8_t g_uart_rx_byte = 0;

/* Keep ISR short: read hardware, set flag, exit */
void USART2_IRQHandler(void) {
    if (USART2->SR & USART_SR_RXNE) {
        g_uart_rx_byte = (uint8_t)(USART2->DR & 0xFF); /* clears RXNE */
        g_uart_rx_flag = 1;
    }
}

/* Main loop or RTOS task processes the flag */
void process_uart(void) {
    if (g_uart_rx_flag) {
        __disable_irq();                   /* enter critical section */
        uint8_t byte = g_uart_rx_byte;
        g_uart_rx_flag = 0;
        __enable_irq();                    /* exit critical section  */
        handle_byte(byte);
    }
}
```

### FreeRTOS Task Creation Skeleton

```c
#include "FreeRTOS.h"
#include "task.h"
#include "queue.h"

#define SENSOR_TASK_STACK  256   /* words */
#define SENSOR_TASK_PRIO   2

static QueueHandle_t xSensorQueue;

static void vSensorTask(void *pvParameters) {
    TickType_t xLastWakeTime = xTaskGetTickCount();
    const TickType_t xPeriod  = pdMS_TO_TICKS(10); /* 10 ms period */

    for (;;) {
        /* Periodic, deadline-driven read */
        uint16_t raw = adc_read_channel(ADC_CH0);
        xQueueSend(xSensorQueue, &raw, 0); /* non-blocking send */

        /* Check stack headroom in debug builds */
        configASSERT(uxTaskGetStackHighWaterMark(NULL) > 32);

        vTaskDelayUntil(&xLastWakeTime, xPeriod);
    }
}

void app_init(void) {
    xSensorQueue = xQueueCreate(8, sizeof(uint16_t));
    configASSERT(xSensorQueue != NULL);

    xTaskCreate(vSensorTask, "Sensor", SENSOR_TASK_STACK,
                NULL, SENSOR_TASK_PRIO, NULL);
    vTaskStartScheduler();
}
```

### GPIO + Timer-Interrupt Blink (Bare-Metal STM32)

```c
/* Demonstrates: clock enable, register-level GPIO, TIM2 interrupt */
#include "stm32f4xx.h"

void TIM2_IRQHandler(void) {
    if (TIM2->SR & TIM_SR_UIF) {
        TIM2->SR &= ~TIM_SR_UIF;           /* clear update flag */
        GPIOA->ODR ^= GPIO_ODR_OD5;        /* toggle LED on PA5  */
    }
}

void blink_init(void) {
    /* GPIO */
    RCC->AHB1ENR |= RCC_AHB1ENR_GPIOAEN;
    GPIOA->MODER |= GPIO_MODER_MODER5_0;  /* PA5 output */

    /* TIM2 @ ~1 Hz (84 MHz APB1 × 2 = 84 MHz timer clock) */
    RCC->APB1ENR |= RCC_APB1ENR_TIM2EN;
    TIM2->PSC  = 8399;   /* /8400  → 10 kHz  */
    TIM2->ARR  = 9999;   /* /10000 → 1 Hz    */
    TIM2->DIER |= TIM_DIER_UIE;
    TIM2->CR1  |= TIM_CR1_CEN;

    NVIC_SetPriority(TIM2_IRQn, 6);
    NVIC_EnableIRQ(TIM2_IRQn);
}
```

## Output Templates

When implementing embedded features, provide:
1. Hardware initialization code (clocks, peripherals, GPIO)
2. Driver implementation (HAL layer, interrupt handlers)
3. Application code (RTOS tasks or main loop)
4. Resource usage summary (flash, RAM, power estimate)
5. Brief explanation of timing and optimization decisions

Maintained by [@jeffallan](https://github.com/jeffallan), Principal Consultant at [Synergetic Solutions](https://synergetic.solutions)

[Documentation](https://jeffallan.github.io/claude-skills/skills/specialized/embedded-systems/)

© https://github.com/Jeffallan · MIT · Jeffallan/claude-skills

See also

Project sponsors

Companies that keep this analytics open
Gold sponsor

Impressions, clicks and code copies — open statistics. We keep the numbers public for the same reason NeBlask itself is public. Become a sponsor