MIPI is the most mainstream video transmission interface specification in the mobile field. The most widely used are the MIPI DPHY and MIPI CPHY protocol families (there is also MIPI MPHY, which belongs to the high-speed Serdes category and is not as widely used). Among them, CSI-2 is mainly used for image input (generally connected to sensors), and DSI-2 is mainly used for image output (generally output to displays). Let’s first look at the physical layer protocol.
MIPI DPHY Specifications
MIPI DPHY Architecture
MIPI DPHY Timing
Since DPHY exists, why choose the more complex physical layer CPHY? Everything is to increase bandwidth.
MIPI CPHY Specifications
MIPI CPHY Architecture
Comparison of MIPI DPHY and CPHY Physical Layer Timing
DPHY is a source-synchronous system with a dedicated synchronization clock channel, but CPHY does not have a synchronization clock; the clock is embedded in the data. Clearly, the purpose of embedding the clock is to increase bandwidth, which will certainly involve encoding, and the structure of the physical layer must be completely different. From the line perspective, CPHY is a three-line system A/B/C.
The physical layer of MIPI DPHY has a pair of clocks, several pairs of data, and the receiver samples data based on the clock edge, finds the 0xB8 synchronization header, and the physical layer implementation is considered ok. However, MIPI CPHY is different because it does not transmit a clock; it must first recover the clock using CDR, then sample the data with the recovered clock and find the synchronization header, and finally decode the data to recover the initially sent content (the sending process is the opposite).
CPHY “Line State” Variation Diagram
CPHY Interface Equivalent Circuit DiagramCPHY physical link (A/B/C lines) transmits different levels. Through the level operations of A-B, B-C, and C-A, six different line states +x, -x, +y, -y, +z, -z are recovered. The encoding symbols are recovered through the rotation direction, phase, and polarity of the previous and subsequent line states, and then 16-bit data is decoded from seven consecutive symbols. The entire process is shown in the diagram below.
The overall encoding principles can be clearly seen from the diagram below:
Why choose this more complex physical layer than DPHY? Everything is to increase bandwidth. If a certain line state has five different changes, then each symbol (A, B, C, a total of 3 bits) can encode data as log2(5)=2.3219 bits/symbol, and the theoretical bandwidth is 2.3219 times that of DPHY. Every 16-bit data is encoded into seven symbols, making the bandwidth advantage obvious.
In summary, the comparison between DPHY and CPHY is as follows:
After discussing the physical layer, let’s look at the CSI-2 layer:
DPHY organizes data by Byte; CPHY organizes data by 16-bit Word;
The header information of short and long frames in DPHY is organized in the same way as the data; CPHY has a fixed header information of 6×16-bit per channel (short frame information), as shown in the diagram below.