From 8306838424e4a78110105a35437e8010b4beab00 Mon Sep 17 00:00:00 2001 From: Gunar Schorcht Date: Sun, 30 Jul 2023 00:40:53 +0200 Subject: [PATCH] drivers/lcd: expose lcd_ll_set_area function --- drivers/include/lcd.h | 12 ++++++++++++ drivers/lcd/lcd.c | 3 +-- 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/drivers/include/lcd.h b/drivers/include/lcd.h index 16b53eed6d..605c248fa6 100644 --- a/drivers/include/lcd.h +++ b/drivers/include/lcd.h @@ -279,6 +279,18 @@ void lcd_ll_write_cmd(lcd_t *dev, uint8_t cmd, const uint8_t *data, * @param[in] len length of the returned data */ void lcd_ll_read_cmd(lcd_t *dev, uint8_t cmd, uint8_t *data, size_t len); + +/** + * @brief Set the LCD work area + * + * @param[in] dev Pointer to the selected driver + * @param[in] x1 x coordinate of the first corner + * @param[in] x2 x coordinate of the opposite corner + * @param[in] y1 y coordinate of the first corner + * @param[in] y2 y coordinate of the opposite corner + * + */ +void lcd_ll_set_area(lcd_t *dev, uint16_t x1, uint16_t x2, uint16_t y1, uint16_t y2); /** @} */ /** diff --git a/drivers/lcd/lcd.c b/drivers/lcd/lcd.c index 098c877b5f..b715bf65af 100644 --- a/drivers/lcd/lcd.c +++ b/drivers/lcd/lcd.c @@ -369,8 +369,7 @@ static void lcd_ll_set_area_default(lcd_t *dev, uint16_t x1, uint16_t x2, sizeof(params)); } -static void lcd_ll_set_area(lcd_t *dev, uint16_t x1, uint16_t x2, - uint16_t y1, uint16_t y2) +void lcd_ll_set_area(lcd_t *dev, uint16_t x1, uint16_t x2, uint16_t y1, uint16_t y2) { if (dev->driver->set_area) { dev->driver->set_area(dev, x1, x2, y1, y2);