From 42ec3c7d0998cd61d162ecb0d2e895762c2f18e3 Mon Sep 17 00:00:00 2001 From: Ivan Li Date: Sat, 28 Jan 2023 21:01:47 +0800 Subject: [PATCH] chore: delete some log. --- .vscode/settings.json | 2 +- main/light.c | 1 - main/mqtt.c | 7 +++---- 3 files changed, 4 insertions(+), 6 deletions(-) diff --git a/.vscode/settings.json b/.vscode/settings.json index 818b670..69f7b9d 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -7,7 +7,7 @@ "idf.openOcdConfigs": [ "board/esp32c3-builtin.cfg" ], - "idf.port": "/dev/cu.usbmodem149201", + "idf.port": "/dev/cu.usbserial-14910", "idf.pythonBinPath": "/Users/ivan/.espressif/python_env/idf4.4_py3.8_env/bin/python", "idf.toolsPath": "/Users/ivan/.espressif", "idf.gitPath": "/usr/bin/git", diff --git a/main/light.c b/main/light.c index a1ac85c..fbf548b 100644 --- a/main/light.c +++ b/main/light.c @@ -242,7 +242,6 @@ void light_init_strip() { void light_play_colors(uint16_t len, uint8_t *buffer) { light_mode = light_mode_desktop_sending_colors; - printf("COLORS=%.*s\r\n", len, buffer); for (uint16_t led_index = 0, buffer_cursor = 0; led_index < STRIP_LED_NUMBER && buffer_cursor < len; diff --git a/main/mqtt.c b/main/mqtt.c index 24a34f3..7e44e2a 100644 --- a/main/mqtt.c +++ b/main/mqtt.c @@ -83,14 +83,14 @@ static void mqtt_event_handler(void *handler_args, esp_event_base_t base, ESP_LOGI(MQTT_TAG, "MQTT_EVENT_PUBLISHED, msg_id=%d", event->msg_id); break; case MQTT_EVENT_DATA: - ESP_LOGI(MQTT_TAG, "MQTT_EVENT_DATA"); + // ESP_LOGI(MQTT_TAG, "MQTT_EVENT_DATA"); if (strncmp(event->topic, MQTT_KEY_DESKTOP_ONLINE, event->topic_len) == 0) { xEventGroupSetBits(s_mqtt_event_group, MQTT_DESKTOP_ONLINE_BIT); } else if (strncmp(event->topic, MQTT_KEY_DESKTOP_COLORS, event->topic_len) == 0) { - printf("LEN=%d, DATA=%.*s\r\n", event->data_len, event->data_len, - event->data); + // printf("LEN=%d, DATA=%.*s\r\n", event->data_len, event->data_len, + // event->data); memcpy(mqtt_colors_buffer, event->data, MIN(event->data_len, NUMBER_OF_LEDS * 3)); xEventGroupSetBits(s_mqtt_event_group, @@ -177,7 +177,6 @@ static bool waiting_for_desktop_sending_colors() { } } static bool waiting_and_get_colors() { - ESP_LOGI(MQTT_TAG, "aaa bits: %x", xEventGroupGetBits(s_mqtt_event_group)); EventBits_t bits = xEventGroupWaitBits(s_mqtt_event_group, MQTT_COLORS_STAND_BY_BIT, pdFALSE, pdFALSE, portMAX_DELAY);