diff options
author | Andrey Yurovsky <yurovsky@gmail.com> | 2014-08-06 14:28:37 -0700 |
---|---|---|
committer | Spencer Oliver <spen@spen-soft.co.uk> | 2014-10-06 11:56:27 +0000 |
commit | 592d0d514d6602ae9c91cda7e4271c28222a25f6 (patch) | |
tree | f411653e99384f01917554a1c0578f2148bbc506 /doc/openocd.texi | |
parent | ec9ccaa288491a5ec09da96e07d7cba3aee981c9 (diff) | |
download | riscv-openocd-592d0d514d6602ae9c91cda7e4271c28222a25f6.zip riscv-openocd-592d0d514d6602ae9c91cda7e4271c28222a25f6.tar.gz riscv-openocd-592d0d514d6602ae9c91cda7e4271c28222a25f6.tar.bz2 |
at91samd: add erase/secure commands, minor fix
Reference code for the SAMD2x disables caching in the NVM controller when
issuing NVM commands. Let's do this as well to be consistent and safer.
Add a "chip-erase" for the Atmel SAMD targets that issues a complete Chip Erase
via the Device Service Unit (DSU). This can be used to "unlock" or otherwise
unbrick a chip that can't be halted or inspected, allowing the user to reflash
with new firmware.
Add a "set-security" command which issues an SSB. Once that's done and the
device is power-cycled, the flash cannot be written to until a "chip-erase" is
issued. The chip-erase cannot be issued by openocd at this time because
the device will not respond to a request for the DAP IDCODE.
Change-Id: I80122f0bbf7e3aedffe052c1e77d69dc2dba25ed
Signed-off-by: Andrey Yurovsky <yurovsky@gmail.com>
Reviewed-on: http://openocd.zylin.com/2239
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
Diffstat (limited to 'doc/openocd.texi')
-rw-r--r-- | doc/openocd.texi | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/doc/openocd.texi b/doc/openocd.texi index 0b50c65..7cba65d 100644 --- a/doc/openocd.texi +++ b/doc/openocd.texi @@ -5023,6 +5023,30 @@ flash bank $_FLASHNAME aduc702x 0 0 0 0 $_TARGETNAME @end example @end deffn +@anchor{at91samd} +@deffn {Flash Driver} at91samd +@cindex at91samd + +@deffn Command {at91samd chip-erase} +Issues a complete Flash erase via the Device Service Unit (DSU). This can be +used to erase a chip back to its factory state and does not require the +processor to be halted. +@end deffn + +@deffn Command {at91samd set-security} +Secures the Flash via the Set Security Bit (SSB) command. This prevents access +to the Flash and can only be undone by using the chip-erase command which +erases the Flash contents and turns off the security bit. Warning: at this +time, openocd will not be able to communicate with a secured chip and it is +therefore not possible to chip-erase it without using another tool. + +@example +at91samd set-security enable +@end example +@end deffn + +@end deffn + @anchor{at91sam3} @deffn {Flash Driver} at91sam3 @cindex at91sam3 |