Просмотр исходного кода

ST25TB type is not handled (#1679)

We search for ST25TB type cards, but not handling them being found.
As a result, such cards are detected as NFC-A with 8-byte UID, which lead
to read error on emulation attempt.

Co-authored-by: gornekich <n.gorbadey@gmail.com>
Max Lapan 3 лет назад
Родитель
Сommit
4fcb90928c
1 измененных файлов с 3 добавлено и 1 удалено
  1. 3 1
      firmware/targets/f7/furi_hal/furi_hal_nfc.c

+ 3 - 1
firmware/targets/f7/furi_hal/furi_hal_nfc.c

@@ -124,7 +124,9 @@ bool furi_hal_nfc_detect(FuriHalNfcDevData* nfc_data, uint32_t timeout) {
             }
             nfc_data->cuid = (cuid_start[0] << 24) | (cuid_start[1] << 16) | (cuid_start[2] << 8) |
                              (cuid_start[3]);
-        } else if(dev_list[0].type == RFAL_NFC_LISTEN_TYPE_NFCB) {
+        } else if(dev_list[0].type == RFAL_NFC_LISTEN_TYPE_NFCB ||
+                  dev_list[0].type == RFAL_NFC_LISTEN_TYPE_ST25TB)
+        {
             nfc_data->type = FuriHalNfcTypeB;
         } else if(dev_list[0].type == RFAL_NFC_LISTEN_TYPE_NFCF) {
             nfc_data->type = FuriHalNfcTypeF;