So as I understand it, the main application is not erased until ApplicationUpdate.Start() is called.
Therefore, I assume that if while in bootloader mode I can call SystemUpdate.AccessApplication() and rollback to the main application as long as its done before ApplicationUpdate.Start is called.
Yes, I understand that when you start writing it actually begins writing to the flash on the usbizi, but even before that Application.Start erases the flash.
What I am saying is if I am in bootloader mode, before calling ApplicationStart, which is before you even begin to write to the flash. I don’t see why I shouldn’t be able to call AccessApplication and put the device back into application mode… ?
The following is an example of how this would be useful.
Enter boot loader mode
Begin download of new code on to SD(i.e. serial, network, etc etc)
ERROR… Step 2 failed, Call AccessApplication and switch back to MainApplication.
In a happy path step 3 and on, would call ApplicationStart and begin writing the new firmware to the flash.
@ brightidea - you are correct. What i would suggest though is to download the new firmware in the application mode and then switch to bootloader to update it. This is because in bootloader mode you have only 48 KB flash - enough for your program to include libs to read from sd but not enough to use ethernet (wiznet).