flipperzero-firmware/lib/nfc/parsers/nfc_supported_card.h
Astra 9f3b80e606
Add new card parsers (#1503)
* Add the "Two cities" parser
* Add plantain and plantain4k parsers
* Add new parsers to the supported list
* United card PoC
* Fix nfc device not sleeping
* Completely read the 4K troika variants
* Correct naming
* Update to reflect upstream changes
* Add support for MfUl info
* Fix parsers
* Card type detection fixes
* Remove debug info
* Fixes for the verification of cards
* nfc: fix verification for supported cards
* nfc: remove unused vars
* Improve card reading reliability and fix plantain
* plantain: change log level

Co-authored-by: gornekich <n.gorbadey@gmail.com>
2022-09-20 01:05:04 +09:00

36 lines
944 B
C

#pragma once
#include <furi_hal_nfc.h>
#include "../nfc_worker.h"
#include "../nfc_device.h"
#include <m-string.h>
typedef enum {
NfcSupportedCardTypePlantain,
NfcSupportedCardTypeTroika,
NfcSupportedCardTypePlantain4K,
NfcSupportedCardTypeTroika4K,
NfcSupportedCardTypeTwoCities,
NfcSupportedCardTypeAllInOne,
NfcSupportedCardTypeEnd,
} NfcSupportedCardType;
typedef bool (*NfcSupportedCardVerify)(NfcWorker* nfc_worker, FuriHalNfcTxRxContext* tx_rx);
typedef bool (*NfcSupportedCardRead)(NfcWorker* nfc_worker, FuriHalNfcTxRxContext* tx_rx);
typedef bool (*NfcSupportedCardParse)(NfcDeviceData* dev_data);
typedef struct {
NfcProtocol protocol;
NfcSupportedCardVerify verify;
NfcSupportedCardRead read;
NfcSupportedCardParse parse;
} NfcSupportedCard;
extern NfcSupportedCard nfc_supported_card[NfcSupportedCardTypeEnd];
bool nfc_supported_card_verify_and_parse(NfcDeviceData* dev_data);