Remove carriage return \r for better debug.

Signed-off-by: Pol Henarejos <pol.henarejos@cttc.es>
This commit is contained in:
Pol Henarejos
2024-04-10 18:16:38 +02:00
parent 6adfe4344f
commit 7def35f87c
8 changed files with 25 additions and 29 deletions

View File

@@ -43,7 +43,7 @@ typedef struct cmd {
#if defined(DEBUG_APDU) && DEBUG_APDU == 1
#define DEBUG_PAYLOAD(_p, _s) { \
printf("Payload %s (%d bytes):\r\n", #_p, (int) (_s)); \
printf("Payload %s (%d bytes):\n", #_p, (int) (_s)); \
for (int _i = 0; _i < _s; _i += 16) { \
printf("%" PRIxPTR "h : ", (uintptr_t) (_i + _p)); \
for (int _j = 0; _j < 16; _j++) { \
@@ -56,12 +56,12 @@ typedef struct cmd {
else printf(" "); \
if (_j == 7) printf(" "); \
} \
printf("\r\n"); \
} printf("\r\n"); \
printf("\n"); \
} printf("\n"); \
}
#define DEBUG_DATA(_p, _s) \
{ \
printf("Data %s (%d bytes):\r\n", #_p, (int) (_s)); \
printf("Data %s (%d bytes):\n", #_p, (int) (_s)); \
char *tmp = (char *) calloc(1, 2 * _s + 1); \
for (int _i = 0; _i < _s; _i++) \
{ \