Hello community & support,
I'm using LS1012A-FRWY and was trying to flash secure boot but I messed up and ended with board not able to enter BL33/U-boot. I guess U-boot needs to be reflashed. Current boot log is attached.
I downloaded CodeWarrior for QorlQ and was able to connect to board, using CMSIS-DAP and config USE_SAFE_RCW = False (screenshot attached). Thereby I guess RCW is not corrupted - correct me if I'm wrong.
Please can you provide me with some guideline or point me how to flash U-boot using CMSIS-DAP.
1. Please refer to section "3.2 Working with bareboard application" in C:\Freescale\CW4NET_v2020.06\CW_ARMv8\ARMv8\Help\Getting_Started_for_CW_ARMv8.pdf to create a bareboard project in CodeWarrior IDE to connect to the target board.
2. Please refer to section "7.7 Using flash programmer from eclipse IDE" in C:\Freescale\CW4NET_v2020.06\CW_ARMv8\ARMv8\Help\PDF\ARMv8_Targeting_Manual to do flash programming in CodeWarrior IDE.
@yipingwang thank you for your answer.
I followed your first document ch. 3.2 to run "Hello World" example and placed breakpoint at line 66 (printf). After running Debug (download procedure start and finished within few minutes) execution doesn't stop at line 66. On serial terminal I'm still getting same booting.log sequence as in first post. No error during downloading procedure was reported. Screenshot debug.png attached. Why?
As of 2nd document you suggested I tried to flash fip.bin to region 0x60000 using device QSPI according to LSDK documentation. Getting "Flash programming operation failed.", check flash_fail.png. Do you know why? Is there a way to get more information on failure reason?
Remember I'm using CMSIS-DAP!
1. You need to program fip.bin at 0x00100000 on QSPI flash according to section "LSDK memory layout and Userland" in LSDK document.
2. Please enable hard-coded RCW in CodeWarrior initialization file.
In Target Connections panel, please double click LS1012A_FRWY(1) to open "Target Initialization File" panel, please modify "USE_SAFE_RCW = False" to "USE_SAFE_RCW = True", then save the configuration, and try above operations again.
3. Please do flash programming with command lines method, please refer to the step by step manual in https://community.nxp.com/t5/NXP-Designs/JTAG-Connection-and-Flash-Programming-Problem-LS1012A/m-p/1...
Sorry it took me longer to get back as my CW trial expired and had to request an extension.
2) I tried step 2. however I'm unable to reproduce it as I'm limited to using CMSIS-DAP only and when I try to execute flasher in CW I get message:
RCW override is not available with CMSIS-DAP connection
3) I tried that one as well. Placed 4.7k ohm R50 according to schematics (attached photo). When board powered D1 is constant red. Edited cwflash.py file as well (attached, and working when R50 off). I'm getting an error with similar context as in 2):
(gdb) source C:\Freescale\CW4NET_v2020.06\CW_ARMv8\ARMv8\gdb_extensions\flash\cwflash.py Starting flash programmer services... Starting local server... Successfully started gdb server 127.0.0.1:45001 Set gdb remote timeout to 7200 Connecting to target... Using LS1012A SoC Using CMSIS-DAP Using jtag speed 16000 Connecting to probe... connected successfully Successfully connected to probe Initializing target... Running init script c:\freescale\cw4net_v2020.06\cw_armv8\armv8\gdb_extensions\flash\scripts/../../../../Config/boards/LS1012A_FRWY_init.py RCW error diagnostic is not available with CMSIS-DAP connection. Error: fail to initialize target Closing debugger server... Error: fail to start flash programming services. (gdb)
CONCLUSION: To be able to flash device when in hardcoded RCW you need to use CodeWarrior TAP. Am I correct?
The main problem of using only CMSIS_DAP is the ability to recover the board using RCW override. In case the RCW is missing from the board, you'll not be able to recover the board over CMSIS-DAP. This feature is available in this moment only over jtag.
My question is - if my board is really missing RCW, how come that in boot process I end up in LS1012 BL31 Phase (look at log in my 1st post)? According to TF-A description RCW/PBL is first loaded image, meaning BL31comes afterwards.