Hi yipingwang,
I have modified the target initialization file, but still erase and program failed.
USE_SAFE_RCW = False -> USE_SAFE_RCW = True
QSPI_BOOT = 0 -> QSPI_BOOT = 1
if QSPI_BOOT:
# Add QSPI device
# fl.add_device({"alias": "qspi", "name": "S25FS512S", "address": 0x20000000, "ws_address": 0x18000000, "ws_size": 0x1FFFF, "geometry": "8x1", "controller": "QSPI"})
fl.add_device({"alias": "qspi", "name": "MT25QU512ABA", "address": 0x20000000, "ws_address": 0x18000000, "ws_size": 0x1FFFF, "geometry": "8x1", "controller": "QSPI"})
otherwise, we use flash type is MT25QU512ABB, we also try to add flash drive, add file MT25QU512ABB.xml, but have the same problem.
C:\Freescale\CW4NET_v2020.06\CW_ARMv8\Config\flash\devices\MT25QU512ABB.xml
<device-file>
<device>
<content>
<device_parameters>
<device_type>spi</device_type>
<manufacturerid>0x20</manufacturerid>
</device_parameters>
<name>MT25QU512ABB</name>
<sectors>
<sector count="1024" size="0x10000"/>
</sectors>
<organizations>
<organization depth="64M" width="8">
<id>0xBB20</id>
<algorithm>
<fpinclude href="algorithms/MT25QU512ABA.xml"/>
</algorithm>
</organization>
</organizations>
</content>
</device>
</device-file>

Best Regards
Qiuju.ye