40. Camera subsystem

40.1 Introduction

The camera subsystem is built around a double path:

When plugging a camera sensor, it is recommended to use the DCMIPP that supports more features and provides higher throughput than the DCMI.

The DCMI is recommended only in two noticeable cases:

Note: The DCMIPP inputs pixels from one sensor via the CSI-2 interface, while the DCMI gets pixels from the second sensor via the parallel interface.

The DCMI path offers the following summarized maximum features:

The DCMIPP path offers the following summarized maximum features:

Some over-target use cases are possible, but with specific constraints:

40.2 Camera path main features

40.2.1 DCMI path main features

The DCMI path shows the following features:

See Section 41: Digital camera interface (DCMI) for more details.

40.2.2 DCMIPP path main features

The DCMIPP path groups the DCMIPP pixel pipeline block, its included parallel interface, and the abutted CSI-2-Host and PHY.

The parallel interface shows the following features:

See Section 42: Digital camera interface pixel pipeline (DCMIPP) for more details.

The CSI-2 serial interface shows the following features:

See Section 43: CSI-2 Host (CSI) for more details.

DCMIPP sizings and limitations

The DCMIPP provides three different pipes to process data:

DCMIPP ISP capabilities common to pipe1 and 2, are the following:

The DCMIPP application capabilities, replicated for pipe1 and 2, are listed below:

Output pixel format:

The full features are detailed in Section 41: Digital camera interface (DCMI).

40.3 Camera subsystem implementation

40.3.1 Hardware settings

The camera subsystem is implemented with the following specific settings:

40.4 Camera subsystem functional description

40.4.1 Camera subsystem block diagram

The figure below shows the involved blocks in the camera subsystem.

Figure 333. Camera subsystem block diagram

