Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // https://yoursunny.com/t/2018/PriUint64/
- // https://github.com/yoursunny/PriUint64/
- #include "PriUint64.h"
- byte *ptr1; // define o pointer
- int *ptr2;
- //---------------------------------------------------------------------------
- void setup()
- {
- Serial.begin(115200); // Inicializa serial
- Serial.println(" "); // Nova linha
- uint64_t valor = 0xABCDEF55FC28C24B; // Define variavel e carrega com HEX
- Serial.println(PriUint64<HEX>(valor)); // Nova linha
- ptr1 = (byte *)&valor; // Carrega o endereco da variavel no pointer
- ptr2 = (int *)&valor;
- Serial.println(*ptr1, HEX);
- ptr1++;
- Serial.println(*ptr1, HEX);
- Serial.println("------"); // Nova linha
- Serial.println(*ptr2, HEX);
- ptr2++;
- Serial.println(*ptr2, HEX);
- }
- //---------------------------------------------------------------------------
- void loop() {
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement