Integrates, ports, configures, and debugs littlefs on MCU flash, external NOR/NAND, SD-backed block devices, bare-metal, or RTOS projects.
Ships in aix-skills. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Use this skill to integrate littlefs safely on embedded block devices. The core task is to make the lfs_config match the real storage geometry and prove mount, format, write, sync, power-loss, and remount behavior.
Use this skill when:
LFS_ERR_CORRUPT, read/write errors, wear leveling, block geometry, formatting, or data loss after reboot.lfs.h, lfs_file_*, lfs_dir_*, or struct lfs_config.Do not use this skill for generic flash programming failures before the block device driver works. Use mcu-flashing-debug first.
Ask for:
lfs_config, block device read/prog/erase/sync functions, and error codes.Confirm block geometry.
Set read_size, prog_size, block_size, block_count, cache_size, lookahead_size, and block_cycles from the real storage device, not guesses.
Validate block operations.
read, prog, erase, and sync must use block-relative offsets correctly and return negative error codes on failure.
Respect flash rules. Programming can only change erased bits in the supported direction, writes must be aligned, and erase must cover whole erase blocks.
Decide mount policy.
Try lfs_mount first. Only call lfs_format after explicit user approval or when the product policy allows first-boot formatting.
Add locking if needed. Protect littlefs calls with a mutex if multiple tasks, interrupt contexts, or shell commands can access the filesystem.
Prove persistence. Write a file, close/sync it, unmount if possible, reset, remount, and read back.
context points to the storage driver state if needed.block_size or block_count does not match the actual partition.Before claiming littlefs works:
lfs_config values.User:
littlefs 挂载总是 LFS_ERR_CORRUPT。
Agent:
lfs_config, block driver functions, partition address, and whether format is allowed.What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
/aix-skills:littlefs-integrationfrom aix-skills
npx claudepluginhub easyzoom/aix-skills --plugin aix-skills76 skills in this plugin
/8051-mcu-debugUse when debugging 8051-compatible microcontrollers, 51 MCU firmware, STC download issues, Keil C51 projects, interrupts, timers, UART, or startup failures/avem-integrationUse when integrating, evaluating, configuring, or debugging Avem embedded C framework modules, event-driven components, drivers, middleware, or application architecture/battery-charger-fuel-gauge-integrationUse when integrating or debugging Li-ion charger/fuel gauge ICs (BQ24295, BQ27441, MAX17048) over I2C, covering charge start, watchdog host mode, NTC/JEITA faults, and SOC jumpsOther plugins' skills for the same job