The RF24 library requires a uint64 value
The RF24 library is silly and inefficient, probably. Unless it is actually doing 64bit math, something like char[5] would be a lot better on AVR-like processors (avr-gcc is known to produce particularly bad code for 64bit manipulation)
However, something like the following should work ok:
char hexCharToBin(char c) {
if (isdigit(c)) { // 0 - 9
return c - '0';
} else if (isxdigit(c)) { // A-F, a-f
return (c & 0xF) + 9;
}
return -1;
}
unsigned long long hexStrToULL(char * string)
{
unsigned long long x =0;
char c;
do {
c =hexCharToBin(*string++);
if (c < 0)
break;
x = (x << 4) | c;
} while (1);
return x;
}