For Versal AI Edge Series Gen 2 and Versal Prime Series Gen 2 devices, you need to calculate the CSI buffer depth (CSI_BUF_DEPTH) based on the data type to prevent buffer overflow.
Condition to Avoid Buffer Overflow –
(Number of bytes per line buffer) × CSI_BUF_DEPTH > 2 × WC (word
count)
Example
RAW7 : 21 × CSI_BUF_DEPTH > 2 ×
WC
RGB888 : 24*CSI_BUF_DEPTH >
2*WC
Refer the following table for the number of bytes per line buffer calculations.
| Data Type | Bytes in Line Buffer |
|---|---|
| RGB888 | 24 |
| RGB565 | 16 |
| RGB666 | 18 |
| RGB555 | 16 |
| RGB444 | 16 |
| RAW6 | 18 |
| RAW7 | 21 |
| RAW8 | 16 |
| RAW10 | 20 |
| RAW12 | 24 |
| RAW14 | 28 |
| RAW16 | 16 |
| RAW20 | 20 |
| RAW24 | 24 |
| YUV422-8bit | 16 |
| YUV422-10bit | 20 |
| YUV420-8bit | 16 |