Skip to content

Commit

Permalink
force hardware-reset see:stlink-org#220 (comment)
Browse files Browse the repository at this point in the history
  • Loading branch information
helmo2004 committed Jan 14, 2018
1 parent ba71988 commit 29ef2ff
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/common.c
Original file line number Diff line number Diff line change
Expand Up @@ -692,6 +692,8 @@ int stlink_load_device_params(stlink_t *sl) {

int stlink_reset(stlink_t *sl) {
DLOG("*** stlink_reset ***\n");
// Write SYSRESETREQ to NVIC AIRCR.
stlink_write_debug32(sl, 0xE000ED0C, (0x5FA << 16) | (1 << 2));
return sl->backend->reset(sl);
}

Expand Down

0 comments on commit 29ef2ff

Please sign in to comment.