GUI Flash Tool - which connect script?

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

GUI Flash Tool - which connect script?

Jump to solution
3,785 Views
superaga
Contributor III

Hi all,

I'm developing using the LPCXpresso1125.

I've been able to successfully debug and complete the program using the on-board CMSIS-DAP.

I've been able to generate the release (both the afx and the bin) files.

I've been able to program it using the J-Link through the GUI Flash Tool.

I'd like to program it using the on-board CMSIS-DAP through the GUI Flash Tool, but I don't know which Connect script use, where do I find this information? I wasn't able to find it.

Of course I tried to program the device leaving the Connect script empty, but when I press Run... nothing happens...

Many thanks!

Kind regards,

AGA

0 Kudos
1 Solution
3,680 Views
superaga
Contributor III

Hi @lpcxpresso_supp,

I think that I discovered a workaround to successfully flash the MCU even with the Relase afx.

Here the procedure I used to do it:

  • Build the project as Debug or Release selecting the type from the hammer icon on the toolbar (see picture build_debug_release).
  • Open the GUI Flash Tool (from the toolbar).
    • Leave the File to program to its default path.
  • Press Run to flash the MCU.

When I went through the process after selecting the Debug build I could successfully flash the unit.

When I went through the process after selecting the Release build I couldn't flash the unit.

 

Then this morning I though: What about if I use the Debug build "procedure", but before flash the unit I chose the release build? Doing that I've been able to successfully flash the unit!

So the workaround process is:

  • Build the project as Debug selecting the type from the hammer icon on the toolbar (see picture build_debug_release).
  • Open the GUI Flash Tool (from the toolbar).
    • Change the File to program to the Release path (see picture flash_workaround).
  • Press Run to flash the MCU.

Here the GUI Flash Tool Console output:

Executing flash operation 'Program' (Program file into flash: low_level_clutchTrainer.axf) - Mon Jan 23 09:59:34 CET 2023
Checking MCU info...
Scanning for targets...
Executing flash action...
MCUXpresso IDE RedlinkMulti Driver v11.6 (Jul 12 2022 16:58:24 - crt_emu_cm_redlink.exe build 4)
( 0) Reading remote configuration
Wc(03). No cache support.
Found part description in XML file LPC112x.xml
( 5) Remote configuration complete
Reconnected to existing LinkServer process.
Probe Firmware: LPC-LINK2 CMSIS-DAP V5.361 (NXP Semiconductors)
Serial Number: JQAWBQBR
VID:PID: 1FC9:0090
USB Path: \\?\hid#vid_1fc9&pid_0090&mi_00#c&2f6d6290&0&0000#{4d1e55b2-f16f-11cf-88cb-001111000030}
Using memory from core 0 after searching for a good core
( 30) Emulator Connected
( 40) Debug Halt
( 50) CPU ID
debug interface type = CoreSight DP (DAP DP ID 0BB11477) over SWD TAP 0
processor type = Cortex-M0 (CPU ID 00000C20) on DAP AP 0
number of h/w breakpoints = 4
number of flash patches = 0
number of h/w watchpoints = 2
Probe(0): Connected&Reset. DpID: 0BB11477. CpuID: 00000C20. Info: <None>
Debug protocol: SWD. RTCK: Disabled. Vector catch: Disabled.
Content of CoreSight Debug ROM(s):
RBASE E00FF000: CID B105100D PID 04000BB471 ROM (type 0x1)
ROM 1 E000E000: CID B105E00D PID 04000BB008 Gen SCS (type 0x0)
ROM 1 E0001000: CID B105E00D PID 04000BB00A Gen DWT (type 0x0)
ROM 1 E0002000: CID B105E00D PID 04000BB00B Gen FPB (type 0x0)
NXP: LPC1125/303
DAP stride is 1024 bytes (256 words)
Inspected v.2 On-chip Flash Memory LPC11_12_13_64K_8K.cfx
Image 'LPC11_12_13 (64K Flash, min 8K RAM) Jul 7 2022 12:18:00'
( 65) Chip Setup Complete
Connected: was_reset=true. was_stopped=false
( 70) License Check Complete
Loading 'low_level_clutchTrainer.axf' ELF 0x00000000 len 0x13A0
Opening flash driver LPC11_12_13_64K_8K.cfx
Sending VECTRESET to run flash driver
Flash device supported (64KB = 16*4K at 0x0)
Writing 5024 bytes to address 0x00000000 in Flash
1 of 1 ( 0) Writing sectors 0-1 at 0x00000000 with 5024 bytes
( 0) at 00000000: 0 bytes - 0/5024
( 81) at 00000000: 4096 bytes - 4096/5024
(100) at 00001000: 4096 bytes - 8192/5024
Sectors written: 2, unchanged: 0, total: 2
Erased/Wrote sector 0-1 with 5024 bytes in 200msec
Closing flash driver LPC11_12_13_64K_8K.cfx
(100) Finished writing Flash successfully.
Flash Write Done
Loaded 0x13A0 bytes in 261ms (about 19kB/s)
Reset target (system)
Starting execution using system reset

