c++ - Need the output of printf as a String or char array -


i have been working on arduino project. has written library mfrc522, rfid. need change on library, , need use output of printf variable.

i meant:

serial.print(f("card uid:")); (byte = 0; < uid->size; i++) {     if(uid->uidbyte[i] < 0x10)         serial.print(f(" 0"));     else         serial.print(f(" "));     serial.print(uid->uidbyte[i], hex); }  serial.println(); 

and in general output comes as

card uid: a6 74 e6 2b 

i need these id's put them in array or this. please teach me ways use them variables.

look standard sprintf (better snprintf, better in linux asprintf) c, posix open_memstream, (or, in standard c++, std::ostringstream) or similar functions arduino.


Comments

Popular posts from this blog

php - Vagrant up error - Uncaught Reflection Exception: Class DOMDocument does not exist -

vue.js - Create hooks for automated testing -

Add new key value to json node in java -