Skip to content

Feat/seeed esp32s3 xiao sense board - #658

Merged
shiliu-yang merged 5 commits into
tuya:masterfrom
yingtao450:feat/seeed-esp32s3-xiao-sense-board
Jul 31, 2026
Merged

Feat/seeed esp32s3 xiao sense board#658
shiliu-yang merged 5 commits into
tuya:masterfrom
yingtao450:feat/seeed-esp32s3-xiao-sense-board

Conversation

@yingtao450

Copy link
Copy Markdown
Contributor

PR 描述/PR description

[在此详细描述 PR 的内容]/[Describe the PR content in detail here]

代码质量/Code Quality:

在本次拉取请求中,我已考虑以下事项 As part of this pull request, I've considered the following:

  • 确保代码注释和文档清晰,并使用英文注释以保证代码可读性。Ensure that the code comments and documentation are clear, and use English for comments to ensure code readability.
  • 确保文件头遵循文件头格式。Ensure that the file header follows the File Header Format.
  • 确保函数头遵循 Doxygen 格式。Ensure that function headers follow the Doxygen format as specified in Comments.
  • 已查阅 编码风格指南,并核查代码风格合规性,包括缩进、空格、命名规范及其他风格要求。 Reviewed the Coding Style Guide and verified code style compliance, including indentation, spacing, naming conventions, and other style guidelines.
  • 已使用代码格式化工具确保符合 TuyaOpen 编码规范。Have used the code-formatting source code formatting tool to ensure compliance with TuyaOpen coding standards.

yingtao450 and others added 5 commits July 31, 2026 10:27
Add board support for the Seeed XIAO ESP32S3 Sense (ESP32-S3R8, 8MB
flash / 8MB PSRAM): OV2640/OV3660 DVP camera, PDM digital microphone,
onboard LED (GPIO21), BOOT button (GPIO0), and optional microSD.

- New board dir boards/ESP32/SEEED_ESP32S3_XIAO_SENSE with camera / PDM
  mic / LED|button / SD registration; LED and SD share GPIO21, so
  ENABLE_LED is Kconfig-gated on !ENABLE_SEEED_XIAO_SDCARD.
- New common PDM mic TDD driver (tdd_audio_pdm_mic): mic-only capture via
  ESP-IDF I2S PDM RX, guarded by SOC_I2S_SUPPORTS_PDM_RX so non-PDM
  targets still build.
- Register the board in boards/ESP32/Kconfig.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Add a way for a camera driver to advertise which output formats it
supports, so applications can query capabilities instead of trying an
open() and handling the error. Previously the TDD dev_info only carried
a single native raw format (sr_fmt), which was write-only in TDL.

- Replace the single fmt/sr_fmt field with a supported_fmts bitmask
  (TDL_CAMERA_FMT_E) in TDD_CAMERA_DEV_INFO_T and TDL_CAMERA_DEV_INFO_T;
  surfaced via tdl_camera_dev_get_info(). 0 = unspecified (probe via
  open, preserving old behavior for drivers that don't set it).
- Fill it per driver from what open() accepts: ESP DVP (OV2640) and
  ESP CSI (P4) = YUV422|JPEG; core DVP (T5AI) = YUV422|JPEG|H264;
  Linux v4l2 = YUV422|JPEG.

Only ESP32-S3 was build-verified; T5AI and Linux changes are field
renames with correct masks but were not compiled here.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
- output_sdcard: pick the camera output format at runtime from the
  driver's supported_fmts (prefer H264, else JPEG) instead of hardcoding
  H264, so it runs on ESP32-S3 (JPEG) as well as T5AI (H264). File
  extension follows the chosen format.
- output_web: new example streaming the camera to a web browser as
  MJPEG over HTTP (WiFi STA + tiny HTTP server); frames buffered in
  PSRAM, Nagle disabled for smoother streaming. For camera boards
  without a display. Configs for SEEED_ESP32S3_XIAO_SENSE and
  TUYA_T5AI_BOARD.
- Add SEEED_ESP32S3_XIAO_SENSE board configs to led, switch_demo and
  camera_demo.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Reorganize the audio examples so audio_codecs is a container with two
leaves that name their output path:
- output_speaker: the former audio_codecs (record then play back through
  a speaker/codec).
- output_sdcard: the former multimedia/audio_recorder/output_sdcard
  (record the mic to a WAV file on SD). Moved here and removed the now
  empty multimedia/audio_recorder.

Also: rename the recorder output to record.pcm/record.wav — ESP-IDF
FATFS defaults to 8.3 short names, so "tuya_recorder.wav" failed to
open; and add a SEEED_ESP32S3_XIAO_SENSE config for output_sdcard.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
camera_demo has a pre-existing build break (tuya_p2p headers use
undefined CHAR_T/UINT_T), so it does not compile for any board. Remove
the SEEED_ESP32S3_XIAO_SENSE config so CI does not try (and fail) to
build camera_demo for this board.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@shiliu-yang
shiliu-yang merged commit 966ff6a into tuya:master Jul 31, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants