Hello @JLi.21 and welcome to the Community :)
All devices that contain LTDC feature, support RGB222 mode.
The LTDC always outputs RGB888 formats, then each format is available as long as the corresponding AFs availability: i.e. RGB222 mode is available as soon the package included the alternate R7, G7, B7, R6, G6 and B6.
Also, the RGB565 mode is available as soon the package included the alternate R[7:3] G[7:2] B[7:3].
For RGB666 the AFs should be available are R[7:2] G[7:2] B[7:2].
I advise you to use STM32CubeMX tool to configure the LTDC peripheral and use RGB222 mode.
Have a look at this AN4861 Application note LCD-TFT display controller (LTDC) on STM32 MCUs, which describes the LCD-TFT display controller of the STM32 MCUs and demonstrates how to use and configure the LTDC peripheral.
Hope my answer helped you!
When your question is answered, please close this topic by choosing Select as Best.
Imen