I think that this is a bug for this IDE release (MCUXpresso IDE v11.6.0 [Build 8187] [2022-07-13]), but I didn't try to any other previous versions.

Can you confirm it?

Many thanks!

AGA

View solution in original post

0 Kudos
8 Replies
3,766 Views
brendonslade
NXP TechSupport
NXP TechSupport

Did you try with no connect script? Not all targets need one.

0 Kudos
3,760 Views
superaga
Contributor III

Hi @brendonslade,

many thanks for your reply.

Yes I did it. Looks that I can flash the Debug afx, but I can't flash the Release afx.

Are you aware about some limitation using the on-board LPC-Link2?

One more clarification: Why not all devices need one? What does this script? What is its role in the flashing process?

Many thanks!

Kind regards,

AGA

0 Kudos
3,753 Views
RaRo
NXP TechSupport
NXP TechSupport

Hello @superaga,

Please take a look to MCUXpresso IDE User Manual Chapter 14. The GUI Flash Tool, there you may find relevant information related with the tool and the Connect script usage. You can obtain it here in Documentation: MCUXpresso IDE for NXP MCUs

Also, could you please build again the release? Programming a release .afx file leaving the Connect script empty for the LPCXpresso1125 should work properly; what are you getting by clicking Run…?

Regards, Raul.

0 Kudos
3,733 Views
superaga
Contributor III

Hi @RaRo,

yes I already read the ch 14 but I didn't find anything more than what I already know.

Yes I already tried several times with the Release build but when I press Run nothing happen except that the dialog closes (see the flash_release picture).

If I instead try to do the very same, but with the Debug build I can successfully flash the MCU (see the flash_debug picure).

Here the log for the flash in the console:

