SDP [EVK-MIMXRT1060]: "WRITE_FILE" error when using packets > 256Byte

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

SDP [EVK-MIMXRT1060]: "WRITE_FILE" error when using packets > 256Byte

268 Views
vaerov
Contributor I

SDP [EVK-MIMXRT1060]: "WRITE_FILE" error on when using packets > 256Byte

Hi All,

I using the imx_usb_loader application to write the image via the SDP "WRITE_FILE" API.

The image size is 0x1ff00 and the load address is 0x100.
I have configured the board to boot from USB and using the default flexRAM configuration:
(128KB ITC: 0x0->0x20000).

in "imx_usb_loader" we can control the size of the SDP REPORT2 packet size we transmit (In the SPEC the size is limited to 1024Byte).

when i try to use the maximum size of 1024Byte, the bootrom is crashing on the last chunk (0x1fc00 -> 0x1ff00), i can see that the USB bootrom device is enumerated and assigned with new address on my local laptop (which is connected to the EVK).

is there a limitation (known bug) that using packet size greater than 256Byte when writing a file of 0x1ff00 size?

### logs (with 1024 packet size - FAILURE)
my configuration file:

 

 

imxrt1060_usb
#hid/bulk,[old_header,]max packet size, dcd_addr
hid,1024,0x0
#load
test.bin:jump header

 

 


report=2, cnt=400
load_file:foffset=1f800, cnt=400, remaining=700
0001f900: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001f920: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001f940: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001f960: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001f980: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001f9a0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001f9c0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001f9e0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fa00: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fa20: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fa40: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fa60: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fa80: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001faa0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fac0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fae0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fb00: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fb20: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fb40: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fb60: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fb80: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fba0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fbc0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fbe0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fc00: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fc20: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fc40: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fc60: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fc80: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fca0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fcc0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fce0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
report=2, cnt=400
load_file:foffset=1fc00, cnt=300, remaining=300
0001fd00: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fd20: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fd40: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fd60: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fd80: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fda0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fdc0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fde0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fe00: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fe20: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fe40: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fe60: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fe80: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fea0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fec0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fee0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001ff00: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001ff20: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001ff40: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001ff60: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001ff80: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001ffa0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001ffc0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001ffe0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
report=2, cnt=300

<<<130816, 130816 bytes>>>
report=3, cnt=40
libusb_interrupt_transfer, err=-1, trans=0
report 3 in err=-1, last_trans=0 00 00 00 00


### logs with 256 packet size (SUCCESS)
my configuration file:

 

 

imxrt1060_usb
#hid/bulk,[old_header,]max packet size, dcd_addr
hid,256,0x0
#load
test.bin:jump header

 

 

report=2, cnt=100
load_file:foffset=1fc00, cnt=100, remaining=300
0001fd00: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fd20: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fd40: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fd60: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fd80: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fda0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fdc0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fde0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
report=2, cnt=100
load_file:foffset=1fd00, cnt=100, remaining=200
0001fe00: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fe20: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fe40: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fe60: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fe80: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fea0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fec0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001fee0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
report=2, cnt=100
load_file:foffset=1fe00, cnt=100, remaining=100
0001ff00: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001ff20: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001ff40: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001ff60: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001ff80: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001ffa0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001ffc0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
0001ffe0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
report=2, cnt=100

<<<130816, 130816 bytes>>>
report=3, cnt=40
libusb_interrupt_transfer, err=0, trans=5
report 3 in err=0, last_trans=4 56 78 78 56
report=4, cnt=40
libusb_interrupt_transfer, err=0, trans=65
report 4 in err=0, last_trans=64 88 88 88 88
succeeded (security 0x56787856, status 0x88888888)
load file took 690709 us, rate 189393 Bps

 

 

0 Kudos
0 Replies