rdk-camera-setup
Skill5 starsChanged 3 months agoApache-2.0View on GitHub
Detect, connect, and verify MIPI/USB cameras on D-Robotics RDK devices using i2cdetect and official pydev_demo samples. Use when the user connects a camera and wants to confirm it works, gets no image or a black screen, or i2cdetect finds no address. Triggers include 摄像头, MIPI, USB 相机, IMX219, OV5647, IMX477, 出图, 黑屏, 扫不到地址, mipi_cam, /dev/video0. Do not use for sensor driver development or ISP tuning — point to official 07_Advanced_development docs.
- Installs packages
2 other projects use a version of this, 1 of them edited.
Adopted by
Most recently taken up by
- D-Robotics/rdk-device-skillsword for word, first seen Oct 15, 2026
- D-Robotics/dsh-plugin-rdkedited, first seen Aug 28, 2026
Other versions2 projects use a version of this.
Word for word · 1
- D-Robotics/rdk-device-skills★ 4100% same
Edited · 1
- D-Robotics/dsh-plugin-rdk★ 198% same
Wrote their own version · 0
None found.
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository42 other files it gives its agents.
- bsp-bootloader-buildSkill
- bsp-deb-buildSkill
- bsp-env-setupSkill
- bsp-image-buildSkill
- bsp-kernel-buildSkill
- bsp-rootfs-customSkill
- bsp-source-syncSkill
- bsp-s-seriesSkill
- cmos-sensor-bringupSkill
- rdk-accessoriesSkill
- rdk-board-delegateSkill
- rdk-board-knowledgeSkill
- rdk-command-manualSkill
- rdk-diagnosticSkill
- rdk-docs-referenceSkill
- rdk-ecosystemSkill
- rdk-embodied-lerobotSkill
- rdk-gpio-40pinSkill
- rdk-hardwareSkill
- rdk-headless-modeSkill
- rdk-llm-deploymentSkill
- rdk-log-forensicsSkill
- rdk-memory-auditSkill
- rdk-model-benchmarkSkill
- rdk-model-deploySkill
- rdk-model-zoo-developSkill
- rdk-model-zoo-integrateSkill
- rdk-model-zoo-releaseSkill
- rdk-model-zoo-repoSkill
- rdk-model-zoo-reviewSkill
- rdk-model-zooSkill
- rdk-model-zoo-validateSkill
- rdk-multimediaSkill
- rdk-network-remoteSkill
- rdk-pack-installerSkill
- rdk-peripheral-cookbookSkill
- rdk-skill-finderSkill
- rdk-source-mapSkill
- rdk-system-configSkill
- rdk-system-maintainSkill
- rdk-tros-setupSkill
- rdk-vision-pipelineSkill
The file
Files
RDK Camera Setup
MIPI / USB 摄像头的检测、接入与出图验证。所有命令与总线号均以 D-Robotics 官方文档
(rdk_x_doc / rdk_s_doc)为准,见 references/ 中的出处标注。
Purpose
帮助用户确认摄像头硬件被正确识别(I2C 地址可探测、V4L2 设备存在),并用官方示例完成 第一帧出图验证,定位"接了摄像头但没图"类问题。
When to use
当用户提出以下问题时激活:
- "MIPI 摄像头接上了怎么验证能不能用?"
- "接了 IMX219 / OV5647 / IMX477,怎么确认接好了?"
- "i2cdetect 扫不到摄像头地址。"
- "USB 摄像头在 RDK 上怎么打开?"
- "运行 mipi_camera 示例黑屏 / 报错。"
不要用本技能修改设备树或驱动——驱动级问题定位后应指引用户查阅官方
07_Advanced_development 文档章节。
Prerequisites
- 摄像头已按官方指引连接(22pin 排线金属面背对黑色卡扣插入连接器)。
- 官方系统镜像自带
/app/pydev_demo示例目录。
Available Scripts
| Script | Purpose | Arguments |
scripts/detect_camera.sh | 按板卡型号扫描对应 I2C 总线并列出 V4L2 设备,输出 JSON 检测结果。 | --json(默认)、--human |
Instructions
- 运行
scripts/detect_camera.sh获取 I2C 与 V4L2 检测结果。 - MIPI 摄像头未探测到时,按
references/camera-verify.md中对应板卡的官方步骤 (X5 需先拉 GPIO 使能再i2cdetect)人工复查。 - 出图验证:
- MIPI:运行官方示例
/app/pydev_demo/08_mipi_camera_sample/02_mipi_camera_dump.py(保存 YUV 文件,无需显示器)。 - USB:确认
/dev/video0存在后运行/app/pydev_demo/07_usb_camera_sample示例。
- MIPI:运行官方示例
- 需要 HDMI 可视化且系统为 Desktop 版时,先执行
sudo systemctl stop lightdm(官方要求),结束后可sudo systemctl start lightdm恢复。
Reporting guidance
- 报告 I2C 探测结果时引用脚本输出的
i2c.detected_addrs;IMX219 的典型地址是0x10。 - 多路摄像头:脚本会扫描板卡全部摄像头总线并列出所有 V4L2 设备;逐总线报告
detected_addrs,明确哪个接口上有 sensor、哪个接口空置,不要只报告第一路。 - 未探测到地址时,按官方 FAQ 的排查顺序报告:排线方向 → 总线号是否对应接口 → 换用官方适配的摄像头型号(IMX219 / OV5647 / IMX477)。
- 不要凭记忆给出总线号;X3 与 X5 不同(见 references),一律以脚本或 references 为准。
Limitations
- 本技能验证到"官方示例能出图"为止;ISP 调参、自定义 sensor 驱动超出范围。
- I2C 扫描需要 root(
sudo i2cdetect);非特权运行时脚本报告i2c.readable: false。
Error handling
i2cdetect命令缺失时提示sudo apt install i2c-tools,不要跳过检测直接跑示例。- 示例运行报 ION/VIO 分配失败时,交接 rdk-memory-audit 检查 ION 内存余量。
- 出图验证通过后,用户想进一步"摄像头实时跑模型看画面"时,交接 rdk-vision-pipeline 走端到端链路。
Output contract for detect_camera.sh
{
"board": "rdk-x5",
"i2c": {
"readable": true,
"buses_scanned": [ 4, 6 ],
"detected_addrs": { "4": [ "0x10" ], "6": [] }
},
"v4l2_devices": [ "/dev/video0" ],
"pydev_demo_present": true
}Safety
只读检测 + 官方示例运行;唯一的系统级操作是 X5 上按官方文档拉摄像头使能 GPIO
(/sys/class/gpio/gpio353|gpio351),以及用户确认后临时停止 lightdm。
Cross-platform behavior
| 板卡 | MIPI 检测总线 | 备注 |
| RDK X3 / X3 Module | i2c-1 / i2c-2 | sudo i2cdetect -y -r 1(官方 FAQ) |
| RDK X5 | i2c-6(mipi_host0,靠网口)/ i2c-4(mipi_host2) | 探测前需按官方步骤拉 GPIO353/GPIO351 使能 |
| RDK S100 / S100P / S600 | i2c-1 / i2c-2(vcon 设备树节点管理 sensor,rdk_s_doc 多媒体开发章节) | 脚本默认扫描 bus 1/2 并如实报告;细节以 rdk_s_doc 为准 |
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

