Skip to content

Commit

Permalink
make all device side HTS messages DBGlevel extended
Browse files Browse the repository at this point in the history
  • Loading branch information
iceman1001 committed Sep 14, 2024
1 parent d715871 commit febaa64
Show file tree
Hide file tree
Showing 4 changed files with 70 additions and 124 deletions.
6 changes: 2 additions & 4 deletions armsrc/hitag2.c
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,6 @@
// See LICENSE.txt for the text of the license.
//-----------------------------------------------------------------------------

#define DBG if (g_dbglevel >= DBG_EXTENDED)

#include "hitag2.h"
#include "hitag2/hitag2_crypto.h"
#include "string.h"
Expand Down Expand Up @@ -2085,7 +2083,7 @@ void WriterHitag(const lf_hitag_data_t *payload, bool ledcontrol) {
// Check configuration
switch (payload->cmd) {
case WHT2F_CRYPTO: {
DbpString("Authenticating using key:");
DBG DbpString("Authenticating using key:");
memcpy(key, payload->key, 6); //HACK; 4 or 6?? I read both in the code.
memcpy(writedata, payload->data, 4);
Dbhexdump(6, key, false);
Expand All @@ -2109,7 +2107,7 @@ void WriterHitag(const lf_hitag_data_t *payload, bool ledcontrol) {
}
break;
default: {
Dbprintf("Error, unknown function: " _RED_("%d"), payload->cmd);
DBG Dbprintf("Error, unknown function: " _RED_("%d"), payload->cmd);
reply_ng(CMD_LF_HITAG2_WRITE, PM3_ESOFT, NULL, 0);
return;
}
Expand Down
Loading

0 comments on commit febaa64

Please sign in to comment.