diff --git a/src/pn532/pn532.cxx b/src/pn532/pn532.cxx index d0e7b221..2ac512d2 100644 --- a/src/pn532/pn532.cxx +++ b/src/pn532/pn532.cxx @@ -995,7 +995,8 @@ bool PN532::mifareclassic_WriteNDEFURI (uint8_t sectorNumber, // Setup the sector buffer (w/pre-formatted TLV wrapper and NDEF message) uint8_t sectorbuffer1[16] = {0x00, 0x00, 0x03, static_cast(len+5), 0xD1, 0x01, static_cast(len+1), - 0x55, uriIdentifier, 0x00, 0x00, 0x00, 0x00, + 0x55, static_cast(uriIdentifier), + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; uint8_t sectorbuffer2[16] = {0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, @@ -1337,7 +1338,7 @@ bool PN532::ntag2xx_WriteNDEFURI (NDEF_URI_T uriIdentifier, char * url, 0x01, /* Type Length for the record type indicator */ static_cast(len+1), /* Payload len */ 0x55, /* Record Type Indicator (0x55 or 'U' = URI Record) */ - uriIdentifier /* URI Prefix (ex. 0x01 = "http://www.") */ + static_cast(uriIdentifier) /* URI Prefix (ex. 0x01 = "http://www.") */ }; // Write 12 byte header (three pages of data starting at page 4)