Glad I could be of some help.
> Are you saying in your last paragraph that I might be able to recover the download capability with, say, a really short program that can be downloaded "in between" the resets issuing from processor?
Not exactly. It's the job of the debug adapter (and its companion software) to get the target into a stable state, such that it can write your application to flash. The size of that application shouldn't matter. You as the user shouldn't have to worry about resets happening while the programming is taking place. That should all be taken care of by the debug adapter/software.
Exactly how the debug adapter/software gets the target into a stable state will vary between devices and the debug provider. In some cases it will involve placing instructions to disable the watchdog in SRAM, and executing them before trying to perform the flash write operation. Sometimes, if the target is stuck in a reset loop then the debug adapter/software may struggle to perform the operations it needs to to get the target into a stable state. The extent of this problem varies between different targets and debug solutions.
The other thing to be aware of is that if a mass-erase simply clears every bit in flash, then both security bits in the flash configuration field are being set to 1, which is a secure state. The mass-erase command has turned off flash security, but if you reset before writing a new application that disables flash security in the flash configuration field, you'll just end up in a secure state again. Note however that when you ask a particular debug adapter to perform a mass erase it could simply clear flash, or it could clear flash then modify the flash configuration field to unsecure the target across reboots.
With that in mind, let me rephrase the final paragraph from my previous response:
* If the device is secure and mass erase is disabled then it's probably a brick (unrecoverable).
* If the device is secure and mass erase is enabled then it should be recoverable.
* Performing a mass-erase will unsecure the device...
* ...BUT...some things can make the device unusable again pretty quickly (including reset loops, and cleared flash configuration fields)...
* ...SO...when recovering a secured device perform the mass erase, then get a known-good program onto it as soon as possible (before a reset).
Hopefully that answers your question?