MIPI CSI-2 Camera Bring-up
Scope
This application note covers bringing up a MIPI CSI-2 camera on the on-EVK CSI connector: configuring the on-module per-camera LDO, validating the lane routing, and reading the first frame through the SDK's <alp/camera.h> API.
Table: Scope summary
| Field | Detail |
|---|---|
| Audience | Firmware engineers integrating a camera sensor into vision workloads. |
| Prerequisites | QS- guide completed, RPi-compatible MIPI camera module (e.g. RPi V2 or HQ camera). |
| Outcome | ai-camera-viewer running, streaming live frames to the display. |
| Time | 20 minutes. |
| Source | examples/camera-vision/ai-camera-viewer/ in alp-sdk. |
Hardware Setup
Table: MIPI CSI-2 camera support per family
| SoM family | CSI interfaces + LDO |
|---|---|
| E1M-AEN | 1 × 2-lane CSI (CSI0). On-die Alif Ensemble ISP-Pico (VeriSilicon ISP Nano Pico, DT compatible vsi,isp-pico) on E4 / E6 / E8 (not on E3 / E5 / E7). Per-camera LDO: +V_CAM0 (Z34) + CAM_VFB0 (Z33) divider. |
| E1M-X V2N / V2N-M1 | 2 × 4-lane CSI (CSI0, CSI1). On-module ISP. Per-camera LDOs: +V_CAM0…+V_CAM3 with matching CAM_VFBx feedback divider. |
Place the feedback resistor pair (R1, R2) close to the SoM CAM_VFBx pin; long feedback traces invite oscillation. The output voltage is set by:
VCAM = 0.6 V × (1 + R1 / R2)
Software Walkthrough
west build -b <BOARD> examples/camera-vision/ai-camera-viewer
west flash
The example brings up CSI0, energises the per-camera LDO, opens an OV5640 stream at 240 × 240 RGB565 via alp_camera_open(), and renders the live preview to the display.
Expected Output
[cam] LDO0 -> 2.8 V (target 2.8 V, divider 220k/82k)
[cam] CSI0 link up, 2 lanes @ TBD Mbps
[cam] streaming 240x240 RGB565 @ 30 fps
Troubleshooting
- LDO voltage off: divider current too low; reduce
R1 + R2until divider current = 100 × worst-case feedback-pin current (see DS-AEN-001 §7.8 formula). - No CSI link: differential lanes swapped (P/N reversed) or trace impedance not 100 Ω differential.
- Lane skew errors: lane-to-lane length mismatch > TBD ps.
References
- Example source:
examples/camera-vision/ai-camera-viewer/in alp-sdk; API ininclude/alp/camera.h. Silicon bring-up reg-checks:examples/aen/aen-camera-regcheck/,examples/aen/aen-isp-regcheck/. - Hardware Design Guides: HG-AEN-001 §5.5, HG-V2N-001 §6.4 (MIPI CSI-2 routing rules).
- Datasheet CSI-2 pin tables: §2.3 in each datasheet.
Revision History
Table: Revision History
| Revision | Changes | Date |
|---|---|---|
| 0.1 | Initial draft. | May 2026 |
| 0.2 | Updated SDK references to current layout: example path examples/camera-vision/ai-camera-viewer/, added include/alp/camera.h and the aen-camera-regcheck / aen-isp-regcheck reg-checks; corrected the AEN on-die ISP to the Alif Ensemble ISP-Pico (vsi,isp-pico); aligned the stream config with the example (240×240 RGB565). | June 2026 |
Questions about this page? Discuss in Community Forum