esp-thread-br-skill

Guides firmware development for ESP32-based Thread Border Routers using esp-thread-br and OpenThread.

28|3|Updated Jun 24, 2026
One-click install
npx skills add https://github.com/JasonYANG170/esp-dev-skill --skill esp-thread-br-skill-jasonyang170
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: esp-thread-br-skill
Source: https://github.com/JasonYANG170/esp-dev-skill/tree/main/repos/esp-thread-br
Command: npx skills add https://github.com/JasonYANG170/esp-dev-skill --skill esp-thread-br-skill-jasonyang170

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Building an ESP Thread Border Router requires coordinating a dual-chip architecture (ESP32 host SoC plus ESP32-H2/C6 RCP), strict initialization ordering, version-sensitive lwIP configuration, and many Kconfig options; this Skill grounds AI code generation in the real esp-thread-br repository docs and source so no APIs or settings are invented. ## Core Features & Use Cases - Scenario Recipes: 15 step-by-step recipes covering build/flash, board and UART/SPI interface selection, auto-start mode, bidirectional IPv6, multicast forwarding, SRP/mDNS service discovery, NAT64, TREL, DHCPv6 PD, credential sharing, Web GUI, RCP update, HTTPS OTA, and RF coexistence. - API & Config Reference: Real function signatures from components like esp_rcp_update, esp_br_http_ota, esp_ot_br_server, and esp_ot_cli_extension, plus Kconfig, pin, and partition tables extracted from sdkconfig.defaults. - Pitfall Prevention: 13 critical pitfalls with WRONG/CORRECT code pairs, such as binding the backbone netif before border_router_init and matching LWIP_IPV6_NUM_ADDRESSES to the IDF version. - Use Case: Ask the agent to create a Thread Border Router firmware for an ESP32-S3 board with Wi-Fi backbone and automatic RCP update, and it will produce the correct app_main sequence, esp_ot_config.h pins, partitions.csv, and build commands. ## Quick Start Ask the agent to build and flash a Thread Border Router on an ESP32-S3 with an ESP32-H2 RCP and verify it reaches the leader role.

Frequently Asked Questions about esp-thread-br-skill

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I build and flash an ESP Thread Border Router?

Set up ESP-IDF (v5.5.4 recommended), build the ot_rcp example for ESP32-H2, then in examples/basic_thread_border_router run idf.py set-target esp32s3, menuconfig, build, and flash monitor. The RCP image is packaged automatically during the BR build.

How do I set up a Thread Border Router with ESP32-S3 and ESP32-H2?

Use the basic_thread_border_router example with the ESP32-S3 as host and ESP32-H2 as RCP over UART at 460800 baud. Connect reset and boot pins, then either enable OPENTHREAD_BR_AUTO_START or manually run wifi connect, dataset init new, dataset commit active, ifconfig up, thread start.

Which ESP32 chips work as host or RCP for a Thread Border Router?

Supported hosts are ESP32-S3, ESP32-P4, ESP32-C5, and ESP32-C61; the RCP must be ESP32-H2 or ESP32-C6. A dual-chip design is mandatory because the host runs the Border Router while the RCP handles 802.15.4 radio.

Why does my Thread Border Router stay in detached state?

The most common cause is wrong startup ordering: thread start was issued before ifconfig up, or the dataset was never committed. Follow the sequence dataset init new, dataset commit active, ifconfig up, then thread start, and verify the backbone netif was bound before border_router_init.

Why does RCP communication fail with Spinel response timeout?

This usually means UART or SPI pins or baud rate mismatch between host and RCP configs. On ESP32-S3 avoid GPIO17/18 for UART due to drive current differences; use GPIO4/GPIO5, and ensure both sides use the same interface mode.

Can the Thread Border Router do OTA updates including the RCP firmware?

Yes, with CONFIG_OPENTHREAD_CLI_OTA and CONFIG_CREATE_OTA_IMAGE_WITH_RCP_FW enabled, the build produces an ota_with_rcp_image bundle. Trigger it at runtime with the ota download CLI command over HTTPS after replacing server_certs/ca_cert.pem with your server certificate.