Merge pull request #373 from UweBonnes/fixes
Fixes for detach and stm32mem
This commit is contained in:
commit
0551809475
|
@ -89,7 +89,10 @@ def stm32_scan(args, test):
|
|||
exit(-1)
|
||||
|
||||
for dev in devs:
|
||||
dfudev = dfu.dfu_device(*dev)
|
||||
try:
|
||||
dfudev = dfu.dfu_device(*dev)
|
||||
except:
|
||||
return 0
|
||||
man = dfudev.handle.getString(dfudev.dev.iManufacturer, 30)
|
||||
if man == "Black Sphere Technologies": bmp = bmp + 1
|
||||
if bmp == 0 :
|
||||
|
|
|
@ -413,6 +413,8 @@ void cortexm_detach(target *t)
|
|||
|
||||
/* Disable debug */
|
||||
target_mem_write32(t, CORTEXM_DHCSR, CORTEXM_DHCSR_DBGKEY);
|
||||
/* Add some clock cycles to get the CPU running again.*/
|
||||
target_mem_read32(t, 0);
|
||||
}
|
||||
|
||||
enum { DB_DHCSR, DB_DCRSR, DB_DCRDR, DB_DEMCR };
|
||||
|
|
Loading…
Reference in New Issue