Error while Flashing imX95 board

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Error while Flashing imX95 board

Jump to solution
2,339 Views
Abhishek05
Contributor I

I am using the NXP i.MX 95 Eval Kit. I have migrated a custom application to FreeRTOS. The migration is completed, and the code is compiling. But while flashing, I am getting the error [HID(W): LIBUSB_ERROR_PIPE] using uuu tool. 


Wait for Known USB Device Appear...
New USB Device Attached at 2:2-A027376C1F1041DB
2:2-A027376C1F1041DB>Start Cmd:SDPS: boot -f flash.bin
49%2:2-A027376C1F1041DB>Fail HID(W): LIBUSB_ERROR_PIPE (-9)(5.698s)

For adding my custom files into project, I have used the below methods, there are around 50 files to be added to the project.


file(GLOB ADDITIONAL_SOURCES1 "${ProjDirPath}/../HLAC_Proteus/Source/*.cpp")
set(ADDITIONAL_SOURCES
${ADDITIONAL_SOURCES1}
${ADDITIONAL_SOURCES2}
${ADDITIONAL_SOURCES3}
list(APPEND ADDITIONAL_SOURCES
    "${ProjDirPath}/../freertos_hello.cpp"
    "${ProjDirPath}/../board.h"
    "${ProjDirPath}/../board.cpp"
    "${ProjDirPath}/../hal_config.h"
    "${ProjDirPath}/../clock_config.h"
    "${ProjDirPath}/../clock_config.cpp"
    "${ProjDirPath}/../pin_mux.cpp"
    "${ProjDirPath}/../pin_mux.h"
    "${ProjDirPath}/../hardware_init.cpp"
    "${ProjDirPath}/../app.h"
    "${ProjDirPath}/../FreeRTOSConfig_Gen.h"
    "${ProjDirPath}/../mcux_config.h"
)
If not using the additional files, the bin file is flashing, but with this additional file the code is compiling but not flashing on the board. 
Please Help

0 Kudos
Reply
1 Solution
1,869 Views
JorgeCas
NXP TechSupport
NXP TechSupport

Hello,

Since it is not possible to expand this capacity, I suggest you take a look in optimization side for your application.

Best regards.

View solution in original post

0 Kudos
Reply
13 Replies
2,304 Views
JorgeCas
NXP TechSupport
NXP TechSupport

Hello,

We do not have documentation regarding FreeRTOS porting. I strongly suggest you confirm the steps you are following with software provider, here some steps you can use to troubleshoot and solve your issue: 

- Update UUU to the last version.

- Verify the files paths of additional software added.

- Add additional files incrementally to verify what could be causing the issue.

Best regards.

 

0 Kudos
Reply
2,288 Views
Abhishek05
Contributor I
Hello JorgeCas,
1. Which is the latest version of UUU? If uuu is fine, as basic hello world programs are running fine.
2. Additional paths are perfect.
3. I can't add additional files incrementally, as all files are interdependent. So all files need to be there for proper compilation.
For normal FreeRTOS Hello World Code M7 partition size is
22528 bytes (23 kB, 22 KiB) copied, 0.000158571 s, 142 MB/s
42+1 records in
42+1 records out
21844 bytes (22 kB, 21 KiB) copied, 0.000219649 s, 99.4 MB/s
M7 file_offset = 0xbbc00 size = 0x5800

For my Application, when compiled and made flash.bin M7 partition is
604160 bytes (604 kB, 590 KiB) copied, 0.00161078 s, 375 MB/s
1179+1 records in
1179+1 records out
603808 bytes (604 kB, 590 KiB) copied, 0.00341523 s, 177 MB/s
M7 file_offset = 0xbbc00 size = 0x93800

Are there some restrictions here?
0 Kudos
Reply
2,267 Views
JorgeCas
NXP TechSupport
NXP TechSupport

Hello,

1. The latest UUU version is uuu_1.5.201.

2. Got it.

3. There is not a limitation in file size, but I suggest you check with software provider.

Could you please share the UUU command/script you are using?

Best regards

0 Kudos
Reply
2,238 Views
Abhishek05
Contributor I
1. Got it Thanks. I am using this on only
3. uuu -b sd flash.bin
0 Kudos
Reply
2,168 Views
JorgeCas
NXP TechSupport
NXP TechSupport

Hello,

I asked internally and this issue is caused by TCM space dedicated to Cortex-M, which is 256 kB / 512 kB.

Your application exceeds this limit.

Best regards.

0 Kudos
Reply
2,122 Views
Abhishek05
Contributor I
Thanks a lot for your help. Is there any way to increase this limit?
Also one more thing how you concluded that my application exceeds this limit? By which parameter you judged it ?

0 Kudos
Reply
2,113 Views
JorgeCas
NXP TechSupport
NXP TechSupport

Hello,

This memory cannot be increased.

This can be verified in table 1 "Arm Cortex-M33 and Cortex-M7 platform" of datasheet.

Best regards.

0 Kudos
Reply
2,067 Views
Abhishek05
Contributor I
Thanks a lot for letting me know this.
I just want to know how did you infer this issue from below data
604160 bytes (604 kB, 590 KiB) copied, 0.00161078 s, 375 MB/s
1179+1 records in
1179+1 records out
603808 bytes (604 kB, 590 KiB) copied, 0.00341523 s, 177 MB/s
M7 file_offset = 0xbbc00 size = 0x93800
or any other method you used to infer this. As i need to document this thing.
Thanks
0 Kudos
Reply
2,044 Views
JorgeCas
NXP TechSupport
NXP TechSupport

Hello,

I just inferred this by the size of your application. We saw a similar issue in an i.MX93 but it is limited to 256K in that case.

Best regards.

0 Kudos
Reply
2,022 Views
Abhishek05
Contributor I
Hello,
Got it thanks a lot. Is there any way to resolve the issue? I cant reduce the size of application in my case?
Thanks
0 Kudos
Reply
1,870 Views
JorgeCas
NXP TechSupport
NXP TechSupport

Hello,

Since it is not possible to expand this capacity, I suggest you take a look in optimization side for your application.

Best regards.

0 Kudos
Reply
1,849 Views
Abhishek05
Contributor I
Thanks a lot for your help
0 Kudos
Reply
2,326 Views
Abhishek05
Contributor I

While making the Bin file, getting some overshoot in  u-boot-atf-container.img at 1483 KB, psize=1024
Please check


compute2@compute2--7820:/media/compute2/ff458cdb-c21f-4f84-8cc4-3fb3df7ab7e5/M7_Core/project/imx-boot/imx-mkimage$ make SOC=iMX95 flash_all LPDDR_TYPE=lpddr5 OEI=YES
soc.mak:119: "Note: There are no Cortex-A55 oei images"
include autobuild.mak
DDR FW - lpddr5_imem_v202311.bin lpddr5_dmem_v202311.bin lpddr5_imem_qb_v202311.bin lpddr5_dmem_qb_v202311.bin
25257+0 records in
25257+0 records out
101028 bytes (101 kB, 99 KiB) copied, 0.0729454 s, 1.4 MB/s
40230+1 records in
40231+0 records out
321848 bytes (322 kB, 314 KiB) copied, 0.102316 s, 3.1 MB/s
./../mkimage_imx8 -soc IMX9 -append mx95a0-ahab-container.img -c -oei m33-oei-ddrfw.bin m33 0x1ffc0001 0x1ffc0000 -hold 65536 -oei oei-m33-tcm.bin m33 0x1ffc0001 0x1ffc0000 -msel 0 \
-m33 m33_image.bin 0 0x1FFC0000 \
-m7 m7_image.bin 0 0x0 0x303C0000 \
-ap u-boot-spl.bin a55 0x20480000 -dummy 0x8b000000 -out flash.bin
SOC: IMX9
New Container: 0
OEI: m33-oei-ddrfw.bin core: m33 entry addr: 0x1ffc0001 load addr: 0x1ffc0000
HOLD: 65536
OEI: oei-m33-tcm.bin core: m33 entry addr: 0x1ffc0001 load addr: 0x1ffc0000
MSEL: 0
CM33: m33_image.bin core: 0 entry addr: 0x1ffc0000
CM7: m7_image.bin core: 0 entry addr: 0x00000000 load addr: 0x303c0000
AP: u-boot-spl.bin core: a55 addr: 0x20480000
Dummy V2X image at: 0x8b000000
Output: flash.bin
CONTAINER FUSE VERSION: 0x00
CONTAINER SW VERSION: 0x0000
Platform: i.MX9
ivt_offset: 1024
header tag missmatched ca
container image offset (aligned):35000
csf_off 0x35400
flags: 0x10
Hash of the images =
1+0 records in
1+0 records out
322560 bytes (323 kB, 315 KiB) copied, 0.000958095 s, 337 MB/s
628+1 records in
628+1 records out
321848 bytes (322 kB, 314 KiB) copied, 0.00190583 s, 169 MB/s
OEI file_offset = 0x35000 size = 0x4ec00
Hash of the images =
1+0 records in
1+0 records out
5120 bytes (5.1 kB, 5.0 KiB) copied, 0.000127055 s, 40.3 MB/s
8+1 records in
8+1 records out
4128 bytes (4.1 kB, 4.0 KiB) copied, 0.000133723 s, 30.9 MB/s
OEI file_offset = 0x93c00 size = 0x1400
Hash of the images =
1+0 records in
1+0 records out
158720 bytes (159 kB, 155 KiB) copied, 0.000477369 s, 332 MB/s
308+1 records in
308+1 records out
157960 bytes (158 kB, 154 KiB) copied, 0.000971758 s, 163 MB/s
M4 file_offset = 0x95000 size = 0x26c00
Hash of the images =
1+0 records in
1+0 records out
604160 bytes (604 kB, 590 KiB) copied, 0.00161078 s, 375 MB/s
1179+1 records in
1179+1 records out
603808 bytes (604 kB, 590 KiB) copied, 0.00341523 s, 177 MB/s
M7 file_offset = 0xbbc00 size = 0x93800
Hash of the images =
1+0 records in
1+0 records out
145408 bytes (145 kB, 142 KiB) copied, 0.000436619 s, 333 MB/s
282+1 records in
282+1 records out
144494 bytes (144 kB, 141 KiB) copied, 0.000908239 s, 159 MB/s
AP file_offset = 0x14f400 size = 0x23800
V2X Dummy file_offset = 0x172c00 size = 0x0
CST: CONTAINER 0 offset: 0x800
CST: CONTAINER 0: Signature Block: offset is at 0xb10
Offsets = 0x800 0xb10
DONE.
Note: Please copy image to offset: IVT_OFFSET + IMAGE_OFFSET
append u-boot-atf-container.img at 1483 KB, psize=1024
1612+0 records in
1612+0 records out
1650688 bytes (1.7 MB, 1.6 MiB) copied, 0.00898117 s, 184 MB/s

0 Kudos
Reply