Executing flash operation 'Program' (Program file into flash: low_level_clutchTrainer.axf) - Fri Jan 20 08:50:55 CET 2023
Checking MCU info...
Scanning for targets...
Executing flash action...
MCUXpresso IDE RedlinkMulti Driver v11.6 (Jul 12 2022 16:58:24 - crt_emu_cm_redlink.exe build 4)
( 0) Reading remote configuration
Wc(03). No cache support.
Found part description in XML file LPC112x.xml
( 5) Remote configuration complete
Reconnected to existing LinkServer process.
Probe Firmware: LPC-LINK2 CMSIS-DAP V5.361 (NXP Semiconductors)
Serial Number: JQAWBQBR
VID:PID: 1FC9:0090
USB Path: \\?\hid#vid_1fc9&pid_0090&mi_00#c&2f6d6290&0&0000#{4d1e55b2-f16f-11cf-88cb-001111000030}
Using memory from core 0 after searching for a good core
( 30) Emulator Connected
( 40) Debug Halt
( 50) CPU ID
debug interface type = CoreSight DP (DAP DP ID 0BB11477) over SWD TAP 0
processor type = Cortex-M0 (CPU ID 00000C20) on DAP AP 0
number of h/w breakpoints = 4
number of flash patches = 0
number of h/w watchpoints = 2
Probe(0): Connected&Reset. DpID: 0BB11477. CpuID: 00000C20. Info: <None>
Debug protocol: SWD. RTCK: Disabled. Vector catch: Disabled.
Content of CoreSight Debug ROM(s):
RBASE E00FF000: CID B105100D PID 04000BB471 ROM (type 0x1)
ROM 1 E000E000: CID B105E00D PID 04000BB008 Gen SCS (type 0x0)
ROM 1 E0001000: CID B105E00D PID 04000BB00A Gen DWT (type 0x0)
ROM 1 E0002000: CID B105E00D PID 04000BB00B Gen FPB (type 0x0)
NXP: LPC1125/303
DAP stride is 1024 bytes (256 words)
Inspected v.2 On-chip Flash Memory LPC11_12_13_64K_8K.cfx
Image 'LPC11_12_13 (64K Flash, min 8K RAM) Jul 7 2022 12:18:00'
( 65) Chip Setup Complete
Connected: was_reset=true. was_stopped=false
( 70) License Check Complete
Loading 'low_level_clutchTrainer.axf' ELF 0x00000000 len 0x2224
Opening flash driver LPC11_12_13_64K_8K.cfx
Sending VECTRESET to run flash driver
Flash device supported (64KB = 16*4K at 0x0)
Writing 8740 bytes to address 0x00000000 in Flash
1 of 1 ( 0) Writing sectors 0-2 at 0x00000000 with 8740 bytes
( 0) at 00000000: 0 bytes - 0/8740
( 46) at 00000000: 4096 bytes - 4096/8740
( 93) at 00001000: 4096 bytes - 8192/8740
(100) at 00002000: 4096 bytes - 12288/8740
Sectors written: 3, unchanged: 0, total: 3
Erased/Wrote sector 0-2 with 8740 bytes in 282msec
Closing flash driver LPC11_12_13_64K_8K.cfx
(100) Finished writing Flash successfully.
Flash Write Done
Loaded 0x2224 bytes in 339ms (about 25kB/s)
Reset target (system)
Starting execution using system reset

 

Any idea why?

Many thanks!

Tags (1)
0 Kudos
3,725 Views
lpcxpresso_supp
NXP Employee
NXP Employee

The log you pasted above is associated to the programming session of the Debug ELF? Would you please send us the complete support files after trying to program the Release ELF? Go to Help => MCUXpresso IDE Save Info for Support, and export the zipped logs.

Also, is there any chance you can attach here the Release ELF? We'd like to try to reproduce the described behavior on our side.

Regards,
MCUXpresso IDE Support

0 Kudos
3,681 Views
superaga
Contributor III

Hi @lpcxpresso_supp,

I think that I discovered a workaround to successfully flash the MCU even with the Relase afx.

Here the procedure I used to do it:

  • Build the project as Debug or Release selecting the type from the hammer icon on the toolbar (see picture build_debug_release).
  • Open the GUI Flash Tool (from the toolbar).
    • Leave the File to program to its default path.
  • Press Run to flash the MCU.

When I went through the process after selecting the Debug build I could successfully flash the unit.

When I went through the process after selecting the Release build I couldn't flash the unit.

 

Then this morning I though: What about if I use the Debug build "procedure", but before flash the unit I chose the release build? Doing that I've been able to successfully flash the unit!

So the workaround process is:

  • Build the project as Debug selecting the type from the hammer icon on the toolbar (see picture build_debug_release).
  • Open the GUI Flash Tool (from the toolbar).
    • Change the File to program to the Release path (see picture flash_workaround).
  • Press Run to flash the MCU.

Here the GUI Flash Tool Console output:

