ESP-IDFを使ってみる

ESP32-C5開発ボード

Espressif Systemsから2022年4月20日に、こちらの 公式アナウンスが公開されました。
ESP32-C6のフォローアップ版(?)だそうです。
2.4GHz/5GHzのDual BandのWiFi 6 (IEEE 802.11ax) + Bluetooth 5 (LE) をサポートするようです。
ESP32-C6のCPU周波数が160MHzに対して、ESP32-C5は240MHzになっています。
ESP32S3@160とESP32C3@160を比べると、整数演算に関してはESP32C3@160の方が高速です。
2023年時点では、240MHzで動作するESP32S3が最速のSoCですが、整数演算に関しては、ESP32-C5の方がこれを上回る可能 性が有ります。
まだデータシートが公開されていないので、これ以上詳しいことは分かりません。



2022年の公式アナウンス以降、何の音沙汰もなかったこのボードですが、2024年3月末(頃)にこ ちらのESP32-C5 Test Boardの情報が
Espressif Systemsから公開されました。
この資料によると、2.4GHz/5GHzのDual BandのWi-Fi 6 (IEEE 802.11ax) + Bluetooth LE 5に加え、IEEE 802.15.4もサポートされるようです。
CPUクロック周波数やメモリーサイズなどの具体的な数値の記載は有りませんが、GPIOはGPIO0からGPIO11とGPIO25/26の 14個あるようです。
2.4GHz/5GHzのDual Bandになると、アンテナがどうなるのか気になるところです。

esp-idf v5.3では既にターゲットとして設定されています。
$ idf.py --version
ESP-IDF v5.3-dev-2381-g9f4e8eb0cd

$ idf.py set-target
Usage: idf.py set-target [OPTIONS] {esp32|esp32s2|esp32c3|esp32s3|esp32c2|esp3
                         2c6|esp32h2|linux|esp32p4|esp32c5|esp32c61}
Try 'idf.py set-target --help' for help.

Error: Missing argument '{esp32|esp32s2|esp32c3|esp32s3|esp32c2|esp32c6|esp32h2|linux|esp32p4|esp32c5|esp32c61}'. Choose from:
        esp32,
        esp32s2,
        esp32c3,
        esp32s3,
        esp32c2,
        esp32c6,
        esp32h2,
        linux,
        esp32p4,
        esp32c5,
        esp32c61



こ ちらのESP32の一覧では、2024年10月時点で、ESP32-C5のサンプル出荷が始まっています。
2025年中には開発ボードが入手できると思います。



2025年5月にようやくESP32-C5のステータスがMass Productionになり、Hardware Design Guidelinesがこ ちらに公開されました。
以下はベータ版のデータシートの内容ですが、正式なデータシートも近日中に公開されると思います。
正式なデータシートが公開されたら改めて改訂しますが、本当にUSB OTGが使えるなら嬉しいです。

ESP32-C6 ESP32-C5
HP Core 32-bit RISC-V single-core processor, up to 160MHz 32-bit RISC-V single-core processor, up to 240MHz
ULP Core 32-bit RISC-V single-core processor, up to 20MHz 32-bit RISC-V single-core processor, up to 40MHz
Memory 384 KB ROM
400 KB SRAM
320 KB ROM
512 KB HP SRAM
16 KB LP SRAM
Wi-Fi 802.11 b/g/n/ax 802.11 b/g/n/ax/ac
Bluetooth Bluetooth 5.3/Bluetooth Mesh Bluetooth 5.x/Bluetooth Mesh 1.1
IEEE 802.15.4 Compliant with IEEE 802.15.4-2015 protocol
• Thread 1.3
• Zigbee 3.0
Compliant with IEEE 802.15.4-2015 protocol
• Thread 1.3
• Zigbee 3.0
Advanced Peripheral Interfaces • 30 or 22 × programmable GPIOs
• 1 × 12-bit SAR ADCs, up to 7 channels
• 1 × temperature sensor


• 2 × UART
• 1 × Low-power UART
• 2 × SPI ports for communication with flash
• 1 × General purpose SPI port
• 1 × I2C
• 1 × Low-power (LP) I2C
• 1 × I2S
• 1 × Pulse count controller

• 1 × USB Serial/JTAG controller
• 2 × TWAI controller (compatible with ISO 11898-1)
• 1 × SDIO 2.0 slave controller
• 1 × LED PWM controller, up to 6 channels
• 1 × Motor Control PWM (MCPWM), up to 6 channels
• 1 × Remote control peripheral (RMT) (TX/RX)
• 1 × Parallel IO interface (PARLIO)
• 1 × General DMA controller (GDMA), with 3 transmit channels and 3 receive channels

• 1 × Event task matrix (ETM)
• 27 or 19 × programmable GPIOs
• 1 × 12-bit SAR ADCs, up to 6 channels
• 1 × temperature sensor
• 1 × Brownout detector
• 1 × Analog PAD voltage comparator
• 2 × UART
• 1 × Low-power UART
• 2 × SPI ports for communication with flash
• 1 × General purpose SPI port
• 1 × I2C
• 1 × Low-power (LP) I2C
• 1 × I2S
• 1 × Pulse count controller
• 1 × USB 2.0 OTG High-Speed
• 1 × USB Serial/JTAG controller
• 2 × TWAI controller (compatible with ISO 11898-1)
• 1 × SDIO 2.0 slave controller
• 1 × LED PWM controller, up to 6 channels
• 1 × Motor Control PWM (MCPWM), up to 6 channels
• 1 × Remote control peripheral (RMT) (TX/RX)
• 1 × Parallel IO interface (PARLIO)
• 1 × General DMA controller (GDMA), with 3 transmit channels and 3 receive channels
• 1 × Bit-scrambler controller
• 1 × Event task matrix (ETM)

続く....