MCPcopy Create free account
hub / github.com/RT-Thread/rt-thread / Ft_DumpHexWord

Function Ft_DumpHexWord

bsp/ft2004/libraries/bsp/standlone/ft_debug.c:39–67  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

37}
38
39void Ft_DumpHexWord(const u32 *ptr, ft_base_t buflen)
40{
41 u32 *buf = (u32 *)ptr;
42 int i, j;
43 buflen = buflen / 4;
44 for (i = 0; i < buflen; i += 4)
45 {
46 Ft_printf("0x%08X: ", ptr + i);
47
48 for (j = 0; j < 4; j++)
49 {
50 if (i + j < buflen)
51 {
52 Ft_printf("%08X ", buf[i + j]);
53 }
54 else
55 {
56 Ft_printf(" ");
57 }
58 }
59
60 Ft_printf(" ");
61
62 for (j = 0; j < 16; j++)
63 if (i + j < buflen)
64 Ft_printf("%c", __is_print(buf[i + j]) ? buf[i + j] : '.');
65 Ft_printf("\r\n");
66 }
67}

Callers 2

demo_dump_sdcFunction · 0.85

Calls 1

Ft_printfFunction · 0.85

Tested by

no test coverage detected