MFsim: RATS_IN_DATA was not a proper bit flag

This commit is contained in:
Philippe Teuwen 2024-10-16 15:24:01 +02:00
commit 5b7ba3bf50
3 changed files with 3 additions and 3 deletions

View file

@ -1256,7 +1256,7 @@ bool SimulateIso14443aInit(uint8_t tagType, uint16_t flags, uint8_t *data, uint8
}
// copy the iRATs if supplied
if ((flags & RATS_IN_DATA) == RATS_IN_DATA) {
if ((flags & FLAG_RATS_IN_DATA) == FLAG_RATS_IN_DATA) {
memcpy(rRATS, iRATs, sizeof(iRATs));
// rats len is dictated by the first char of the string, add 2 crc bytes
rRATS_len = (iRATs[0] + 2);

View file

@ -3745,7 +3745,7 @@ int CmdHF14AAIDSim(const char *Cmd) {
}
if (rats_len > 0) {
flags |= RATS_IN_DATA;
flags |= FLAG_RATS_IN_DATA;
}

View file

@ -779,7 +779,7 @@ typedef struct {
#define FLAG_FORCED_ATQA 0x800
#define FLAG_FORCED_SAK 0x1000
#define FLAG_CVE21_0430 0x2000
#define RATS_IN_DATA 0x3000
#define FLAG_RATS_IN_DATA 0x4000
#define MODE_SIM_CSN 0