Pixel Encoding - 2.2 English

MIPI CSI-2 Transmitter Subsystem (PG260)

Document ID
PG260
Release Date
2023-05-16
Version
2.2 English

This section elaborates the pixel encoding and the s_axis_tdata or the vid_pxl port width generation followed by the MIPI CSI-2 TX controller. For more details, refer to AXI4-Stream Video IP and System Design Guide (UG934) [Ref 2] .

The width of the s_axis_tdata or the vid_pxl port is calculated as shown below:

Width of s_axis_tdata/vid_pix Port = Byte aligned of (C_CSI_MAX_BPC*3*Pixel Mode)

For example, C_CSI_MAX_BPC is 14 then data width for 1 Pixel mode will be 14*3*1 resulting in 42. Therefore, the width has to be byte aligned with the final Data Width, which in this case is 48 ([47:0]). For individual data types pixel encoding refer to Table: Pixel Encoding for Single Pixel per Beat with C_CSI_MAX_BPC =14 to Table: Pixel Encoding for Quad Pixel per Beat with C_CSI_MAX_BPC =20 correspondingly,

Table: Pixel Encoding for Single Pixel per Beat with C_CSI_MAX_BPC =14 lists the pixel encoding for single pixel per beat.

Table 2-5: Pixel Encoding for Single Pixel per Beat with C_CSI_MAX_BPC =14

Generic

[12DW-1:

11DW]

[11DW-1:

10DW]

[10DW-1:

9DW]

[9DW-1:

8DW]

[8DW-1:

7DW]

[7DW-1:

6DW]

[6DW-1:

5DW]

[5DW-1:

4DW]

[4DW-1: 3DW]

[3DW-1:

2DW]

[2DW-1: DW]

[DW-1:0]

Boundary

[167:154]

[153:140]

[139:126]

[125:112]

[111:98]

[97:84]

[83:70]

[69:56]

[55:42]

[41:28]

[27:14]

[13:0]

Data Type

RAW8, USD, Embedded non-image data

P0 [13:6]

RAW10

P0 [13:4]

RAW12

P0 [13:2]

RAW14

P0 [13: 0 ]

YUV422-8Bit

U0/V0 [27:20]

Y0/Y1[ 13:6]

RGB888

R0 [41:34]

B0 [27:20]

G0 [13:6]

RGB565

R0 [41:37]

B0 [27:23]

G0 [13:8]

Table 2-6: Pixel Encoding for Single Pixel per Beat with C_CSI_MAX_BPC =20

Generic

[12DW-1:

11DW]

[11DW-1:

10DW]

[10DW-1:

9DW]

[9DW-1:

8DW]

[8DW-1:

7DW]

[7DW-1:

6DW]

[6DW-1:

5DW]

[5DW-1:

4DW]

[4DW-1: 3DW]

[3DW-1:

2DW]

[2DW-1: DW]

[DW-1:0]

Boundary

[239:220]

[219:200]

[199:180]

[179:160]

[159:140]

[139:120]

[119:100]

[99:80]

[79:60]

[59:40]

[39:20]

[19:0]

Data Type

RAW8

P0 [19:12]

RAW10

P0 [19:10]

RAW12

P0 [19:8]

RAW14

P0 [19:6]

YUV422-8Bit

U0/V0 [39:32]

Y0/Y1 [19:12]

YUV 422-10 Bit

U0/V0 [39:30]

Y0/Y1 [19:10]

RGB888

R0 [59:52]

B0 [39:32]

G0 [19:12]

RGB565

R0 [59:55]

B0 [39:35]

G0 [19:14]

RAW16

P0 [19:4]

RAW20

P0 [19:0]

Table 2-7: Pixel Encoding for Dual Pixel per Beatwith C_CSI_MAX_BPC =14

Generic

[12DW-1:

11DW]

[11DW-1:

10DW]

[10DW-1:

9DW]

[9DW-1:

8DW]

[8DW-1:

7DW]

[7DW-1:

6DW]

[6DW-1:

5DW]

[5DW-1:

4DW]

[4DW-1: 3DW]

[3DW-1:

2DW]

[2DW-1: DW]

[DW-1:0]

Boundary

[167:154]

[153:140]

[139:126]

[125:112]

[111:98]

[97:84]

[83:70]

[69:56]

[55:42]

[41:28]

[27:14]

[13:0]

Data Type

RAW8, USD, Embedded non-image data

P1 [27:20]

P0 [13:6]

RAW10

P1 [27:18]

P0 [13:4]

RAW12

P1 [27:16]

P0 [13:2]

RAW14

P1 [27:14]

P0 [13:0]

YUV422-8Bit

V0 [55:48]

Y1 [41:34]

U0 [27:20]

Y0 [13:6]

RGB888

R1 [83:76]

B1 [69:62]

G1 [55:48]

R0 [41:34]

B0 [27:20]

G0 [13:6]

RGB565

R1 [83:79]

B1 [69:65]

G1 [55:50]

R0 [41:37]

B0 [27:23]

G0 [13:8]

Table: Pixel Encoding for Dual Pixel per Beatwith C_CSI_MAX_BPC =14 lists the pixel encoding for dual pixel per beat.

Table 2-8: Pixel Encoding for Dual Pixel per Beat with C_CSI_MAX_BPC=20

Generic

[12DW-1:

11DW]

[11DW-1:

10DW]

[10DW-1:

9DW]

[9DW-1:

8DW]

[8DW-1:

7DW]

[7DW-1:

6DW]

[6DW-1:

5DW]

[5DW-1:

4DW]

[4DW-1: 3DW]

