This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

AM2434: bootloader over UART and OSPI

Part Number: AM2434
Other Parts Discussed in Thread: UNIFLASH

Hi,

I was asked to make a program where the main application resides in an OSPI flash and the custumer uses UART communication for fimware update.

From hereafter i will refer to the OSPI bootloader example provided by AM243x MCU+SDK as OSPI boot. 

The two possible solutions that came up to my mind are:

        A) At startup the ROM is in OSPI bootloader mode.
            The main program is loaded using OSPI boot.
            The program constanly listens to the UART port for a firwmare update.

        B) At startup the ROM is in OSPI bootloader mode.
             The OSPI boot(1) loads a custom made bootloader that listens for any update from the UART for a few seconds.
             If no communication starts a second OSPI bootl(2) loads the main program.
             (if a new firmware is being loaded via UART no timeout will occur and the second OSPI boot(2) will load the newly flashed firmware).

I am new to bootloaders so here's what I'm asking you experts:

  1.  Are this valid solutions or is there a better way of solving this problem?
  2.  Is there any available guideline on how to make such a bootloader or where can I find the documentation about it?

I already checked mcu_plus_sdk_am243x_08_03_00_18/docs/api_guide_am243x/BOOTFLOW_GUIDE.html but couldn't find a way of making solution A) or B)