Executing flash operation 'Program' (Program file into flash: low_level_clutchTrainer.axf) - Mon Jan 23 09:59:34 CET 2023
Checking MCU info...
Scanning for targets...
Executing flash action...
MCUXpresso IDE RedlinkMulti Driver v11.6 (Jul 12 2022 16:58:24 - crt_emu_cm_redlink.exe build 4)
( 0) Reading remote configuration
Wc(03). No cache support.
Found part description in XML file LPC112x.xml
( 5) Remote configuration complete
Reconnected to existing LinkServer process.
Probe Firmware: LPC-LINK2 CMSIS-DAP V5.361 (NXP Semiconductors)
Serial Number: JQAWBQBR
VID:PID: 1FC9:0090
USB Path: \\?\hid#vid_1fc9&pid_0090&mi_00#c&2f6d6290&0&0000#{4d1e55b2-f16f-11cf-88cb-001111000030}
Using memory from core 0 after searching for a good core
( 30) Emulator Connected
( 40) Debug Halt
( 50) CPU ID
debug interface type = CoreSight DP (DAP DP ID 0BB11477) over SWD TAP 0
processor type = Cortex-M0 (CPU ID 00000C20) on DAP AP 0
number of h/w breakpoints = 4
number of flash patches = 0
number of h/w watchpoints = 2
Probe(0): Connected&Reset. DpID: 0BB11477. CpuID: 00000C20. Info: <None>
Debug protocol: SWD. RTCK: Disabled. Vector catch: Disabled.
Content of CoreSight Debug ROM(s):
RBASE E00FF000: CID B105100D PID 04000BB471 ROM (type 0x1)
ROM 1 E000E000: CID B105E00D PID 04000BB008 Gen SCS (type 0x0)
ROM 1 E0001000: CID B105E00D PID 04000BB00A Gen DWT (type 0x0)
ROM 1 E0002000: CID B105E00D PID 04000BB00B Gen FPB (type 0x0)
NXP: LPC1125/303
DAP stride is 1024 bytes (256 words)
Inspected v.2 On-chip Flash Memory LPC11_12_13_64K_8K.cfx
Image 'LPC11_12_13 (64K Flash, min 8K RAM) Jul 7 2022 12:18:00'
( 65) Chip Setup Complete
Connected: was_reset=true. was_stopped=false
( 70) License Check Complete
Loading 'low_level_clutchTrainer.axf' ELF 0x00000000 len 0x13A0
Opening flash driver LPC11_12_13_64K_8K.cfx
Sending VECTRESET to run flash driver
Flash device supported (64KB = 16*4K at 0x0)
Writing 5024 bytes to address 0x00000000 in Flash
1 of 1 ( 0) Writing sectors 0-1 at 0x00000000 with 5024 bytes
( 0) at 00000000: 0 bytes - 0/5024
( 81) at 00000000: 4096 bytes - 4096/5024
(100) at 00001000: 4096 bytes - 8192/5024
Sectors written: 2, unchanged: 0, total: 2
Erased/Wrote sector 0-1 with 5024 bytes in 200msec
Closing flash driver LPC11_12_13_64K_8K.cfx
(100) Finished writing Flash successfully.
Flash Write Done
Loaded 0x13A0 bytes in 261ms (about 19kB/s)
Reset target (system)
Starting execution using system reset

I think that this is a bug for this IDE release (MCUXpresso IDE v11.6.0 [Build 8187] [2022-07-13]), but I didn't try to any other previous versions.

Can you confirm it?

Many thanks!

AGA

0 Kudos
3,669 Views
brendonslade
NXP TechSupport
NXP TechSupport
We've reported to the developers to check if there is a bug here.
Many thanks for taking the time to report and carefully document your report for the Community!
0 Kudos
3,720 Views
superaga
Contributor III

Hi @lpcxpresso_supp,

many thanks for your support.

  • Yes, the above logs are related to the Debug ELF.
  • I attached the SupportInfo zip generated as per your instructions.
  • I attached also the Release ELF.

Many thanks!

 

Tags (1)
0 Kudos