From b748a7989ea7587ab885b92f74ccb2e08008543c Mon Sep 17 00:00:00 2001 From: iceman1001 Date: Sun, 8 Dec 2019 18:49:26 +0100 Subject: [PATCH] nexwatch textual, wrong endianess --- client/cmddata.c | 8 ++++---- client/cmdlfnexwatch.c | 5 +++-- 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/client/cmddata.c b/client/cmddata.c index d13eee46d..cb78642b2 100644 --- a/client/cmddata.c +++ b/client/cmddata.c @@ -406,7 +406,7 @@ static int CmdSetDebugMode(const char *Cmd) { void printDemodBuff(void) { int len = DemodBufferLen; if (len < 1) { - PrintAndLogEx(NORMAL, "(printDemodBuff) no bits found in demod buffer"); + PrintAndLogEx(INFO, "(printDemodBuff) no bits found in demod buffer"); return; } if (len > 512) len = 512; @@ -458,7 +458,7 @@ int CmdPrintDemodBuff(const char *Cmd) { if (errors) return usage_data_printdemodbuf(); if (DemodBufferLen == 0) { - PrintAndLogEx(NORMAL, "Demodbuffer is empty"); + PrintAndLogEx(WARNING, "Demodbuffer is empty"); return PM3_ESOFT; } if (lstrip) { @@ -491,9 +491,9 @@ int CmdPrintDemodBuff(const char *Cmd) { if (numBits == 0) { return PM3_ESOFT; } - PrintAndLogEx(NORMAL, "DemodBuffer: %s", hex); + PrintAndLogEx(SUCCESS, "DemodBuffer: %s", hex); } else { - PrintAndLogEx(NORMAL, "DemodBuffer:\n%s", sprint_bin_break(DemodBuffer + offset, length, 32)); + PrintAndLogEx(SUCCESS, "DemodBuffer:\n%s", sprint_bin_break(DemodBuffer + offset, length, 32)); } return PM3_SUCCESS; } diff --git a/client/cmdlfnexwatch.c b/client/cmdlfnexwatch.c index 1a204ed41..717bf2587 100644 --- a/client/cmdlfnexwatch.c +++ b/client/cmdlfnexwatch.c @@ -9,6 +9,7 @@ //----------------------------------------------------------------------------- #include "cmdlfnexwatch.h" +#include // PRIu #include // tolower #include "commonutil.h" // ARRAYLEN @@ -80,9 +81,9 @@ static int CmdNexWatchDemod(const char *Cmd) { //checksum check (TBD) //output - PrintAndLogEx(NORMAL, "NexWatch ID: %d", ID); + PrintAndLogEx(SUCCESS, "NexWatch ID: " _YELLOW_("%"PRIu32) , ID); if (invert) { - PrintAndLogEx(NORMAL, "Had to Invert - probably NexKey"); + PrintAndLogEx(INFO, "Had to Invert - probably NexKey"); for (size_t i = 0; i < size; i++) DemodBuffer[i] ^= 1; }