chg: 'hf thinfilm info' - fixed manufacture lookup

This commit is contained in:
iceman1001 2019-08-01 12:16:33 -04:00
commit 2a054438ab
3 changed files with 5 additions and 2 deletions

View file

@ -73,7 +73,7 @@ static const manufactureName manufactureMapping[] = {
{ 0x34, "Mikron JSC Russia" }, { 0x34, "Mikron JSC Russia" },
{ 0x35, "Fraunhofer Institute for Photonic Microsystems Germany" }, { 0x35, "Fraunhofer Institute for Photonic Microsystems Germany" },
{ 0x36, "IDS Microchip AG Switzerland" }, { 0x36, "IDS Microchip AG Switzerland" },
{ 0x37, "Kovio USA" }, { 0x37, "Thinfilm - Kovio USA" },
{ 0x38, "HMT Microelectronic Ltd Switzerland" }, { 0x38, "HMT Microelectronic Ltd Switzerland" },
{ 0x39, "Silicon Craft Technology Thailand" }, { 0x39, "Silicon Craft Technology Thailand" },
{ 0x3A, "Advanced Film Device Inc. Japan" }, { 0x3A, "Advanced Film Device Inc. Japan" },

View file

@ -27,7 +27,9 @@ static int usage_thinfilm_info(void) {
// https://github.com/nfc-tools/libnfc/blob/master/utils/nfc-barcode.c // https://github.com/nfc-tools/libnfc/blob/master/utils/nfc-barcode.c
static int print_barcode(uint8_t *barcode, const size_t barcode_len, bool verbose) { static int print_barcode(uint8_t *barcode, const size_t barcode_len, bool verbose) {
PrintAndLogEx(SUCCESS, " Manufacturer : "_YELLOW_("%s") "[0x%02X]", (barcode[0] == 0xB7) ? "Thinfilm" : "unknown", barcode[0]); // remove start bit
uint8_t mb = barcode[0] & ~0x80;
PrintAndLogEx(SUCCESS, " Manufacturer : "_YELLOW_("%s") "[0x%02X]", getTagInfo(mb), mb);
if (verbose) { if (verbose) {
PrintAndLogEx(SUCCESS, " Data format : "_YELLOW_("%02X"), barcode[1]); PrintAndLogEx(SUCCESS, " Data format : "_YELLOW_("%02X"), barcode[1]);

View file

@ -20,6 +20,7 @@
#include "cmdparser.h" #include "cmdparser.h"
#include "util.h" #include "util.h"
#include "cmdhf.h" // list cmd #include "cmdhf.h" // list cmd
#include "cmdhf14a.h" // manufacture
int infoThinFilm(bool verbose); int infoThinFilm(bool verbose);