Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

command: Convert format-string in rtt #1682

Merged
merged 1 commit into from
Nov 14, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions src/command.c
Original file line number Diff line number Diff line change
Expand Up @@ -534,8 +534,8 @@ static bool cmd_rtt(target_s *t, int argc, const char **argv)
}
if (rtt_flag_ram)
gdb_outf("ram: 0x%08" PRIx32 " 0x%08" PRIx32, rtt_ram_start, rtt_ram_end);
gdb_outf(
"\nmax poll ms: %u min poll ms: %u max errs: %u\n", rtt_max_poll_ms, rtt_min_poll_ms, rtt_max_poll_errs);
gdb_outf("\nmax poll ms: %" PRIu32 " min poll ms: %" PRIu32 " max errs: %" PRIu32 "\n", rtt_max_poll_ms,
rtt_min_poll_ms, rtt_max_poll_errs);
} else if (argc >= 2 && strncmp(argv[1], "channel", command_len) == 0) {
/* mon rtt channel switches to auto rtt channel selection
mon rtt channel number... selects channels given */
Expand All @@ -554,9 +554,9 @@ static bool cmd_rtt(target_s *t, int argc, const char **argv)
} else if (argc == 2 && strncmp(argv[1], "ident", command_len) == 0)
rtt_ident[0] = '\0';
else if (argc == 2 && strncmp(argv[1], "poll", command_len) == 0)
gdb_outf("%u %u %u\n", rtt_max_poll_ms, rtt_min_poll_ms, rtt_max_poll_errs);
gdb_outf("%" PRIu32 " %" PRIu32 " %" PRIu32 "\n", rtt_max_poll_ms, rtt_min_poll_ms, rtt_max_poll_errs);
else if (argc == 2 && strncmp(argv[1], "cblock", command_len) == 0) {
gdb_outf("cbaddr: 0x%x\n", rtt_cbaddr);
gdb_outf("cbaddr: 0x%08" PRIx32 "\n", rtt_cbaddr);
gdb_out("ch ena i/o buffer@ size head tail flag\n");
for (uint32_t i = 0; i < rtt_num_up_chan + rtt_num_down_chan; ++i) {
gdb_outf("%2" PRIu32 " %c %s 0x%08" PRIx32 " %6" PRIu32 " %6" PRIu32 " %6" PRIu32 " %4" PRIu32 "\n", i,
Expand Down