Merge pull request #13 from Sani7/LCD_API

Implement Clear LCD display
This commit is contained in:
2023-11-13 14:40:33 +01:00
2 changed files with 13 additions and 0 deletions

View File

@@ -95,4 +95,13 @@ void lcd_display_text(uint8_t* text, uint16_t x_pos, uint16_t y_pos, uint32_t co
*/ */
void lcd_draw_bmp(const void* p_src, uint32_t x_pos, uint32_t y_pos, uint32_t x_size, uint32_t y_size, uint32_t color_mode); void lcd_draw_bmp(const void* p_src, uint32_t x_pos, uint32_t y_pos, uint32_t x_size, uint32_t y_size, uint32_t color_mode);
/**
* @brief Clear LCD screen
* Clears the whole LCD screen to the desired color
*
*@param[in] color Color to which the LCD should be cleared
*/
void lcd_clear(uint32_t color);
#endif /* INC_LCD_API_H_ */ #endif /* INC_LCD_API_H_ */

View File

@@ -95,3 +95,7 @@ void lcd_draw_bmp(const void* p_src, uint32_t x_pos, uint32_t y_pos, uint32_t x_
LOG_INFO(TAG, "DMA2D poll"); LOG_INFO(TAG, "DMA2D poll");
HAL_DMA2D_PollForTransfer(&hDma2dHandler2, 10); HAL_DMA2D_PollForTransfer(&hDma2dHandler2, 10);
} }
void lcd_clear(uint32_t color){
BSP_LCD_Clear(color);
}