add OPENTHREAD_CONFIG_LOG_PKT_DUMP (#1109)

This commit is contained in:
Marcin K Szczodrak
2017-01-04 14:55:45 -08:00
committed by Jonathan Hui
parent d61b878d34
commit a360f2e46e
2 changed files with 14 additions and 0 deletions
+4
View File
@@ -50,6 +50,7 @@
extern "C" {
#endif
#if OPENTHREAD_CONFIG_LOG_PKT_DUMP == 1
/**
* This static method outputs a line of the memory dump.
*
@@ -148,6 +149,9 @@ void otDump(otLogLevel aLogLevel, otLogRegion aLogRegion, const char *aId, const
otLogDump("%s", buf);
}
#else
void otDump(otLogLevel, otLogRegion, const char *, const void *, const size_t) {}
#endif
#ifdef OPENTHREAD_CONFIG_LOG_PREPEND_LEVEL
const char *otLogLevelToString(otLogLevel aLevel)
+10
View File
@@ -389,6 +389,16 @@
#define OPENTHREAD_CONFIG_LOG_MEM 1
#endif // OPENTHREAD_CONFIG_LOG_MEM
/**
* @def OPENTHREAD_CONFIG_LOG_PKT_DUMP
*
* Define to enable log content of packets.
*
*/
#ifndef OPENTHREAD_CONFIG_LOG_PKT_DUMP
#define OPENTHREAD_CONFIG_LOG_PKT_DUMP 1
#endif // OPENTHREAD_CONFIG_LOG_PKT_DUMP
/**
* @def OPENTHREAD_CONFIG_LOG_NETDIAG
*