Other Parts Discussed in Thread: UNIFLASH, TIDM-02011
Hello Community,
I'm using F283888D for my product development. I have a requirement to divide available flash of CM core into 3 parts - APP1, APP2 and APP3 and Jump between them whenever required.
Could be in situations when CM - APP2 is Hung and WWD triggered and in NMI we shall jump to APP3 and in APP3 we want to de-initialize some stuff (like peripherals/IPC unregisters etc..)
and then Jump back to APP-2 and If required can also Jump to APP1.
APP-1 stored in FLASH sectors 1-3,
APP2 stored in FLASH sectors 4-7 and remaining are for APP3.
APP1 will be booted first whenever we perform a POR and from APP1, APP2 will be called.
We've implementations that shall program APP3/APP1 from APP2 and JUMP to APP3/APP1 when needed to.
I see that I can write and read FW opcodes to required Flash sectors using UNIFLASH.
So I'm comparing Flash sectors opcodes by reading respective sectors of APP3 and APP1 from UniFlash (by writing first and then reading) with the data that is being written from APP-2.
I see that there are no differences and hence I conclude that Data is written properly.
But here comes the main problem that I'm facing.... Whenever we Branch from APP-3 back to APP2.... and repeatedly branch couple of times I see that execution is stuck somewhere and if i read using target configurations file it gives me 0x1816 as in FIG1 value and as per TRM it says FIG2: In wait boot mode waiting for boot command. And execution is stuck there.
Please check the program_flsh_read_data.zip file for files written and read.
Q1 :: Why does boot command comes into picture here ?
FIG1:

FIG2

Also I'm able to write APP1 from APP2 but unable to jump to APP1 from APP2. As APP1 is first instruction gets executed during POR, After writing APP1 from APP2 I'm performing a POR but I see that APP1 doesnt seem to restart. I have added LEDs to know if it is jumped or not , but i don't see LED blinking. I see that it is stuck at 0x1816 in this case also. What could be the reasons ?
Q2: Anything that needs to be executed before jumping from one app to another app ?
My further queries follows here:
Q3: Can we actually jump from one flash sector to another flash sector back and forth ? If not why and how to overcome ?
Q4: what and all care shall be taken before jumping ?
Q5: Anything shall be done before jumping to secondary fw from primary fw (ie., from SSBL to APPlication FW)
Q6 : Any instructions like clearing PC,SP,LR or main registers resetting shall be done before we jump from APP FW to SSBL ? if So can you share me example source code or path to find them.
I'm using C2000 sdk 4.03 and 4.00.
Let me know if anything else required to be shared
Vivek Singh / @ Hareesh Janakiraman Can you please help me out here.
Thanks,
Pranay



