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.

[参考译文] AM263PX-AM263Px:MCU-PLUS-SDK–如何使基于闪存的程序可引导

Guru**** 2378650 points
请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

https://e2e.ti.com/support/microcontrollers/arm-based-microcontrollers-group/arm-based-microcontrollers/f/arm-based-microcontrollers-forum/1522872/mcu-plus-sdk-am263px-am263px-how-to-make-flash-based-program-bootable

器件型号:MCU-PLUS-SDKAM263PX-AM263PX
主题中讨论的其他部件:ASH

工具/软件:

尊敬的 TI 社区:

我正在使用 AM263Px 器件、目前正在开发超出可用 2MB RAM 的程序。 为了管理存储器限制、我将文本段、代码和只读数据段移到了中 闪存中

现在、我想问: 如何使这个基于闪存的程序可引导?

请提供任何指导或参考。

提前感谢!

此致、

Aymen Salem

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    您好感谢您的查询,请允许我明天返回这里。

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    是的、确定

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    您好、

    步骤 1:请确保您使用的是最新的 SDK 102。

    步骤 2:在应用程序中、您需要进行以下更改:

    在 syscfg 中为 FL;ash 添加 MPU 配置、如下所示:

    在文本段中添加.text 和.rodata.cfg(启用了对齐和填充,应放置在 OCRAM 中)

    接下来、将代码和 rodata 放入闪存中

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    然后、重新编译示例并使用以下步骤刷写 SBL 和应用:

    software-dl.ti.com/.../GETTING_STARTED_FLASH.html

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    感谢您的答复。

    我已经完成了上一步。 现在、代码构建成功、我能够刷写它。 但是、刷写后、电路板似乎恢复到 QSPI 引导模式、但在日志中、我可以看到与处于 UART 引导模式时相同的输出、如所附的屏幕截图所示。

    #-----------------------------------------------------------------------------#
    #                                                                             #
    #      DEFAULT CONFIGURATION FILE TO BE USED WITH THE FLASHWRITER SCRIPT      #
    #                                                                             #
    #-----------------------------------------------------------------------------#
    #
    # By default this config file,
    # - points to pre-built flash writer, bootloader for this EVM
    # - The application image points to relative path of the ipc echo application image for this EVM
    #   - Make sure this application is built before running this script
    # - You can customized this config file to point to your own bootloader and/or application images
    # - You can use --operation=flashverify if you just want to verify the flash contents and not flash the file.
    #
    
    # First point to sbl_uart_uniflash binary, which function's as a server to flash one or more files
    --flash-writer=sbl_prebuilt/am263px-lp/sbl_uart_uniflash.release.tiimage
    
    # Now send one or more files to flash or flashverify as needed. The order of sending files does not matter
    
    # Program the OSPI PHY tuning attack vector
    --operation=flash-phy-tuning-data
    
    # When sending bootloader make sure to flash at offset 0x0. ROM expects bootloader at offset 0x0
    --file=sbl_prebuilt/am263px-lp/sbl_ospi_fastboot.release.tiimage --operation=flash --flash-offset=0x0
    
    # When sending application image, make sure to flash at offset 0x80000 (default) or to whatever offset your bootloader is configured for
    --file=../../../../Users/a.salem/workspace_v12/project/Debug/project.appimage --operation=flash --flash-offset=0x80000
    
    # send the XIP image for this application, no need to specify flash offset since flash offset is specified within the image itself
    --file=../../../../Users/a.salem/workspace_v12/project/Debug/project.appimage_xip --operation=flash-xip
    
    

    我是否需要修改闪存配置文件中的某些内容(我已共享了该文件)? 另外、您能否提供有关如何调试代码的建议?

    谢谢

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    可以尝试使用 sbl_ospi 而不是 sbl_ospi_flastboot(此 SBL 仅用于安全转换样本)

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    已测试。 我也有同样的问题

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    什么是引导开关配置?是 OSPI 还是 QSPI?

    我在终端使用 MCU PLUS SDK 10.2 进行了测试、运行正常。

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    OSPI 引导模式  

    引导模式[1:4]= 0011

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    我不能理解为什么它对你不起作用?

    您能告诉我您正在升级 E1/E2 或 RevA 的电路板版本吗? 您可以附加电路板的图片、我可以从中弄清楚。

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    是的、确定。  
    这是电路板  


    这是存储器分配


  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    刷写后是否对电路板进行电源复位?

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    是的

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    我认为这可能是问题:

    映像的偏移量应为 0x81000

    文件中也提到了同样的情况:

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    感谢您的支持问题已解决