查看: 6099|回复: 9

[求助] RT1052 NOR FLASH无法执行

[复制链接]

该用户从未签到

7

主题

26

帖子

0

注册会员

Rank: 2

积分
130
最后登录
2021-6-30
发表于 2021-6-24 14:01:59 | 显示全部楼层 |阅读模式
采用McuXpresso IDE,导入了HelloWorld,在开发板能成功执行,但在我们自己的板上,能下载成功,但到执行的时候就挂着了。
界面如下:
RT1052_00.png RT1052_01.png
请问有遇到过吗?该如何解决?
RT1052_02.png
回复

使用道具 举报

  • TA的每日心情
    奋斗
    2021-5-28 05:36
  • 签到天数: 1 天

    连续签到: 1 天

    [LV.1]初来乍到

    2

    主题

    36

    帖子

    0

    注册会员

    Rank: 2

    积分
    153
    最后登录
    2025-5-20
    发表于 2021-6-24 17:07:08 | 显示全部楼层
    先在RAM中运行看看有没有问题,没问题就检查XIP有没有问题,修改并整片擦除重新下载,再不行就检查硬件吧,看看BOOT_CFG1对应的引脚是不是都拉低了。
    干不完的事
    回复 支持 反对

    使用道具 举报

    该用户从未签到

    7

    主题

    26

    帖子

    0

    注册会员

    Rank: 2

    积分
    130
    最后登录
    2021-6-30
     楼主| 发表于 2021-6-24 20:53:22 来自手机 | 显示全部楼层
    RAM中能运行,也擦除重试过了,BOOT_CFG1都是低位
    回复 支持 反对

    使用道具 举报

    该用户从未签到

    7

    主题

    26

    帖子

    0

    注册会员

    Rank: 2

    积分
    130
    最后登录
    2021-6-30
     楼主| 发表于 2021-6-25 17:01:13 | 显示全部楼层
    1. 552,115 2-list-thread-groups
    2. 552,126 2^done,groups=[{id="i1",type="process"}]
    3. 552,128 (gdb)
    4. 553,129 3-gdb-version
    5. 553,134 ~"GNU gdb (GNU Arm Embedded Toolchain 9-2020-q2-update) 8.3.1.20191211-git\n"
    6. 553,134 ~"Copyright (C) 2019 Free Software Foundation, Inc.\n"
    7. 553,134 ~"License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>\nThis is fre\
    8. e software: you are free to change and redistribute it.\nThere is NO WARRANTY, to the extent permitt\
    9. ed by law."
    10. 553,135 ~"\nType "show copying" and "show warranty" for details.\n"
    11. 553,135 ~"This GDB was configured as "--host=i686-w64-mingw32 --target=arm-none-eabi".\n"
    12. 553,135 ~"Type "show configuration" for configuration details.\n"
    13. 553,135 ~"For bug reporting instructions, please see:\n"
    14. 553,135 ~"<http://www.gnu.org/software/gdb/bugs/>.\n"
    15. 553,135 ~"Find the GDB manual and other documentation resources online at:\n    <http://www.gnu.org/\
    16. software/gdb/documentation/>."
    17. 553,135 ~"\n\n"
    18. 553,135 ~"For help, type "help".\n"
    19. 553,135 ~"Type "apropos word" to search for commands related to "word".\n"
    20. 553,135 3^done
    21. 553,136 (gdb)
    22. 553,137 4-environment-cd E:/McuXpresso/evkbimxrt1050_hello_world
    23. 553,150 4^done
    24. 553,150 (gdb)
    25. 553,150 5-gdb-set breakpoint pending on
    26. 553,164 5^done
    27. 553,164 (gdb)
    28. 553,165 6-gdb-set detach-on-fork on
    29. 553,180 6^done
    30. 553,180 (gdb)
    31. 553,181 7-enable-pretty-printing
    32. 553,196 7^done
    33. 553,196 (gdb)
    34. 553,196 8-gdb-set python print-stack none
    35. 553,212 8^done
    36. 553,212 (gdb)
    37. 553,213 9-gdb-set print object on
    38. 553,228 9^done
    39. 553,228 (gdb)
    40. 553,229 10-gdb-set print sevenbit-strings on
    41. 553,243 10^done
    42. 553,243 (gdb)
    43. 553,244 11-gdb-set host-charset UTF-8
    44. 553,259 11^done
    45. 553,259 (gdb)
    46. 553,260 12-gdb-set target-charset GBK
    47. 553,275 12^done
    48. 553,275 (gdb)
    49. 553,275 13-gdb-set target-wide-charset UTF-16
    50. 553,290 13^done
    51. 553,290 (gdb)
    52. 553,291 14-gdb-set dprintf-style call
    53. 553,306 14^done
    54. 553,306 (gdb)
    55. 553,307 15-gdb-set target-async on
    56. 553,321 15^done
    57. 553,321 (gdb)
    58. 553,322 16-gdb-set record full stop-at-limit off
    59. 553,337 16^done
    60. 553,337 (gdb)
    61. 553,338 17-gdb-set non-stop on
    62. 553,353 17^done
    63. 553,353 (gdb)
    64. 553,354 18-gdb-set auto-solib-add on
    65. 553,369 18^done
    66. 553,369 (gdb)
    67. 553,378 19-file-exec-and-symbols --thread-group i1 E:/McuXpresso/evkbimxrt1050_hello_world/Debug/evk\
    68. bimxrt1050_hello_world.axf
    69. 553,409 19^done
    70. 553,409 (gdb)
    71. 553,413 20-interpreter-exec console "set non-stop on"
    72. 553,433 20^done
    73. 553,433 (gdb)
    74. 553,434 21-interpreter-exec console "set pagination off"
    75. 553,449 =cmd-param-changed,param="pagination",value="off"
    76. 553,449 21^done
    77. 553,449 (gdb)
    78. 553,450 22-interpreter-exec console "set mi-async"
    79. 553,464 22^done
    80. 553,464 (gdb)
    81. 553,465 23-interpreter-exec console "set remotetimeout 60000"
    82. 553,480 =cmd-param-changed,param="remotetimeout",value="60000"
    83. 553,480 23^done
    84. 553,480 (gdb)
    85. 553,576 24-target-select extended-remote | crt_emu_cm_redlink -msg-port=56387 -g -mi -2 -pMIMXRT1052\
    86. xxxxB -vendor=NXP --connectscript=RT1050_connect.scp  --reset= -ProbeHandle=1 -CoreIndex=0 -cache=di\
    87. sable --flash-hashing --flash-driver= -x E:/McuXpresso/evkbimxrt1050_hello_world/Debug --flash-dir C\
    88. :/nxp/MCUXpressoIDE_11.3.0_5222/ide/plugins/com.nxp.mcuxpresso.tools.bin.win32_11.3.0.202101111546/b\
    89. inaries/Flash --flash-dir E:/McuXpresso/.mcuxpressoide_packages_support/MIMXRT1052xxxxB_support/Flas\
    90. [message truncated to 5 lines. More lines can be set in the Preference->Debug->GDB eclipse preference page.]
    91. 555,876 =thread-group-started,id="i1",pid="42000"
    92. 555,876 =thread-created,id="1",group-id="i1"
    93. 555,877 *running,thread-id="1"
    94. 556,008 ~"\nProgram"
    95. 556,008 ~" stopped.\n"
    96. 556,017 ~"0x0020d138 in ?? ()\n"
    97. 556,018 *stopped,reason="signal-received",signal-name="0",signal-meaning="Signal 0",frame={addr="0x0\
    98. 020d138",func="??",args=[],arch="armv7e-m"},thread-id="1",stopped-threads=["1"]
    99. 556,018 24^connected
    100. 556,019 (gdb)
    101. 556,031 25-interpreter-exec console "set mem inaccessible-by-default off"
    102. 556,032 =cmd-param-changed,param="mem inaccessible-by-default",value="off"
    103. 556,032 25^done
    104. 556,032 (gdb)
    105. 556,034 26-interpreter-exec console "mon ondisconnect cont"
    106. 556,050 26^done
    107. 556,050 (gdb)
    108. 556,051 27-interpreter-exec console "set arm force-mode thumb"
    109. 556,052 =cmd-param-changed,param="arm force-mode",value="thumb"
    110. 556,052 27^done
    111. 556,052 (gdb)
    112. 556,054 28-interpreter-exec console "set remote hardware-breakpoint-limit 6"
    113. 556,055 =cmd-param-changed,param="remote hardware-breakpoint-limit",value="6"
    114. 556,055 28^done
    115. 556,055 (gdb)
    116. 556,059 29set range-stepping on
    117. 556,059 &"set range-stepping on\n"
    118. 556,059 29^done
    119. 556,060 (gdb)
    120. 556,062 30-interpreter-exec console "mon semihost enable"
    121. 556,082 30^done
    122. 556,082 (gdb)
    123. 556,083 31-target-download
    124. 556,084 31+download,{section=".boot_hdr",section-size="8192",total-size="1738353"}
    125. 556,084 31+download,{section=".boot_hdr",section-sent="8192",section-size="8192",total-sent="8192",t\
    126. otal-size="1738353"}
    127. 556,098 31+download,{section=".text",section-size="15768",total-size="1738353"}
    128. 556,113 31+download,{section=".data",section-size="4",total-size="1738353"}
    129. 556,439 32-list-thread-groups
    130. 558,275 31^done,address="0x600022f0",load-size="23964",transfer-rate="93608",write-rate="7988"
    131. 558,276 (gdb)
    132. 558,277 32^done,groups=[{id="i1",type="process",pid="42000",executable="E:\\McuXpresso\\evkbimxrt105\
    133. 0_hello_world\\Debug\\evkbimxrt1050_hello_world.axf"}]
    134. 558,277 (gdb)
    135. 558,280 33-interpreter-exec console "mon SWO datasource"
    136. 558,300 34-list-thread-groups i1
    137. 558,305 33^done
    138. 558,306 (gdb)
    139. 558,321 34^done,threads=[{id="1",target-id="Thread 1",details="Runnable",frame={level="0",addr="0x60\
    140. 0022f0",func="ResetISR",args=[],file="../startup/startup_mimxrt1052.c",fullname="E:\\McuXpresso\\evk\
    141. bimxrt1050_hello_world\\startup\\startup_mimxrt1052.c",line="638",arch="armv7e-m"},state="stopped"}]\

    142. 558,322 (gdb)
    143. 558,346 35-gdb-show --thread-group i1 language
    144. 558,346 35^done,value="auto"
    145. 558,346 (gdb)
    146. 558,347 36-gdb-set --thread-group i1 language c
    147. 558,347 36^done
    148. 558,347 (gdb)
    149. 558,348 37-interpreter-exec --thread-group i1 console "p/x (char)-1"
    150. 558,348 ~"$1 = 0xff\n"
    151. 558,348 37^done
    152. 558,348 (gdb)
    153. 558,352 38-data-evaluate-expression --thread-group i1 "sizeof (void*)"
    154. 558,352 39-stack-info-depth --thread 1 11
    155. 558,352 38^done,value="4"
    156. 558,352 (gdb)
    157. 558,352 39^done,depth="1"
    158. 558,353 (gdb)
    159. 558,353 40-gdb-set --thread-group i1 language auto
    160. 558,353 40^done
    161. 558,353 (gdb)
    162. 558,354 41-interpreter-exec --thread-group i1 console "show endian"
    163. 558,355 ~"The target endianness is set automatically (currently little endian)\n"
    164. 558,355 41^done
    165. 558,355 (gdb)
    166. 558,381 42-break-insert -t -h -f main
    167. 558,384 43-stack-select-frame --thread 1 0
    168. 558,403 44-thread-info 1
    169. 558,414 42^done,bkpt={number="1",type="hw breakpoint",disp="del",enabled="y",addr="0x6000288a",func=\
    170. "main",file="../source/hello_world.c",fullname="E:\\McuXpresso\\evkbimxrt1050_hello_world\\source\\h\
    171. ello_world.c",line="35",thread-groups=["i1"],times="0",original-location="main"}
    172. 558,415 (gdb)
    173. 558,415 43^done
    174. 558,415 (gdb)
    175. 558,423 45-exec-continue --thread-group i1
    176. 558,429 44^done,threads=[{id="1",target-id="Thread 1",details="Runnable",frame={level="0",addr="0x60\
    177. 0022f0",func="ResetISR",args=[],file="../startup/startup_mimxrt1052.c",fullname="E:\\McuXpresso\\evk\
    178. bimxrt1050_hello_world\\startup\\startup_mimxrt1052.c",line="638",arch="armv7e-m"},state="stopped"}]\

    179. 558,430 (gdb)
    180. 558,430 45^running
    181. 558,430 *running,thread-id="1"
    182. 558,491 (gdb)
    183. 558,978 46-thread-select 1
    184. 558,993 47-thread-select 1
    185. 558,995 48-thread-select 1
    186. 559,028 46^done,new-thread-id="1"
    187. 559,028 (gdb)
    188. 559,076 47^done,new-thread-id="1"
    189. 559,076 (gdb)
    190. 559,108 48^done,new-thread-id="1"
    191. 559,108 (gdb)
    复制代码
    GDB的跟踪内容,如下:
    回复 支持 反对

    使用道具 举报

    该用户从未签到

    7

    主题

    26

    帖子

    0

    注册会员

    Rank: 2

    积分
    130
    最后登录
    2021-6-30
     楼主| 发表于 2021-6-27 18:44:49 | 显示全部楼层
    1. GNU gdb (GNU Arm Embedded Toolchain 9-2020-q2-update) 8.3.1.20191211-git
    2. Copyright (C) 2019 Free Software Foundation, Inc.
    3. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
    4. This is free software: you are free to change and redistribute it.
    5. There is NO WARRANTY, to the extent permitted by law.
    6. Type "show copying" and "show warranty" for details.
    7. This GDB was configured as "--host=i686-w64-mingw32 --target=arm-none-eabi".
    8. Type "show configuration" for configuration details.
    9. For bug reporting instructions, please see:
    10. <http://www.gnu.org/software/gdb/bugs/>.
    11. Find the GDB manual and other documentation resources online at:
    12.     <http://www.gnu.org/software/gdb/documentation/>.

    13. For help, type "help".
    14. Type "apropos word" to search for commands related to "word".

    15. Program stopped.
    16. 0x0020c7a2 in ?? ()
    复制代码

    0x0020c7a2是BOOTROM的地址段,如何知道这个地址是干什么?
    回复 支持 反对

    使用道具 举报

    该用户从未签到

    712

    主题

    6371

    帖子

    0

    超级版主

    Rank: 8Rank: 8

    积分
    24866
    最后登录
    2025-7-18
    发表于 2021-6-28 10:16:21 | 显示全部楼层
    老鹰(深圳) 发表于 2021-6-27 18:44
    0x0020c7a2是BOOTROM的地址段,如何知道这个地址是干什么?

    你有没有先跑下这个代码?
    SDK_2.9.1_EVKB-IMXRT1050\boards\evkbimxrt1050\driver_examples\flexspi\nor\polling_transfer
    在RAM中跑,看看你的外部flash是否能够都顺利完成擦写读等,还有你的外部QSPI你要看看,要检查下QEbit位,和你的flash芯片一致。对于新的QSPI flash一定要执行。
    还有,RT1052的芯片你需要修改位internal boot模式。
    你先检查下这几个点,如果还有问题,欢迎继续交流!
    回复 支持 反对

    使用道具 举报

    该用户从未签到

    7

    主题

    26

    帖子

    0

    注册会员

    Rank: 2

    积分
    130
    最后登录
    2021-6-30
     楼主| 发表于 2021-6-28 15:05:17 | 显示全部楼层
    小恩GG 发表于 2021-6-28 10:16
    你有没有先跑下这个代码?
    SDK_2.9.1_EVKB-IMXRT1050\boards\evkbimxrt1050\driver_examples\flexspi\nor ...

    跑了的,这个没有问题。
    回复 支持 反对

    使用道具 举报

    该用户从未签到

    7

    主题

    26

    帖子

    0

    注册会员

    Rank: 2

    积分
    130
    最后登录
    2021-6-30
     楼主| 发表于 2021-6-30 13:38:19 | 显示全部楼层
    自己顶一下
    回复 支持 反对

    使用道具 举报

  • TA的每日心情
    奋斗
    2021-5-28 05:36
  • 签到天数: 1 天

    连续签到: 1 天

    [LV.1]初来乍到

    2

    主题

    36

    帖子

    0

    注册会员

    Rank: 2

    积分
    153
    最后登录
    2025-5-20
    发表于 2021-6-30 14:12:52 | 显示全部楼层

    也替你着急呀,脱离开发环境跑个闪灯试试吧。
    干不完的事
    回复 支持 反对

    使用道具 举报

    该用户从未签到

    712

    主题

    6371

    帖子

    0

    超级版主

    Rank: 8Rank: 8

    积分
    24866
    最后登录
    2025-7-18
    发表于 2021-7-2 14:40:59 | 显示全部楼层
    楼主你好!
    你使用MCUBootUtility工具下载个LED闪灯代码试试,看看是否可以工作?
    还有,你如果IDE debug,RAM工程能成功跑起来吗?
    如果RAM 可以,flash RAM那个也跑的很顺,你需要检查下你的启动模式,是不是放到serial download模式了,你需要修改为internal boot模式。
    回复 支持 反对

    使用道具 举报

    您需要登录后才可以回帖 注册/登录

    本版积分规则

    关闭

    站长推荐上一条 /3 下一条

    Archiver|手机版|小黑屋|恩智浦技术社区

    GMT+8, 2025-7-19 09:58 , Processed in 0.105799 second(s), 29 queries , MemCache On.

    Powered by Discuz! X3.4

    Copyright © 2001-2024, Tencent Cloud.

    快速回复 返回顶部 返回列表