mirror of https://github.com/arendst/Tasmota.git
parent
86b6dc7ecb
commit
c2474f8d5d
|
@ -1545,20 +1545,21 @@ void AddLog_Debug(PGM_P formatP, ...)
|
||||||
|
|
||||||
void AddLogBuffer(uint32_t loglevel, uint8_t *buffer, uint32_t count)
|
void AddLogBuffer(uint32_t loglevel, uint8_t *buffer, uint32_t count)
|
||||||
{
|
{
|
||||||
/*
|
|
||||||
snprintf_P(log_data, sizeof(log_data), PSTR("DMP:"));
|
snprintf_P(log_data, sizeof(log_data), PSTR("DMP:"));
|
||||||
for (uint32_t i = 0; i < count; i++) {
|
for (uint32_t i = 0; i < count; i++) {
|
||||||
snprintf_P(log_data, sizeof(log_data), PSTR("%s %02X"), log_data, *(buffer++));
|
snprintf_P(log_data, sizeof(log_data), PSTR("%s %02X"), log_data, *(buffer++));
|
||||||
}
|
}
|
||||||
AddLog(loglevel);
|
AddLog(loglevel);
|
||||||
*/
|
|
||||||
/*
|
/*
|
||||||
strcpy_P(log_data, PSTR("DMP: "));
|
strcpy_P(log_data, PSTR("DMP: "));
|
||||||
ToHex_P(buffer, count, log_data + strlen(log_data), sizeof(log_data) - strlen(log_data), ' ');
|
ToHex_P(buffer, count, log_data + strlen(log_data), sizeof(log_data) - strlen(log_data), ' ');
|
||||||
AddLog(loglevel);
|
AddLog(loglevel);
|
||||||
*/
|
*/
|
||||||
|
/*
|
||||||
char hex_char[count * 3];
|
char hex_char[count * 3];
|
||||||
AddLog_P2(loglevel, PSTR("DMP: %s"), ToHex_P(buffer, count, hex_char, sizeof(hex_char), ' '));
|
AddLog_P2(loglevel, PSTR("DMP: %s"), ToHex_P(buffer, count, hex_char, sizeof(hex_char), ' '));
|
||||||
|
*/
|
||||||
}
|
}
|
||||||
|
|
||||||
void AddLogSerial(uint32_t loglevel)
|
void AddLogSerial(uint32_t loglevel)
|
||||||
|
|
Loading…
Reference in New Issue