fix: WITH_EM4x50 and WITH_EM4x70 in lf search

This commit is contained in:
douniwan5788 2024-08-26 21:45:06 +08:00
commit 0f2eaa316b

View file

@ -1553,7 +1553,7 @@ static bool check_chiptype(bool getDeviceData) {
//check for em4x05/em4x69 chips first //check for em4x05/em4x69 chips first
uint32_t word = 0; uint32_t word = 0;
if (em4x05_isblock0(&word)) { if (IfPm3EM4x50() && em4x05_isblock0(&word)) {
PrintAndLogEx(SUCCESS, "Chipset detection: " _GREEN_("EM4x05 / EM4x69")); PrintAndLogEx(SUCCESS, "Chipset detection: " _GREEN_("EM4x05 / EM4x69"));
PrintAndLogEx(HINT, "Hint: try " _YELLOW_("`lf em 4x05`") " commands"); PrintAndLogEx(HINT, "Hint: try " _YELLOW_("`lf em 4x05`") " commands");
retval = true; retval = true;
@ -1570,7 +1570,7 @@ static bool check_chiptype(bool getDeviceData) {
#if !defined ICOPYX #if !defined ICOPYX
// check for em4x50 chips // check for em4x50 chips
if (detect_4x50_block()) { if (IfPm3EM4x50() && detect_4x50_block()) {
PrintAndLogEx(SUCCESS, "Chipset detection: " _GREEN_("EM4x50")); PrintAndLogEx(SUCCESS, "Chipset detection: " _GREEN_("EM4x50"));
PrintAndLogEx(HINT, "Hint: try " _YELLOW_("`lf em 4x50`") " commands"); PrintAndLogEx(HINT, "Hint: try " _YELLOW_("`lf em 4x50`") " commands");
retval = true; retval = true;
@ -1578,7 +1578,7 @@ static bool check_chiptype(bool getDeviceData) {
} }
// check for em4x70 chips // check for em4x70 chips
if (detect_4x70_block()) { if (IfPm3EM4x70() && detect_4x70_block()) {
PrintAndLogEx(SUCCESS, "Chipset detection: " _GREEN_("EM4x70")); PrintAndLogEx(SUCCESS, "Chipset detection: " _GREEN_("EM4x70"));
PrintAndLogEx(HINT, "Hint: try " _YELLOW_("`lf em 4x70`") " commands"); PrintAndLogEx(HINT, "Hint: try " _YELLOW_("`lf em 4x70`") " commands");
retval = true; retval = true;