Don't make me think!
This commit is contained in:
parent
57e1fceb6b
commit
27d33775dc
2 changed files with 3 additions and 0 deletions
|
@ -286,8 +286,10 @@ struct mifare_ultralight_tag {
|
|||
#define TB_AB(ab) ((ab == C_DEFAULT) ? C_100 : ab)
|
||||
|
||||
#ifdef WITH_DEBUG
|
||||
#define DEBUG_FUNCTION() do { printf("*** \033[033;1m%s\033[0m ***\n", __FUNCTION__); } while (0)
|
||||
#define DEBUG_XFER(data, nbytes, hint) do { hexdump (data, nbytes, hint, 0); } while (0)
|
||||
#else
|
||||
#define DEBUG_FUNCTION() do {} while (0)
|
||||
#define DEBUG_XFER(data, nbytes, hint) do {} while (0)
|
||||
#endif
|
||||
|
||||
|
|
|
@ -166,6 +166,7 @@ static ssize_t read_data (MifareTag tag, uint8_t command, uint8_t file_no, off_
|
|||
*/
|
||||
#define DESFIRE_TRANSCEIVE2(tag, msg, msg_len, res) \
|
||||
do { \
|
||||
DEBUG_FUNCTION(); \
|
||||
static uint8_t __msg[MAX_CAPDU_SIZE + 5] = { 0x90, 0x00, 0x00, 0x00, 0x00, /* ..., */ 0x00 }; \
|
||||
/* CLA INS P1 P2 Lc PAYLOAD LE*/ \
|
||||
static uint8_t __res[MAX_RAPDU_SIZE + 1]; \
|
||||
|
|
Loading…
Reference in a new issue