Add a nfc-utils fonction (not in API) to display nfc_target_type_t as string
This commit is contained in:
parent
202c2a7a8b
commit
5d753827c1
2 changed files with 56 additions and 0 deletions
|
@ -212,6 +212,60 @@ print_nfc_dep_info (const nfc_dep_info_t ndi)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void print_nfc_target_type( const nfc_target_type_t ntt )
|
||||||
|
{
|
||||||
|
switch (ntt) {
|
||||||
|
case NTT_GENERIC_PASSIVE_106:
|
||||||
|
printf ("Generic passive 106 kbps (ISO/IEC14443-4A, mifare, DEP)\n");
|
||||||
|
break;
|
||||||
|
case NTT_GENERIC_PASSIVE_212:
|
||||||
|
printf ("Generic passive 212 kbps (FeliCa, DEP)\n");
|
||||||
|
break;
|
||||||
|
case NTT_GENERIC_PASSIVE_424:
|
||||||
|
printf ("Generic passive 424 kbps (FeliCa, DEP)\n");
|
||||||
|
break;
|
||||||
|
case NTT_ISO14443B_106:
|
||||||
|
printf ("Passive 106 kbps ISO/IEC14443-4B\n");
|
||||||
|
break;
|
||||||
|
case NTT_JEWEL_106:
|
||||||
|
printf ("Innovision Jewel tag\n");
|
||||||
|
break;
|
||||||
|
case NTT_MIFARE:
|
||||||
|
printf ("mifare card\n");
|
||||||
|
break;
|
||||||
|
case NTT_FELICA_212:
|
||||||
|
printf ("FeliCa 212 kbps card\n");
|
||||||
|
break;
|
||||||
|
case NTT_FELICA_424:
|
||||||
|
printf ("FeliCa 424 kbps card\n");
|
||||||
|
break;
|
||||||
|
case NTT_ISO14443A_106:
|
||||||
|
printf ("Passive 106 kbps ISO/IEC14443-4A\n");
|
||||||
|
break;
|
||||||
|
case NTT_ISO14443B_TCL_106:
|
||||||
|
printf ("Passive 106 kbps ISO/IEC14443-4B with TCL flag\n");
|
||||||
|
break;
|
||||||
|
case NTT_DEP_PASSIVE_106:
|
||||||
|
printf ("DEP passive 106 kbps\n");
|
||||||
|
break;
|
||||||
|
case NTT_DEP_PASSIVE_212:
|
||||||
|
printf ("DEP passive 212 kbps\n");
|
||||||
|
break;
|
||||||
|
case NTT_DEP_PASSIVE_424:
|
||||||
|
printf ("DEP passive 424 kbps\n");
|
||||||
|
break;
|
||||||
|
case NTT_DEP_ACTIVE_106:
|
||||||
|
printf ("DEP active 106 kbps\n");
|
||||||
|
break;
|
||||||
|
case NTT_DEP_ACTIVE_212:
|
||||||
|
printf ("DEP active 212 kbps\n");
|
||||||
|
break;
|
||||||
|
case NTT_DEP_ACTIVE_424:
|
||||||
|
printf ("DEP active 424 kbps\n");
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Tries to parse arguments to find device descriptions.
|
* @brief Tries to parse arguments to find device descriptions.
|
||||||
* @return Returns the list of found device descriptions.
|
* @return Returns the list of found device descriptions.
|
||||||
|
|
|
@ -40,6 +40,8 @@ void print_nfc_felica_info (const nfc_felica_info_t nfi);
|
||||||
void print_nfc_jewel_info (const nfc_jewel_info_t nji);
|
void print_nfc_jewel_info (const nfc_jewel_info_t nji);
|
||||||
void print_nfc_dep_info (const nfc_dep_info_t ndi);
|
void print_nfc_dep_info (const nfc_dep_info_t ndi);
|
||||||
|
|
||||||
|
void print_nfc_target_type( const nfc_target_type_t ntt );
|
||||||
|
|
||||||
nfc_device_desc_t *parse_device_desc (int argc, const char *argv[], size_t * szFound);
|
nfc_device_desc_t *parse_device_desc (int argc, const char *argv[], size_t * szFound);
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Reference in a new issue