Merge pull request #20 from pfalcon/hex-abs-addr

cmd-hex: Dump absolute memory address.

This code has been copied-and-pasted across multiple projects, hence the split between
hex_offset() and hex().  This is a fine patch for this project.
This commit is contained in:
Sean Cross 2015-04-07 17:04:23 +08:00
commit 7402d86909

View file

@ -36,7 +36,7 @@ int serial_print_hex_offset(const void *block, int count, int offset)
count += offset;
b -= offset;
for ( ; offset < count; offset += 16) {
serial_puth(offset, 8);
serial_puth((uint32_t)b + offset, 8);
for (byte = 0; byte < 16; byte++) {
if (byte == 8)