mirror of
https://github.com/HASwitchPlate/openHASP.git
synced 2025-07-27 05:06:44 +00:00
Add HASP_LOG_TASKS
This commit is contained in:
parent
f542195dd6
commit
d5337fe147
@ -1,10 +1,10 @@
|
|||||||
/* MIT License - Copyright (c) 2019-2022 Francis Van Roie
|
/* MIT License - Copyright (c) 2019-2023 Francis Van Roie
|
||||||
For full license information read the LICENSE file in the project folder */
|
For full license information read the LICENSE file in the project folder */
|
||||||
|
|
||||||
#ifndef HASP_TFTESPI_TOUCH_DRIVER_H
|
#ifndef HASP_TFTESPI_TOUCH_DRIVER_H
|
||||||
#define HASP_TFTESPI_TOUCH_DRIVER_H
|
#define HASP_TFTESPI_TOUCH_DRIVER_H
|
||||||
|
|
||||||
#ifdef ARDUINO&& defined(USER_SETUP_LOADED)
|
#ifdef ARDUINO && defined(USER_SETUP_LOADED)
|
||||||
#include <Arduino.h>
|
#include <Arduino.h>
|
||||||
|
|
||||||
#include "touch_driver.h" // base class
|
#include "touch_driver.h" // base class
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
/* MIT License - Copyright (c) 2019-2022 Francis Van Roie
|
/* MIT License - Copyright (c) 2019-2023 Francis Van Roie
|
||||||
For full license information read the LICENSE file in the project folder */
|
For full license information read the LICENSE file in the project folder */
|
||||||
|
|
||||||
#include "hasplib.h"
|
#include "hasplib.h"
|
||||||
@ -364,6 +364,13 @@ static void debugPrintLvglMemory(int level, Print* _logOutput)
|
|||||||
#endif // LV_MEM_CUSTOM
|
#endif // LV_MEM_CUSTOM
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if defined(ESP32) && defined(HASP_LOG_TASKS)
|
||||||
|
static void debugPrintTaskName(int level, Print* _logOutput)
|
||||||
|
{
|
||||||
|
debug_print(_logOutput, "[%s%6u]", pcTaskGetTaskName(NULL), uxTaskGetStackHighWaterMark(NULL));
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
static void debugPrintPriority(int level, Print* _logOutput)
|
static void debugPrintPriority(int level, Print* _logOutput)
|
||||||
{
|
{
|
||||||
switch(level) {
|
switch(level) {
|
||||||
@ -408,6 +415,9 @@ void debugPrintPrefix(uint8_t tag, int level, Print* _logOutput)
|
|||||||
debugPrintTimestamp(level, _logOutput);
|
debugPrintTimestamp(level, _logOutput);
|
||||||
debugPrintHaspMemory(level, _logOutput);
|
debugPrintHaspMemory(level, _logOutput);
|
||||||
debugPrintLvglMemory(level, _logOutput);
|
debugPrintLvglMemory(level, _logOutput);
|
||||||
|
#if defined(ESP32) && defined(HASP_LOG_TASKS)
|
||||||
|
debugPrintTaskName(level, _logOutput);
|
||||||
|
#endif
|
||||||
|
|
||||||
if(tag == TAG_MQTT_PUB && level == LOG_LEVEL_NOTICE) {
|
if(tag == TAG_MQTT_PUB && level == LOG_LEVEL_NOTICE) {
|
||||||
debugSendAnsiCode(F(TERM_COLOR_GREEN), _logOutput);
|
debugSendAnsiCode(F(TERM_COLOR_GREEN), _logOutput);
|
||||||
|
@ -848,7 +848,6 @@ static void webHandleInfoJson()
|
|||||||
{ // Send Content
|
{ // Send Content
|
||||||
String htmldata((char*)0);
|
String htmldata((char*)0);
|
||||||
htmldata.reserve(HTTP_PAGE_SIZE);
|
htmldata.reserve(HTTP_PAGE_SIZE);
|
||||||
StaticJsonDocument<1024> doc;
|
|
||||||
|
|
||||||
htmldata += F("<h1>");
|
htmldata += F("<h1>");
|
||||||
htmldata += haspDevice.get_hostname();
|
htmldata += haspDevice.get_hostname();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user