Skip to content
This repository was archived by the owner on Oct 5, 2021. It is now read-only.

Commit 033aaa8

Browse files
committed
Report RAM and flash size as maximal values
https://sourceforge.net/p/stm32flash/tickets/56/ Signed-off-by: Tormod Volden <debian.tormod@gmail.com>
1 parent 1f10b4e commit 033aaa8

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

main.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -313,8 +313,8 @@ int main(int argc, char* argv[]) {
313313
fprintf(diag, "Option 2 : 0x%02x\n", stm->option2);
314314
}
315315
fprintf(diag, "Device ID : 0x%04x (%s)\n", stm->pid, stm->dev->name);
316-
fprintf(diag, "- RAM : %dKiB (%db reserved by bootloader)\n", (stm->dev->ram_end - 0x20000000) / 1024, stm->dev->ram_start - 0x20000000);
317-
fprintf(diag, "- Flash : %dKiB (size first sector: %dx%d)\n", (stm->dev->fl_end - stm->dev->fl_start ) / 1024, stm->dev->fl_pps, stm->dev->fl_ps[0]);
316+
fprintf(diag, "- RAM : Up to %dKiB (%db reserved by bootloader)\n", (stm->dev->ram_end - 0x20000000) / 1024, stm->dev->ram_start - 0x20000000);
317+
fprintf(diag, "- Flash : Up to %dKiB (size first sector: %dx%d)\n", (stm->dev->fl_end - stm->dev->fl_start ) / 1024, stm->dev->fl_pps, stm->dev->fl_ps[0]);
318318
fprintf(diag, "- Option RAM : %db\n", stm->dev->opt_end - stm->dev->opt_start + 1);
319319
fprintf(diag, "- System RAM : %dKiB\n", (stm->dev->mem_end - stm->dev->mem_start) / 1024);
320320

0 commit comments

Comments
 (0)