Skip to content

Commit

Permalink
ARMmbed#80 Add incompatible image detection feature in details.txt fi…
Browse files Browse the repository at this point in the history
…le. Add documentation on the feautre.
  • Loading branch information
gerargz authored and gaborcsapo committed Jun 29, 2022
1 parent ce22988 commit 168e304
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
5 changes: 5 additions & 0 deletions docs/MSD_COMMANDS.md
Original file line number Diff line number Diff line change
Expand Up @@ -82,3 +82,8 @@ data fast enough from DAPLink and an overflow occurs the text ```<DAPLink:Overfl
will show up in the serial data. Serial overflow reporting is turned off by default.

``ovfl_off.cfg`` This file turns off serial overflow reporting.


``comp_on.cfg`` This file turns on the incompatible target image detection. The interface project must define a board specific `board_detect_incompatible_image()` function with the criteria to validate the target image over the first 12 vectors. Otherwise, the incompatible target image detection won't have an effect.

``comp_off.cfg`` This file turns off the incompatible target image detection (off by default).
3 changes: 3 additions & 0 deletions source/daplink/drag-n-drop/vfs_user.c
Original file line number Diff line number Diff line change
Expand Up @@ -506,6 +506,9 @@ static uint32_t update_details_txt_file(uint8_t *data, uint32_t datasize)
pos += util_write_string(buf + pos, "Overflow detection: ");
pos += util_write_string(buf + pos, config_get_overflow_detect() ? "1" : "0");
pos += util_write_string(buf + pos, "\r\n");
pos += util_write_string(buf + pos, "Incompatible image detection: ");
pos += util_write_string(buf + pos, config_get_detect_incompatible_target() ? "1" : "0");
pos += util_write_string(buf + pos, "\r\n");
pos += util_write_string(buf + pos, "Page erasing: ");
pos += util_write_string(buf + pos, config_ram_get_page_erase() ? "1" : "0");
pos += util_write_string(buf + pos, "\r\n");
Expand Down

0 comments on commit 168e304

Please sign in to comment.