Block diagram of the Camera subsystem showing internal components (DCMI, PSSI, DCMIPP, CSI_Host, CSI2-DPHY) and external interfaces (Parallel GPIO, LowRes // Sensor, LowPerf // Device, HighRes // Sensor, HighRes CSI Sensor).

The diagram illustrates the Camera subsystem architecture. The subsystem is enclosed in a dashed box and contains several internal blocks: DCMI (with AHB-S32b and 14b// interfaces), PSSI (with AHB-S32b and 16b// interfaces), DCMIPP (with AXI-M64b and AHB-S32b interfaces), CSI_Host (with csi_pck and byte interfaces), and CSI2-DPHY (2DL+1CL) (with byte and csi_bit interfaces). External interfaces are shown on the right, categorized into an 'Exclusive parallel interface' (LowRes // Sensor, LowPerf // Device, HighRes // Sensor) and an 'Exclusive HighRes Sensor: Parallel vs CSI Sensor' (HighRes CSI Sensor). Data paths are indicated by arrows, showing connections between the subsystem blocks and the external sensors. For example, the Parallel GPIO (16 bits) connects to the PSSI and DCMIPP. The HighRes CSI Sensor connects to the CSI2-DPHY, which then connects to the CSI_Host and DCMIPP.

Block diagram of the Camera subsystem showing internal components (DCMI, PSSI, DCMIPP, CSI_Host, CSI2-DPHY) and external interfaces (Parallel GPIO, LowRes // Sensor, LowPerf // Device, HighRes // Sensor, HighRes CSI Sensor).

Note: The PSSI is not used for camera purpose but rather for general-purpose parallel input (not described in this section).

40.4.2 Camera subsystem pins and external signal interface

Details about the pins can be found in the respective block sections.

40.4.3 Camera subsystem reset and clocks

The clock diagram of the camera subsystem is shown in the figure below.

Figure 334. Camera subsystem clock diagram

Figure 334: Camera subsystem clock diagram. The diagram shows the clocking architecture for the camera subsystem. It includes three main blocks: DCMI, DCMIPP, and CSI2-DPHY. DCMI receives ck_icn_p_cci and outputs hclk_cci and pixck_pdck_cci. DCMIPP receives ck_icn_p_dcmipp, ck_icn_m_dcmipp, and ck_ker_csi2, and outputs pclk, aclk, and clk_proc. CSI2-DPHY receives ck_ker_csi2_txesc, ck_ker_csi2, and ck_ker_csiphy, and outputs i_TxClkEsc, io_Cn, io_Cp, and i_cfg_clk. The diagram also shows the connections between these blocks and the external clock sources.

The diagram illustrates the clocking architecture of the camera subsystem. It features three primary blocks: DCMI, DCMIPP, and CSI2-DPHY. DCMI is connected to the external clock source ck_icn_p_cci and outputs hclk_cci and pixck_pdck_cci. DCMIPP is connected to ck_icn_p_dcmipp, ck_icn_m_dcmipp, and ck_ker_csi2, and outputs pclk, aclk, and clk_proc. CSI2-DPHY is connected to ck_ker_csi2_txesc, ck_ker_csi2, and ck_ker_csiphy, and outputs i_TxClkEsc, io_Cn, io_Cp, and i_cfg_clk. The diagram also shows the connections between these blocks and the external clock sources.

Figure 334: Camera subsystem clock diagram. The diagram shows the clocking architecture for the camera subsystem. It includes three main blocks: DCMI, DCMIPP, and CSI2-DPHY. DCMI receives ck_icn_p_cci and outputs hclk_cci and pixck_pdck_cci. DCMIPP receives ck_icn_p_dcmipp, ck_icn_m_dcmipp, and ck_ker_csi2, and outputs pclk, aclk, and clk_proc. CSI2-DPHY receives ck_ker_csi2_txesc, ck_ker_csi2, and ck_ker_csiphy, and outputs i_TxClkEsc, io_Cn, io_Cp, and i_cfg_clk. The diagram also shows the connections between these blocks and the external clock sources.

The above camera subsystem has been implemented with the following clock max frequencies:

40.4.4 Camera subsystem security

The security of the camera subsystem is based on the protection of its register map, and of its master access to the system interconnect, based on default RISUP and RIMU respectively.

More information can be found in Section 5.4: Resource isolation framework (RIF).

The RISUP differentiates the access right of accesses performed toward the following RIF protected peripheral ID (indexes refer to Table 38: Indexes for non-RIF-aware peripherals (RISUP)):

The RIMU (RIMU_AXI_DCMIPP) gives the access right to the DCMIPP AXI master:

By default, the camera subsystem is expected to work in a non-secure mode:

For secure applications, the user can put the camera subsystem in S, P, or S-and-P mode, with the following impacts:

The above recommended non-protected settings are shown in Table 359: Camera subsystem RIF peripheral ID.

The table below lists vertically all camera subsystem blocks, and horizontally the associated RIF peripheral ID.

Table color legend for the recommended settings: gray for a permanently non-protected setting, blue for a temporarily protected versus non-protected, and pink for a permanently protected state: by default, all the settings are non-protected.

Table 359. Camera subsystem RIF peripheral ID

SubsystemBlockAddress rangeStart addressRISUP - slave
888786
DCMI_PSSIDCMIPPCSI2H
Camera low resolutionDCMIConfiguration0x0000Y--
Pixel Rx0x0A00Y--
Configuration0x0B00Y--
Data in/out0x0C00Y--

Table 359. Camera subsystem RIF peripheral ID (continued)

SubsystemBlockAddress rangeStart addressRISUP - slave
888786
DCMI_PSSIDCMIPPCSI2H
Camera high resolutionDCMIPPCommon configuration0x0-Y-
P1 configuration0x0-Y-
P2 configuration0x0-Y-
P3 configuration0x0-Y-
CSIConfiguration control0x0000--Y
Configuration wrap0x1000--Y
CSI DPHY-Rx (no register)----

40.5 Camera subsystem programmable parameters

This section describes the configuration of the various main use cases supported by the camera subsystem. Its purpose is to provide the settings that are global to the camera subsystem, and not provided by the local relevant blocks.

The use cases supported by default are the following:

Some over-target use cases are possible, but with specific constraints:

The limiting factors are

To cope with these limitations, the decimation can be used, ahead of the pipes, to reduce the width and/or height of the frame, and/or deactivate the limiting operators, the demosaicing, downsize, YUV420.

40.5.1 Low-resolution parallel camera and DCMI

This use case is recommended only for backward compatibility, or to grab pictures simultaneously from two sensors (a low and a high resolution).

The steps to setup this path are the following:

40.5.2 High-resolution parallel camera and DCMIPP

This is the default use case to grab a picture from a parallel camera (up to the target 5 Mpixels @30fps). Any RGB or RawBayer picture can be grabbed.

The steps to setup this path are the following:

40.5.3 High-resolution CSI2 camera and DCMIPP

This is the default use-case to grab a picture from a CSI2 camera (up to the target 5 Mpixels @30 fps). Any RGB or RawBayer picture can be grabbed.

The steps to setup this path are the following:

40.5.4 Sensors over target resolution

The sensors over the target resolution (5 Mpixels) are supported with the following restrictions:

After taking into account these restrictions, the configuration itself is the same as for the default high-resolution CSI2 camera, described in previous section.

40.5.5 Sensors over target pixel rate

The sensors over the target pixel rate (150 Mpixel/s average, ~200 Mpixel/s peak) are supported with the following restrictions:

After taking into account these restrictions, the configuration itself is the same as for the default high-resolution CSI2 camera, described in Section 40.5.3.

40.5.6 Double sensors

Two sensors are simultaneously and independently supported with the following restriction:

The configuration of the double sensors is the same as for the default low-resolution and default high-resolution sensors, described in previous sections.

40.6 Camera subsystem interrupts

Sections for each peripheral describe in details the provided interrupts.

40.7 Camera subsystem registers

All the registers are described in sections for each peripheral.