My understanding is that it was the change in the bootloader that is the issue, and there's no way that bootloader (which was not released) could boot any pre-20.7 firmware successfully.
As for your original problem, perhaps it was something else completely - wrong firmware for example?
Testing the firmware for which hardware it has been compiled for is a nice idea. We'd have to just add an identifier before or after the
isr_vector. I'd be tempted to put it before, since the length of
isr_vector varies with hardware.
I'm also keen to enable the IWDG watchdog to make the risk of accidentally bricking a device much less likely, be it by a dodgy firmware, a patch, or corrupted flash process. I've pushed a new branch:
If you have a chance to test it (@antisvin or anyone else who is brave and has access to a hardware programmer!) it would be good to have it verified that it works not just for me. The main updates are to the bootloader, which now initialises the IWDG watchdog to trigger after 8 seconds, unless its timer is reset in that period. When the IWDG triggers, the device is automatically reset. So if you flash the new bootloader and let it start up an old firmware, then it should reset to bootloader after max 8 secs because the firmware doesn't 'feed the dog' (ie reset the IWDG timer). To prevent it doing that, just compile and flash a new firmware from the same branch, which includes the timer reset.