I'm a long-time HC05/HC08 user, but only recently am I starting to use HCS08 MCUs. Have been waiting for a while (too long) for the DZ family (we use CANbus, so other S08 aren't much use).
I was looking forward to some of the new/better features in the S08, such as BDM. But the vector redirection is a huge disappointment. From doing a search, it seems that others agree that vector redirection isn't all that exciting.
We have for several years used a CAN bootloader in the GZ60/AZ60 MCUs. We use a jump table, so that the application firmware runs only if the jump table isn't all FFFF. Vector redirection *could* have been great, but it isn't. So I'm having to stick with a jump table in the DZ60.
I suppose that some people will be OK with the S08 implementation of vector redirection. Not sure what for though. Currently you have to either go without interrupts in the bootloader, or use a jump table. For it to be really useful for any bootloader/monitor code in protected flash, you really need to have control over the redirection.
On reset, NVOPT is loaded to FOPT. So redirection can be done at reset by configuring NVOPT. But FOPT isn't writeable, so you can't change it at runtime. Possibly only allow for redirection to be turned on from protected flash, to prevent rogue application firmware from "stealing" control.
My suggested "fix": make FNORED in FOPT writeable at runtime, so that 1) a protected bootloader can pass control over to application firmware (turn ON the vector redirection), 2) application firmware can turn OFF redirection, which effectively passes control back to a bootloader/monitor.
This would allow redirection on reset, as currently implemented, for applications without a bootloader/monitor. But would improve the usefulness when you need interrupts in a bootloader (eg - for CAN), AND want to then be able to swap to application firmware, with it's own set of vectors.
My question to Freescale: will new/updated S08 MCUs "fix" this problem? is Freescale happy with how it's currently implemented?
My question to other S08 users: would you like to see Freescale improve this feature? yes? no? or don't care? or does anyone have a better way to achieve this?]
Added p/n to subject.
I would go one further - the normal vector table and a register that holds the pointer to the user vector table. Now add registers to control where the source of each interrupt vector comes from (normal or user). A single bit in these registers would select from one table or the other (one bit for each interrupt source). Provide the necessary protection to lock these at reset and perhaps a mechanism that would allow changing them only when the cpu interrupt mask is set.
Therefore different combinations of interrupts could be allocated to the bootloader while others would be allocated to the application.