atr_scrap_eftlab.py producing atrs.h compatible with make style
This commit is contained in:
1 parent
b7ea848f7f
commit
1139650948
2 files changed
+23
-23
No files matched your search
+11
-11
@@ -37,26 +37,26 @@ def main():
|
||||
print(
|
||||
"""#ifndef ATRS_H__
|
||||
|
||||
#define ATRS_H__
|
||||
#define ATRS_H__
|
||||
|
||||
#include <stddef.h>
|
||||
#include <stddef.h>
|
||||
|
||||
typedef struct atr_s {
|
||||
const char *bytes;
|
||||
const char *desc;
|
||||
} atr_t;
|
||||
typedef struct atr_s {
|
||||
const char *bytes;
|
||||
const char *desc;
|
||||
} atr_t;
|
||||
|
||||
const char *getAtrInfo(const char *atr_str);
|
||||
const char *getAtrInfo(const char *atr_str);
|
||||
|
||||
// atr_t array are expected to be NULL terminated
|
||||
const static atr_t AtrTable[] = {""")
|
||||
// atr_t array are expected to be NULL terminated
|
||||
const static atr_t AtrTable[] = {""")
|
||||
|
||||
print_atr(df)
|
||||
|
||||
print(""" {NULL, "no ATR info available"}
|
||||
};
|
||||
};
|
||||
|
||||
#endif""")
|
||||
#endif""")
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
||||
+12
-12
@@ -1,18 +1,18 @@
|
||||
#ifndef ATRS_H__
|
||||
|
||||
#define ATRS_H__
|
||||
|
||||
#include <stddef.h>
|
||||
#define ATRS_H__
|
||||
|
||||
typedef struct atr_s {
|
||||
const char *bytes;
|
||||
const char *desc;
|
||||
} atr_t;
|
||||
#include <stddef.h>
|
||||
|
||||
const char *getAtrInfo(const char *atr_str);
|
||||
typedef struct atr_s {
|
||||
const char *bytes;
|
||||
const char *desc;
|
||||
} atr_t;
|
||||
|
||||
// atr_t array are expected to be NULL terminated
|
||||
const static atr_t AtrTable[] = {
|
||||
const char *getAtrInfo(const char *atr_str);
|
||||
|
||||
// atr_t array are expected to be NULL terminated
|
||||
const static atr_t AtrTable[] = {
|
||||
{ "3B021450", "Schlumberger Multiflex 3k" },
|
||||
{ "3B025301", "Gemplus GemClub Memo SuperShop clubcard" },
|
||||
{ "3B0400000000", "Laundromat payment card Spanish ID (“DNIe: Documento Nacional de Identidad electrónico). http://www.dnie.es/" },
|
||||
@@ -1619,6 +1619,6 @@
|
||||
{ "3FFF9500FF918171FF4700444E4153505330312044736836303916", "PayTV card for DishNetwork Sat receiver http://www.dishnetwork.com/ Cards were obsoleted in nationwide system update in 2009." },
|
||||
{ "3FFF9500FF918171FF470054494745523030332052657632353064", "Tivu’ Sat (Italy) CAM card www.tivu.tv" },
|
||||
{NULL, "no ATR info available"}
|
||||
};
|
||||
};
|
||||
|
||||
#endif
|
||||
#endif
|
||||
Reference in new issue
Block a user