Skip to content

Instantly share code, notes, and snippets.

@marcelstoer
Created April 9, 2018 20:37
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save marcelstoer/2ba116bcb3546fffcc274b9c8518ec2b to your computer and use it in GitHub Desktop.
Save marcelstoer/2ba116bcb3546fffcc274b9c8518ec2b to your computer and use it in GitHub Desktop.
Arduino uint64ToString
// source: https://github.com/markszabo/IRremoteESP8266/blob/master/src/IRutils.cpp#L48
String uint64ToString(uint64_t input) {
String result = "";
uint8_t base = 10;
do {
char c = input % base;
input /= base;
if (c < 10)
c +='0';
else
c += 'A' - 10;
result = c + result;
} while (input);
return result;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment