From 6a76078ba83b89e2c6655dfad41c84260479da6e Mon Sep 17 00:00:00 2001 From: C47D Date: Wed, 13 Oct 2021 22:53:00 -0500 Subject: [PATCH] ili9481: Fix TAG --- lvgl_tft/GC9A01.c | 8 ++++---- lvgl_tft/ili9481.c | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/lvgl_tft/GC9A01.c b/lvgl_tft/GC9A01.c index bb6741b..8ec916d 100644 --- a/lvgl_tft/GC9A01.c +++ b/lvgl_tft/GC9A01.c @@ -16,7 +16,7 @@ /********************* * DEFINES *********************/ - #define TAG "GC9A01" + #define TAG "GC9A01: " /********************** * TYPEDEFS @@ -126,7 +126,7 @@ void GC9A01_init(void) vTaskDelay(100 / portTICK_RATE_MS); #endif - ESP_LOGI(TAG, "Initialization."); + LV_LOG_INFO(TAG "Initialization."); //Send all the commands uint16_t cmd = 0; @@ -226,7 +226,7 @@ static void GC9A01_set_orientation(uint8_t orientation) "PORTRAIT", "PORTRAIT_INVERTED", "LANDSCAPE", "LANDSCAPE_INVERTED" }; - ESP_LOGI(TAG, "Display orientation: %s", orientation_str[orientation]); + LV_LOG_INFO(TAG "Display orientation: %s", orientation_str[orientation]); #if defined CONFIG_LV_PREDEFINED_DISPLAY_M5STACK const uint8_t data[] = {0x68, 0x68, 0x08, 0x08}; @@ -236,7 +236,7 @@ static void GC9A01_set_orientation(uint8_t orientation) const uint8_t data[] = {0x08, 0xC8, 0x68, 0xA8}; #endif - ESP_LOGD(TAG, "0x36 command value: 0x%02X", data[orientation]); + LV_LOG_INFO(TAG "0x36 command value: 0x%02X", data[orientation]); GC9A01_send_cmd(0x36); GC9A01_send_data((void *) &data[orientation], 1); diff --git a/lvgl_tft/ili9481.c b/lvgl_tft/ili9481.c index 3e22f39..c587c2b 100644 --- a/lvgl_tft/ili9481.c +++ b/lvgl_tft/ili9481.c @@ -15,7 +15,7 @@ /********************* * DEFINES *********************/ - #define TAG "ILI9481" + #define TAG "ILI9481: " /********************** * TYPEDEFS @@ -86,7 +86,7 @@ void ili9481_init(void) vTaskDelay(100 / portTICK_RATE_MS); #endif - LV_LOG_INFO("TAG" ": Initialization."); + LV_LOG_INFO(TAG "Initialization."); // Exit sleep ili9481_send_cmd(0x01); /* Software reset */ @@ -115,7 +115,7 @@ void ili9481_flush(lv_disp_drv_t * drv, const lv_area_t * area, lv_color_t * col uint8_t *mybuf; do { mybuf = (uint8_t *) heap_caps_malloc(3 * size * sizeof(uint8_t), MALLOC_CAP_DMA); - if (mybuf == NULL) LV_LOG_WARN("TAG" ": Could not allocate enough DMA memory!"); + if (mybuf == NULL) LV_LOG_WARN(TAG "Could not allocate enough DMA memory!"); } while (mybuf == NULL); uint32_t LD = 0; @@ -194,7 +194,7 @@ static void ili9481_set_orientation(uint8_t orientation) "PORTRAIT", "PORTRAIT_INVERTED", "LANDSCAPE", "LANDSCAPE_INVERTED" }; - LV_LOG_INFO("TAG" ": Display orientation: %s", orientation_str[orientation]); + LV_LOG_INFO(TAG "Display orientation: %s", orientation_str[orientation]); uint8_t data[] = {0x48, 0x4B, 0x28, 0x2B}; ili9481_send_cmd(ILI9481_CMD_MEMORY_ACCESS_CONTROL);