lcd_spi_port.h 991 B

123456789101112131415161718192021222324252627282930313233343536373839
  1. /*
  2. * Copyright (c) 2006-2022, RT-Thread Development Team
  3. *
  4. * SPDX-License-Identifier: Apache-2.0
  5. *
  6. * Change Logs:
  7. * Date Author Notes
  8. * 2020-08-10 zylx first version
  9. */
  10. #ifndef __LCD_PORT_H__
  11. #define __LCD_PORT_H__
  12. /* rt-thread 3.5 inch screen, 320 * 480 */
  13. #define LCD_HOR_SCREEN
  14. #define LCD_FULL_COLOR BLACK
  15. #ifndef LCD_FULL_COLOR
  16. #define LCD_FULL_COLOR WHITE
  17. #endif
  18. #ifndef LCD_HOR_SCREEN
  19. #define LCD_WIDTH 320
  20. #define LCD_HEIGHT 480
  21. #else
  22. #define LCD_WIDTH 480
  23. #define LCD_HEIGHT 320
  24. #endif
  25. #define LCD_BITS_PER_PIXEL 24
  26. #define LCD_BYTES_PER_PIXEL (LCD_BITS_PER_PIXEL / 8)
  27. #define LCD_BUF_SIZE (LCD_WIDTH * LCD_HEIGHT * LCD_BYTES_PER_PIXEL)
  28. #define LCD_PIXEL_FORMAT RTGRAPHIC_PIXEL_FORMAT_RGB888
  29. #define LCD_BACKLIGHT_USING_GPIO
  30. #define LCD_BL_PIN GET_PIN(C, 6)
  31. #define LCD_RES_PIN GET_PIN(A, 3)
  32. /* rt-thread 3.5 inch screen, 320 * 480 */
  33. #endif /* __LCD_PORT_H__ */