video/esp32s3: add GC0308 DVP camera support for lckfb-szpi-esp32s3#18542
Merged
acassis merged 5 commits intoapache:masterfrom Mar 16, 2026
Merged
video/esp32s3: add GC0308 DVP camera support for lckfb-szpi-esp32s3#18542acassis merged 5 commits intoapache:masterfrom
acassis merged 5 commits intoapache:masterfrom
Conversation
Add big-endian RGB565 (RGB565X) pixel format throughout the V4L2 video pipeline: - IMGDATA_PIX_FMT_RGB565X in imgdata.h - IMGSENSOR_PIX_FMT_RGB565X in imgsensor.h - Format conversion and buffer size handling in v4l2_cap.c This is needed by 8-bit DVP camera sensors that output RGB565 in big-endian byte order (high byte first on the data bus). Signed-off-by: wangjianyu3 <wangjianyu3@xiaomi.com>
72e0488 to
50138cd
Compare
eren-terzioglu
approved these changes
Mar 16, 2026
Contributor
eren-terzioglu
left a comment
There was a problem hiding this comment.
Hi,
Nice work, congrats
Contributor
|
Hi @JianyuWang0623, Please align CMakeLists.txt with Make.defs (drivers/video) |
50138cd to
1832a92
Compare
simbit18
previously approved these changes
Mar 16, 2026
acassis
previously approved these changes
Mar 16, 2026
Contributor
acassis
left a comment
There was a problem hiding this comment.
@JianyuWang0623 that is amazing!!! Thank you very much! I bought a device and I'm looking forward to test it!
Contributor
|
Hi @JianyuWang0623, please fix |
6208696 to
caa8876
Compare
Contributor
Author
|
depends on: apache/nuttx-apps#3425 |
caa8876 to
5c02755
Compare
acassis
previously approved these changes
Mar 16, 2026
5c02755 to
b7ff824
Compare
Add support for the GalaxyCore GC0308 VGA CMOS image sensor. The driver implements the NuttX imgsensor interface and supports VGA (640x480), QVGA (320x240), and QQVGA (160x120) resolutions via Kconfig selection. Output format is RGB565X (big-endian). Signed-off-by: wangjianyu3 <wangjianyu3@xiaomi.com>
Add ESP32-S3 CAM controller driver implementing the NuttX imgdata interface. Supports 8-bit DVP camera input with DMA-based frame capture, VSYNC interrupt handling, and PSRAM frame buffer allocation. The driver is sensor-agnostic: resolution and pixel format are negotiated at runtime through the V4L2 pipeline. XCLK output (24 MHz) is started during initialization for sensor communication. Signed-off-by: wangjianyu3 <wangjianyu3@xiaomi.com>
Add camera configuration for lckfb-szpi-esp32s3 board with GC0308 sensor on DVP interface. Includes board-level camera initialization, DVP GPIO pin mapping, and V4L2 video pipeline setup. Signed-off-by: wangjianyu3 <wangjianyu3@xiaomi.com>
b7ff824 to
184ff0a
Compare
simbit18
approved these changes
Mar 16, 2026
Contributor
Author
|
Set as draft until dependency apache/nuttx-apps#3425 is merged. |
Contributor
|
Hi @JianyuWang0623, PR apache/nuttx-apps#3425 merged |
Add a minimal GC0308 camera configuration based on nsh. Unlike the full camera config, this only enables the GC0308 DVP camera driver (I2C, PCA9557, LEDC, CAM, VIDEO) and camcap example, without ADB, SDMMC, LCD, PSRAM or other peripherals. Signed-off-by: wangjianyu3 <wangjianyu3@xiaomi.com>
184ff0a to
5abe378
Compare
acassis
approved these changes
Mar 16, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Note: Please adhere to Contributing Guidelines.
Summary
Add GC0308 DVP camera support for the ESP32-S3 platform, including the full V4L2 video pipeline from pixel format definition to board-level configuration.
This PR contains 5 patches:
video: add V4L2_PIX_FMT_RGB565X pixel format support — Add big-endian RGB565 (RGB565X) format to
imgdata.h,imgsensor.h, andv4l2_cap.c. This is needed by 8-bit DVP camera sensors that output RGB565 in big-endian byte order (high byte first on the data bus).drivers/video: add GC0308 VGA CMOS image sensor driver — Add a NuttX imgsensor driver for the GalaxyCore GC0308 VGA CMOS sensor. Supports VGA (640x480), QVGA (320x240), and QQVGA (160x120) resolutions via Kconfig. Output format is RGB565X.
arch/xtensa/esp32s3: add CAM DVP imgdata driver — Add an ESP32-S3 CAM controller driver implementing the NuttX imgdata interface. Supports 8-bit DVP input with DMA-based frame capture, VSYNC interrupt handling, and PSRAM frame buffer allocation. The driver is sensor-agnostic: resolution and pixel format are negotiated at runtime through the V4L2 pipeline.
boards/lckfb-szpi-esp32s3: add camera defconfig — Add a full camera configuration for the lckfb-szpi-esp32s3 board with GC0308 on DVP interface. Includes board-level camera initialization, DVP GPIO pin mapping, V4L2 video pipeline setup, ADB, SDMMC, LCD, and PSRAM.
boards/lckfb-szpi-esp32s3: add gc0308 minimal defconfig — Add a minimal GC0308 camera configuration based on nsh. Only enables the GC0308 DVP camera driver (I2C, PCA9557, LEDC, CAM, VIDEO) without ADB, SDMMC, LCD, PSRAM or other peripherals.
Impact
V4L2_PIX_FMT_RGB565Xadded to the V4L2 pipeline — no impact on existing formats.drivers/video/gc0308.c— only compiled whenCONFIG_VIDEO_GC0308=y.arch/xtensa/src/esp32s3/esp32s3_cam.c— only compiled whenCONFIG_ESP32S3_CAM=y.cameraandgc0308forlckfb-szpi-esp32s3— no impact on existing configs.Documentation/platforms/xtensa/esp32s3/boards/lckfb-szpi-esp32s3/index.rst.Testing
Host: Ubuntu x86_64
Board: LCKFB SZPI ESP32-S3 (ESP32-S3-WROOM-1-N16R8) + GC0308 DVP camera module
Build & flash (gc0308 minimal config):
Build & flash (camera full config):
Both configurations build and flash successfully. Camera frame capture verified on hardware — GC0308 outputs 320x240 RGB565X frames (153600 bytes) via the V4L2 pipeline.
Test app - camcap: JianyuWang0623/nuttx-apps@4aeadf2 (TEMPORARY)