Command line flash programming error - load failure: Ef(4)

Discussion created by lpcware Employee on Jun 15, 2016
Latest reply on Jun 15, 2016 by lpcware
Content originally posted in LPCWare by JAlvarez on Thu Aug 02 18:36:02 MST 2012
I get a "load failure: Ef(4)" when using the command line programming tool to flash a 91KB binary to an LPC4330 board with SPIFI flash using a Red Probe+. The command output is shown below. The GUI flash programmer from the LPCXpresso IDE also displays an error (06: File 'ostest.bin' load failure: Ef(4). Flash operation failed.) after downloading about 64KB of the binary. I get the same error with an LPC-Link (after initializing it and adding the -wire=hid option to the command below). Flash programming of small binaries works fine. The build uses Makefiles, not the LPCXpresso IDE.

Besides the 128K limit, are there other limits in the standalone flash programmer?


C:\Projects\ostest>C:\nxp\LPCXpresso_4.2.3_292\lpcxpresso\bin\crt_emu_lpc18_43_nxp -pLPC4330 -load-base=0x14000000 -flash-load-exec=ostest.bin -flash-driver=C:\nxp\LPCXpresso_4.2.3_292\lpcxpresso\bin\Flash\LPC1850A_4350A_SPIFI.cfx
Ni: LPCXpresso Debug Driver v4.0 (May 21 2012 21:42:30)
Nc: Looked for chip XML file in C:/nxp/LPCXpresso_4.2.3_292/lpcxpresso/bin/LPC4330.xml

Nc: Looked for vendor directory XML file in C:/nxp/LPCXpresso_4.2.3_292/lpcxpresso/bin/nxp_directory.xml

Nc: Found generic directory XML file in C:/nxp/LPCXpresso_4.2.3_292/lpcxpresso/bin/crt_directory.xml

Nc: Emu(0): Conn&Reset. DpID: 2BA01477. Info: FTV7X6ZPA
Nc: SWD Frequency: 3000 KHz. RTCK: False. Vector catch: False.
Nc: Packet delay: 16  Poll delay: 0.
Nc: Loaded C:\nxp\LPCXpresso_4.2.3_292\lpcxpresso\bin\Flash\LPC1850A_4350A_SPIFI.cfx: SPIFI on LPC18xx/43xx @0x14000000 Jan 24 2012 10:07:55  External Flash Device on SPI

Nc: NXP: LPC4330  Part ID: 0x00000000
Cr:v Registered license, download limit of 128K
Nt: Loading binary file 'ostest.bin' at location 14000000
Wc: Target driver error code: 1
Ed:06: File 'ostest.bin' load failure: Ef(4). Flash write operation failed.