| name | waveshare-esp32-p4-devkit-b |
| description | Bootstraps Arduino projects for the Waveshare ESP32-P4 Module DEV KIT B
(SKU 30843) with the 7-inch DSI capacitive touch display (7-DSI-TOUCH-A).
Use this skill when the user wants to start a new Arduino project on this
specific board, or asks about pin assignments, display/touch wiring, partition
scheme, PSRAM config, or LVGL setup for this hardware. Generates the .ino
starter, Display layer (LVGL orchestration), and lv_conf.h. Does NOT generate
project.json / partitions.csv / tasks.json — those are produced by the
esp32-arduino-development skill, which reads board-profile.md from this skill
to pre-fill the right values. Vendors offline copies of the Waveshare libraries
(displays, GFX_Library_for_Arduino, lvgl) and syncs them into the user's
../libraries/ folder when a new project is created. Includes board schematics,
ESP32-P4 datasheet, and TRM in references/. Vendored libs and PDFs come from
the official Waveshare demo bundle; all updates flow through this skill
rather than from the public Arduino library registry.
|
| author | ErabliTEK |
| version | 0.1.0 |
| date | "2026-04-24T00:00:00.000Z" |
Waveshare ESP32-P4 Module DEV KIT B — Arduino Project Scaffolder
Purpose
Creates a new Arduino project pre-configured for the Waveshare ESP32-P4 Module
DEV KIT B (SKU 30843) with the 7-inch 720×1280 DSI capacitive touch display
(7-DSI-TOUCH-A). The skill encapsulates everything board-specific: pin map,
display init sequence, touch controller, LVGL orchestration, PSRAM draw buffers,
and the offline library versions tested with this hardware.
Composition with esp32-arduino-development
This skill is the source of truth for board-specific Arduino settings. It
does not generate project.json, partitions.csv, .vscode/tasks.json, or
drive any compile/flash/monitor action. Those are the responsibility of the
esp32-arduino-development skill.
When a project is created here, hand off to esp32-arduino-development to
finalize the build setup. That skill consults references/board-profile.md from
this skill to pre-fill the FQBN, flash size, PSRAM, partition scheme, libraries
path, and required core version.
Trigger phrases
Run this skill when the user says any of:
- "new Waveshare P4 project", "new ESP32-P4 DEV-KIT project", "create a P4 project"
- "scaffold a project for the 7-inch P4 board"
- "what pins are used by the [I2C/touch/display/SD card/Ethernet] on the P4 DEV-KIT?"
- "which lvgl version works with the Waveshare P4?"
- "what partition scheme should I use for the 16 MB flash on the DEV-KIT?"
Also act as a reference: when the user is mid-project and asks pin/spec
questions about this board, read the appropriate file under references/ and
answer from there rather than guessing.
Interactive project creation
When the user asks to create a new project on this board, ask these questions
in order, one at a time, using tappable options where possible:
1. Project name
Used for the directory and the .ino filename. Convention: lowercase letters,
digits, underscores or hyphens only.
2. Project parent directory
Default: the parent directory of the current working directory (so the new
project lives as a sibling of the current one, sharing ../libraries/). Always
confirm before creating files.
3. Display orientation
- Landscape (default) — 1280×720, swap XY in touch controller
- Portrait — 720×1280, native panel orientation, no swap
This sets a single #define DISPLAY_LANDSCAPE 1 (or 0) in the generated
Display.cpp.
4. Starter content
Offer 4 options:
- Blank — black background, no widget. Use this if you'll wire
SquareLine Studio next.
- Hello World — single centered
lv_label saying "Hello LVGL".
- Button counter — label + button; button taps increment the label.
Tests the touch input end-to-end.
- Full LVGL widgets demo — runs
lv_demo_widgets() (rich showcase of
every LVGL widget, useful as a benchmark/sanity check). Requires the LVGL
demos to be enabled in lv_conf.h (already set in our template).
5. SquareLine Studio scaffolding
Single yes/no question: "Pre-wire the project for SquareLine Studio export?"
- Yes → create empty
src/Display/ui/ folder + add a stub ui_init()
declaration in Display.h + add #define DISPLAY_USE_SQUARELINE 1 in the
.ino so Display::begin() will call ui_init() once the user drops the
SquareLine export there.
- No (default) → vanilla LVGL only, no scaffolding.
This is independent of the starter content choice — the user can have a
"Hello World" starter today and add SquareLine later by just defining the
macro and dropping in the export.
Project file generation
After collecting answers, the skill creates this layout under
<parent_dir>/<project_name>/:
<project_name>/
├── <project_name>.ino # generated from one of the 4 starter templates
├── lv_conf.h # copied verbatim from templates/lv_conf.h
└── src/
└── Display/
├── Display.h # API: begin, lock/unlock, getDisplay, optional ui_init hook
└── Display.cpp # parameterized: orientation, demo content, SquareLine flag
└── ui/ # only if SquareLine scaffolding chosen, else absent
└── .gitkeep
Generation rules:
- Orientation — when landscape, set
DISPLAY_LANDSCAPE 1 in Display.cpp
and call esp_lcd_touch_set_swap_xy(handle, true) after touch_gt911_init().
When portrait, leave the touch handle untouched.
- Starter content — pick one of
templates/starter_blank.ino,
starter_hello_world.ino, starter_button_counter.ino,
starter_lvgl_demo.ino and substitute {{PROJECT_NAME}} placeholders.
- SquareLine flag — when yes, add
#define DISPLAY_USE_SQUARELINE 1
above the #include "src/Display/Display.h" in the .ino and create
src/Display/ui/.gitkeep. The Display.cpp always wraps the ui_init()
call in #ifdef DISPLAY_USE_SQUARELINE, so the macro alone toggles it.
- The skill never writes outside
<parent_dir>/<project_name>/ and
<parent_dir>/libraries/ (lib sync — see next section).
Library sync to ../libraries/
After project file generation, the skill checks each library listed in
libraries/MANIFEST.md against the user's <parent_dir>/libraries/:
for lib in MANIFEST:
installed = read_version("<parent_dir>/libraries/<lib>/library.properties")
manifest = manifest_version_for(lib)
if not installed:
propose: "Library <lib> is not installed in ../libraries/. Copy from skill?"
elif installed != manifest:
propose: "Library <lib>: installed=<installed>, skill=<manifest> (updated <date>).
Choose: keep installed / overwrite with skill / show diff."
else:
skip silently
Rules:
- Never overwrite without explicit user confirmation.
- Never symlink — always copy. The user's
../libraries/ is shared with
other projects and may be on cloud storage that doesn't support symlinks.
- Never touch libraries not listed in MANIFEST. AsyncIoTManager,
ArduinoJson, etc. are user-managed and out of scope.
- When proposing an update, show the version delta and the manifest's
last_updated date so the user can decide.
- The
displays library has no library.properties (Waveshare ships it as a
loose set of files). Compare by hash of the directory contents instead, and
display "fingerprint match" or "files changed: N" rather than versions.
Hand-off to esp32-arduino-development
After the project is generated and libraries are synced, end with:
Project scaffolded. To finalize the build setup, run the
esp32-arduino-development skill. It will read
~/.claude/skills/waveshare-esp32-p4-devkit-b/references/board-profile.md
and pre-fill project.json for this board. Then you can compile, flash, and
monitor through that skill.
Do NOT generate project.json here. Do NOT call arduino-cli here. The
separation of concerns is intentional and keeps both skills maintainable.
Reference files
Use these when the user asks board-specific questions mid-project:
| File | When to read |
|---|
references/board-profile.md | Recommended project.json values (FQBN, flash, partition, PSRAM, etc.) |
references/pinout.md | Any pin-mapping question (GPIO X is what?) |
references/i2c-bus-map.md | I2C device addresses (touch, codec, etc.) on the shared bus |
references/display-spec.md | DSI timings, panel resolution, lane bit rate, touch controller |
references/arduino-setup-notes.md | Core version requirements, gotchas, partition rationale |
references/schematics/ESP32-P4-Module-DEV-KIT-schematic.pdf | Authoritative wiring source — read with the Read tool when unsure |
references/datasheets/ESP32-P4_datasheet.pdf | Chip-level questions (clock domains, power rails, peripherals) |
references/datasheets/ESP32-P4_TRM.pdf | Deep technical questions (PPA, 2D-DMA, MIPI DSI registers, etc.) |
Skill self-update
This skill is maintained by ErabliTEK. Updates are manual:
- Waveshare publishes a new demo bundle on the wiki Resources page
- Download and extract — diff against the skill's
libraries/
- If libraries changed, copy the new versions into
libraries/, update
MANIFEST.md versions and last_updated dates, bump the skill version
field in this frontmatter, and add a CHANGELOG.md entry
- The user's
../libraries/ will then be flagged as out-of-date the next
time this skill creates a project there
When asked "is the skill up to date?", look at MANIFEST.md last_updated
dates and tell the user when the libraries were last refreshed.
Style and tone
- Respond in French if the conversation is in French; English otherwise
- Be concise. The user knows the hardware — don't over-explain
- When proposing destructive operations on
../libraries/, always show the
full plan first and require explicit confirmation
- Schematic, datasheet, and TRM are large PDFs — read only the pages relevant
to the question (use the
pages: parameter of the Read tool)