mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2025-08-23 22:55:37 -07:00
4x50_sim: options 'u' and 'f' can not be used at the same time
This commit is contained in:
parent
140037d9f0
commit
236e3f82d8
1 changed files with 8 additions and 2 deletions
|
@ -1041,7 +1041,7 @@ int CmdEM4x50Restore(const char *Cmd) {
|
||||||
|
|
||||||
int CmdEM4x50Sim(const char *Cmd) {
|
int CmdEM4x50Sim(const char *Cmd) {
|
||||||
|
|
||||||
bool errors = false;
|
bool errors = false, word_given = false;;
|
||||||
uint8_t cmdp = 0;
|
uint8_t cmdp = 0;
|
||||||
char filename[FILE_PATH_SIZE] = {0};
|
char filename[FILE_PATH_SIZE] = {0};
|
||||||
|
|
||||||
|
@ -1056,6 +1056,7 @@ int CmdEM4x50Sim(const char *Cmd) {
|
||||||
|
|
||||||
case 'u':
|
case 'u':
|
||||||
etd.word = param_get32ex(Cmd, cmdp + 1, 0, 16);
|
etd.word = param_get32ex(Cmd, cmdp + 1, 0, 16);
|
||||||
|
word_given = true;
|
||||||
cmdp += 2;
|
cmdp += 2;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
@ -1071,9 +1072,14 @@ int CmdEM4x50Sim(const char *Cmd) {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
// validation
|
// validations
|
||||||
if (errors)
|
if (errors)
|
||||||
return usage_lf_em4x50_sim();
|
return usage_lf_em4x50_sim();
|
||||||
|
|
||||||
|
if (word_given && (strlen(filename) != 0)) {
|
||||||
|
PrintAndLogEx(INFO, "Plesae use either option 'u' or option 'f'");
|
||||||
|
return usage_lf_em4x50_sim();
|
||||||
|
}
|
||||||
|
|
||||||
PrintAndLogEx(INFO, "Start simulating");
|
PrintAndLogEx(INFO, "Start simulating");
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue