Skip to content
Development
Skill

/embedded-data-parsing-libs

Use when integrating, porting, configuring, or debugging embedded C data parsers such as cJSON, jsmn, or inih on MCU projects

From plugin
aix-skills
3976 skills

Claude Code

$ npx -y skills add easyzoom/aix-skills --skill embedded-data-parsing-libs --agent claude-code

SKILL.md

embedded-data-parsing-libs.SKILL.md
name: embedded-data-parsing-libs
description: Use when integrating, porting, configuring, or debugging embedded C data parsers such as cJSON, jsmn, or inih on MCU projects

Embedded Data Parsing Libs

Overview

Use this skill for small embedded data parsers where the main risks are memory allocation, input bounds, encoding assumptions, recursion, and callback handling. Cover `cJSON`, `jsmn`, and `inih` without copying their full APIs.

When To Use

Use this skill when:

  • The user wants to parse JSON or INI on an MCU.
  • The task mentions `cJSON`, `jsmn`, `inih`, config files, telemetry JSON, command payloads, or settings parsing.
  • The issue involves parse failure, memory leak, heap exhaustion, malformed input, callback mapping, or stack/recursion limits.

Do not use this skill for binary protocols or large streaming parsers outside these small libraries.

First Questions

Ask for:

  • Parser library: `cJSON`, `jsmn`, `inih`, or another small C parser.
  • Input source and maximum input size.
  • Runtime: bare metal, RTOS, Linux, bootloader, or shell command.
  • Whether dynamic allocation is allowed.
  • Expected schema and how malformed input should behave.
  • Current error, sample input, and memory budget.

Library Checks

cJSON

  • Decide whether heap allocation is acceptable.
  • Provide custom malloc/free hooks if the project uses a custom allocator.
  • Always delete parsed trees after use.
  • Bound input size before parsing.
  • Validate type before reading values.

jsmn

  • Allocate enough tokens for the expected JSON shape.
  • Handle `JSMN_ERROR_NOMEM`, `JSMN_ERROR_INVAL`, and `JSMN_ERROR_PART`.
  • Remember that tokens reference the original input buffer.
  • Validate string lengths and value types manually.

inih

  • Implement the handler callback with strict section/key matching.
  • Decide whether duplicate keys overwrite, error, or merge.
  • Bound line length and input source.
  • Validate converted numeric values and ranges.

Common Failures

  • Heap fragmentation from repeated `cJSON_Parse` without hooks or cleanup.
  • Token buffer too small for `jsmn`.
  • Using JSON token pointers after the input buffer is freed.
  • Accepting partial config and booting with unsafe defaults.
  • Silent typo in INI key because handler ignores unknown fields.

Verification

Before claiming parser integration works:

  • State parser, allocation policy, max input size, and schema assumptions.
  • Test valid input, missing fields, wrong types, malformed input, and oversize input.
  • Confirm memory is released or static buffers are bounded.
  • Confirm unknown fields and duplicate keys behavior.

Example

User:

想用 cJSON 解析串口发来的配置。

Agent:

1. Asks for max payload size, schema, allocator policy, and malformed-input behavior. 1. Uses custom hooks if needed and validates each field type. 1. Tests good JSON, missing keys, bad types, and oversized payloads.

Read more
@easyzoom
Ships withaix-skills

AIX Skills is a public collection of Agent Skills, templates, and references for building repeatable AI workflows.

Stars on GitHub

Momentum

stars in total
39
Star history of easyzoom/aix-skills on GitHub, a chart by star-history.com

Other skills on aix-skills.

8051-mcu-debug

8051-mcu-debug

Use when debugging 8051-compatible microcontrollers, 51 MCU firmware, STC download issues, Keil C51 projects, interrupts, timers,…

@easyzoom@easyzoomInstall Skill
avem-integration

avem-integration

Use when integrating, evaluating, configuring, or debugging Avem embedded C framework modules, event-driven components, drivers,…

@easyzoom@easyzoomInstall Skill
ble-gatt-integration

ble-gatt-integration

Use when integrating, designing, or debugging BLE GATT services, characteristics, descriptors, MTU, notifications, indications,…

@easyzoom@easyzoomInstall Skill
bootloader-debug

bootloader-debug

Use when debugging embedded bootloaders, application jumps, vector table offsets, firmware upgrade flow, OTA state, image…

@easyzoom@easyzoomInstall Skill
canbus-integration

canbus-integration

Use when integrating, porting, configuring, or debugging CAN bus libraries, CANBus-Triple, MCP2515, CAN frames, bit timing,…

@easyzoom@easyzoomInstall Skill

More skills from other plugins.

brainstorming
Auto-invoked

brainstorming

You MUST use this before any creative work - creating features, building components, adding functionality, modifying behavior, or…

@obra@obraInstall Skill
ask-matt

ask-matt

Ask which skill or flow fits your situation. A router over the skills in this repo.

skills2w309k
@mattpocock@mattpocockInstall Skill
accessibility
Auto-invoked

accessibility

Design, implement, and audit accessible UI to WCAG 2.2 Level AA across Web, iOS, and Android — semantic ARIA roles and labels,…

ecc2w293k
@affaan-m@affaan-mInstall Skill
compiler-commit

compiler-commit

Use when you want to verify compiler changes and commit with the correct convention. Runs tests, lint, and format, then commits…

react5d252k
@facebook@facebookInstall Skill

Questions about embedded-data-parsing-libs.

Which coding agents can use embedded-data-parsing-libs?
embedded-data-parsing-libs installs in Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, OpenCode and Windsurf with the skills CLI, using each agent's flag shown on this page. Flowy's auto-invocation, which fires a skill when your prompt matches, runs in Claude Code only.