//
//-----------------------------------------------------------------------------
-#include "../include/proxmark3.h"
+#include "proxmark3.h"
#include "apps.h"
#include "util.h"
#include "string.h"
// Needed for CRC in emulation mode;
// same construction as in ISO 14443;
// different initial value (CRC_ICLASS)
-#include "../common/iso14443crc.h"
-#include "../common/iso15693tools.h"
-//#include "iso15693tools.h"
+#include "iso14443crc.h"
+#include "iso15693tools.h"
#include "protocols.h"
#include "optimized_cipher.h"
int resp_cc_len;
uint8_t *receivedCmd = BigBuf_malloc(MAX_FRAME_SIZE);
- memset(receivedCmd, 0x44, MAX_FRAME_SIZE);
int len;
// Prepare card messages
}
}
- memset(receivedCmd, 0x44, MAX_FRAME_SIZE);
}
//Dbprintf("%x", cmdsRecvd);
// Reader iClass Anticollission
void ReaderIClass(uint8_t arg0) {
- uint8_t card_data[6 * 8]={0xFF};
+ uint8_t card_data[6 * 8]={0};
+ memset(card_data, 0xFF, sizeof(card_data));
uint8_t last_csn[8]={0};
//Read conf block CRC(0x01) => 0xfa 0x22
int read_status= 0;
uint8_t result_status = 0;
bool abort_after_read = arg0 & FLAG_ICLASS_READER_ONLY_ONCE;
-
+ bool try_once = arg0 & FLAG_ICLASS_READER_ONE_TRY;
set_tracing(TRUE);
setupIclassReader();
+ uint16_t tryCnt=0;
while(!BUTTON_PRESS())
{
-
+ if (try_once && tryCnt > 5) break;
+ tryCnt++;
if(!tracing) {
DbpString("Trace full");
break;