bug fix to printing decimals

This commit is contained in:
2026-01-28 11:56:58 +11:00
parent bb6a1f7e31
commit 1a96ca983d
5 changed files with 2 additions and 2 deletions

View File

@@ -35,9 +35,9 @@ const char* to_hstring(uint64_t value) {
for (uint8_t i = 0; i < size; i++) {
ptr = ((uint8_t*)valPtr + i);
temp = ((*ptr & 0xF0) >> 4);
hexTo_StringOutput[size - (i * 2 + 1)] = temp + (temp > 9 ? 'A' : '0');
hexTo_StringOutput[size - (i * 2 + 1)] = temp + (temp > 9 ? 55 : '0');
temp = ((*ptr & 0x0F));
hexTo_StringOutput[size - (i * 2)] = temp + (temp > 9 ? 'A' : '0');
hexTo_StringOutput[size - (i * 2)] = temp + (temp > 9 ? 55 : '0');
}
hexTo_StringOutput[size + 1] = 0;