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.

AM2634: Flashing external flash via QSPI

Part Number: AM2634
Other Parts Discussed in Thread: TMDSCNCD263, , UNIFLASH

Tool/software:

Hi,

I am currently developing in CCS on a TMDSCNCD263 board where my program is loaded into RAM each programming.

On my custom PCB, I will have a 128Mbit NOR flash attached via QSPI.

How can I flash this external flash through a XDS110 debugger -> through the AM2634 -> QSPI -> FLASH? Is this the expected path?

Do I need to write a program to forward this image into flash?

Do I need to program a SBL that will look for and boot from this external flash?

Is there a guide that explains this whole procedure?

Thank you!

Justin

  • Hi Justin,

    Thanks for your query, 

    Am263x is an external flash device. So in order to access flash, we need QSPI peripheral to do read and writes.

    in order to access QSPI peripheral, you need CPU to program QSPI peripheral.

  • So there are multiple option to program QSPI Peripheral:

    https://software-dl.ti.com/mcu-plus-sdk/esd/AM263X/latest/exports/docs/api_guide_am263x/TOOLS_FLASH.html

    This can be done at multiple stages:

    1. ROM- In UART boot mode, ROM prepares UART peripheral to receive SBL image. The SBL image can use multiple interface to receive application image and then program QSPI peripheral to program that application image. Tools like Uniflash GUI tool- Via UART mode, UART uniflash python tool.

    2. In dev boot mode or QSPI boot mode- you can program a flasher loader binary to program the QSPI image. Tools that support this is Uniflash gui TOOL via JTAG mode and CCS

  • Hi Nilabh, thank you for the quick answer and the guide, this is very helpful.

    Moving off the devkit where there are DIP switches to change what boot mode will take effect, on a custom PCB, how can I program the AM2634 ROM for these different boot modes? Is there a separate guide for this?

    Thanks

  • Also I am able to successfully get it booting on my control card, but what SBL should we use for the stand alone AM2634 when its on our PCB?
    This is the SBL i am using for the CC `${SDK_INSTALL_PATH}/tools/boot/sbl_prebuilt/am263x-cc/sbl_qspi.release.tiimage`

  • here are DIP switches to change what boot mode will take effect, on a custom PCB, how can I program the AM2634 ROM for these different boot modes? Is there a separate guide for this?

    You will need to use an external DIP switch or reduced set of switches for the configuration of Boot mode. 

  • but what SBL should we use for the stand alone AM2634 when its on our PCB?
    This is the SBL i am using for the CC `${SDK_INSTALL_PATH}/tools/boot/sbl_prebuilt/am263x-cc/sbl_qspi.release.tiimage`

    This should be a good start, you can continue to use the sbl, but eventually you may need to modify the sbl for your use case and your own PCB.

    The source for the sbl_qspi is located in the SDK here: 

    mcu_plus_sdk_am263//examples/drivers/boot/sbl_qspi

  • Hi 

    we have a flash chip that doesn’t have QSPI enabled from the factory. Do you know if the AM2634 will send a command to enable QSPI during initiation of the writing of SBL or program to flash, or if this needs to be done offline before programming can be successfully performed?

  • Do you know if the AM2634 will send a command to enable QSPI during initiation of the writing of SBL or program to flash

    If you are using QSPI boot mode, then ROM expects QE bit to be set before you power on the board.

    So this needs to be preprogramed.

    In DEV boot mode you can run the QSPI flash io example and configure the flash properties in syscfg to enable QE bit, Then load the program via JTAG. Then from next iteration you can use QSPI boot mode.

    For mass production, I would suggest to do that offline.