[3DW-1:

2DW]

[2DW-1: DW]

[DW-1:0]

Boundary

[239:220]

[219:200]

[199:180]

[179:160]

[159:140]

[139:120]

[119:100]

[99:80]

[79:60]

[59:40]

[39:20]

[19:0]

Data Type

RAW8

P1 [39:32]

P0 [19:12]

RAW10

P1 [39:30]

P0 [19:10]

RAW12

P1 [39:28]

P0 [19:8]

RAW14

P1 [39:26]

P0 [19:6]

YUV422-8Bit

V0 [79:72]

Y1 [59:52]

U0 [39:32]

Y0 [19:12]

YUV 422-10 Bit

V0 [79:70]

Y1 [59:50]

U0 [39:30]

Y0 [19:10]

RGB888

R1 [119:112]

B1 [99:92]

G1 [79:72]

R0 [59:52]

B0 [39:32]

G0 [19:12]

RGB565

R1 [119:115]

B1 [99:95]

G1 [79:74]

R0 [59:55]

B0 [39:35]

G0 [19:14]

RAW16

P1 [39:24]

P0 [19:4]

RAW20

P1 [39:20]

P0 [19:0]

Table: Pixel encoding for Quad Pixel per Beat with C_CSI_MAX_BPC =14 lists the pixel encoding for quad pixel per beat.

Table 2-9: Pixel encoding for Quad Pixel per Beat with C_CSI_MAX_BPC =14

Generic

[12DW-1:

11DW]

[11DW-1:

10DW]

[10DW-1:

9DW]

[9DW-1:

8DW]

[8DW-1:

7DW]

[7DW-1:

6DW]

[6DW-1:

5DW]

[5DW-1:

4DW]

[4DW-1: 3DW]

[3DW-1:

2DW]

[2DW-1: DW]

[DW-1:0]

Boundary

[167:154]

[153:140]

[139:126]

[125:112]

[111:98]

[97:84]

[83:70]

[69:56]

[55:42]

[41:28]

[27:14]

[13:0]

Data Type

RAW8, USD, Embedded non-image data

P3 [55:48]

P2 [41:34]

P1 [27:20]

P0 [13:6]

RAW10

P3 [55:46]

P2 [41:32]

P1 [27:18]

P0 [13:4]

RAW12

P3 [55:44]

P2 [41:30]

P1 [27:16]

P0 [13:2]

RAW14

P3 [55:42]

P2 [41:28]

P1 [27:14]

P0 [13:0]

YUV422-8Bit

V2 [111:104]

Y3 [97:90]

U2 [83:76]

Y2 [69:62]

V0 [55:48]

Y1 [41:34]

U0 [27:20]

Y0 [13:6]

RGB888

R3 [167:160]

B3 [153:146]

G3 [139:132]

R2 [125:118]

B2 [111:104]

G2 [97:90]

R1 [83:76]

B1 [69:62]

G1 [55:48]

R0 [41:34]

B0 [27:20]

G0 [13:6]

RGB565

R3 [167:163]

B3 [153:149]

G3 [139:134]

R2 [125:121]

B2 [111:107]

G2 [97:92]

R1 [83:79]

B1 [69:65]

G1 [55:50]

R0 [41:37]

B0 [27:23]

G0 [13:8]

Table 2-10: Pixel Encoding for Quad Pixel per Beat with C_CSI_MAX_BPC =20

Generic

[12DW-1:

11DW]

[11DW-1:

10DW]

[10DW-1:

9DW]

[9DW-1:

8DW]

[8DW-1:

7DW]

[7DW-1:

6DW]

[6DW-1:

5DW]

[5DW-1:

4DW]

[4DW-1: 3DW]

[3DW-1:

2DW]

[2DW-1: DW]

[DW-1:0]

Boundary

[239:220]

[219:200]

[199:180]

[179:160]

[159:140]

[139:120]

[119:100]

[99:80]

[79:60]

[59:40]

[39:20]

[19:0]

Data Type

RAW8

P3 [79:72]

P2 [59:52]

P1 [39:32]

P0 [19:12]

RAW10

P3 [79:70]

P2 [59:50]

P1 [39:30]

P0 [19:10]

RAW12

P3 [79:68]

P2 [59:48]

P1 [39:28]

P0 [19:8]

RAW14

P3 [79:66]

P2 [59:46]

P1 [39:26]

P0 [19:6]

YUV422-8Bit

V2 [159:152]

Y3 [139:132]

U2 [119:110]

Y2 [99:92]

V0 [79:72]

Y1 [59:52]

U0 [39:32]

Y0 [19:12]

YUV 422-10 Bit

V2 [159:150]

Y3 [139:130]

U2 [119:110]

Y2 [99:90]

V0 [79:70]

Y1 [59:50]

U0 [39:30]

Y0 [19:10]

RGB888

R3 [239:232]

B3 [219:212]

G3 [199:192]

R2 [179:172]

B2 [159:152]

G2 [139:132]

R1 [119:112]

B1 [99:92]

G1 [79:72]

R0 [59:52]

B0 [39:32]

G0 [19:12]

RGB565

R3 [239:235]

B3 [219:215]

G3 [199:194]

R2 [179:175]

B2 [159:155]

G2 [139:134]

R1 [119:115]

B1 [99:95]

G1 [79:74]

R0 [59:55]

B0 [39:35]

G0 [19:14]

RAW16

P3 [79:64]

P2 [59:44]

P1 [39:24]

P0 [19:4]

RAW20

P3 [79:70]

P2 [59:50]

P1 [39:20]

P0 [19:0]