Dear Toradex Support,
I hope you are well. As I am experiencing an issue with my Verdin Imx8 Mini, I am reaching out to you for assistance.
I successfully built an elf and binary file to toggle an LED.
When I tested the bin file by sending it to the var directory and loading and running the igpio_led_output.binary file into the Cortex-M with EXT4LOAD Loading Method, it worked fine and the led is blinking.
Now, I’m trying to replicate the same experiment using a JTAG debugger. Although the debugger can identify the core, I’m facing an issue. After loading[loadfile C:\Users\mehrdad.saei\Downloads\igpio_led_output.elf 0x0]
the elf file and running the “g” command for run or the “h” command for halting, nothing happens with the LED.
Could you please assist me with this? I would greatly appreciate your help.
J-link commander V7.88K output:
J-Link>connect
Device "MIMX8MM6_M4" selected.
Connecting to target via JTAG
InitTarget() start
JTAG selected. Identifying JTAG Chain...
TotalIRLen = 4, IRPrint = 0x01
JTAG chain detection found 1 devices:
#0 Id: 0x5BA00477, IRLen: 04, CoreSight JTAG-DP
JTAG Chain Identified. Connecting to DAP TAP...
Successfully connected to selected DAP TAP.
DAP initialized successfully.
InitTarget() end - Took 7.05ms
TotalIRLen = 4, IRPrint = 0x01
JTAG chain detection found 1 devices:
#0 Id: 0x5BA00477, IRLen: 04, CoreSight JTAG-DP
DPv0 detected
AP map detection skipped. Manually configured AP map found.
AP[0]: MEM-AP (IDR: Not set)
AP[1]: MEM-AP (IDR: Not set)
AP[2]: MEM-AP (IDR: Not set)
AP[3]: MEM-AP (IDR: Not set)
AP[4]: AHB-AP (IDR: Not set)
AP[4]: Core found
AP[4]: AHB-AP ROM base: 0xE00FF000
CPUID register: 0x410FC241. Implementer code: 0x41 (ARM)
Found Cortex-M4 r0p1, Little endian.
FPUnit: 6 code (BP) slots and 2 literal slots
CoreSight components:
ROMTbl[0] @ E00FF000
[0][0]: E000E000 CID B105E00D PID 000BB00C SCS-M7
[0][1]: E0001000 CID B105E00D PID 003BB002 DWT
[0][2]: E0002000 CID B105E00D PID 002BB003 FPB
[0][3]: E0000000 CID B105E00D PID 003BB001 ITM
[0][5]: E0041000 CID B105900D PID 000BB925 ETM
[0][7]: E0043000 CID B105900D PID 001BB908 CSTF
[0][8]: E0044000 CID B105900D PID 004BB906 CTI
Memory zones:
Zone: "Default" Description: Default access mode
Cortex-M4 identified.
J-Link>g
J-Link>connect
Device "MIMX8MM6_M4" selected.
Connecting to target via JTAG
InitTarget() start
JTAG selected. Identifying JTAG Chain...
TotalIRLen = 4, IRPrint = 0x01
JTAG chain detection found 1 devices:
#0 Id: 0x5BA00477, IRLen: 04, CoreSight JTAG-DP
JTAG Chain Identified. Connecting to DAP TAP...
Successfully connected to selected DAP TAP.
DAP initialized successfully.
InitTarget() end - Took 10.9ms
TotalIRLen = 4, IRPrint = 0x01
JTAG chain detection found 1 devices:
#0 Id: 0x5BA00477, IRLen: 04, CoreSight JTAG-DP
DPv0 detected
AP map detection skipped. Manually configured AP map found.
AP[0]: MEM-AP (IDR: Not set)
AP[1]: MEM-AP (IDR: Not set)
AP[2]: MEM-AP (IDR: Not set)
AP[3]: MEM-AP (IDR: Not set)
AP[4]: AHB-AP (IDR: Not set)
AP[4]: Core found
AP[4]: AHB-AP ROM base: 0xE00FF000
CPUID register: 0x410FC241. Implementer code: 0x41 (ARM)
Found Cortex-M4 r0p1, Little endian.
FPUnit: 6 code (BP) slots and 2 literal slots
CoreSight components:
ROMTbl[0] @ E00FF000
[0][0]: E000E000 CID B105E00D PID 000BB00C SCS-M7
[0][1]: E0001000 CID B105E00D PID 003BB002 DWT
[0][2]: E0002000 CID B105E00D PID 002BB003 FPB
[0][3]: E0000000 CID B105E00D PID 003BB001 ITM
[0][5]: E0041000 CID B105900D PID 000BB925 ETM
[0][7]: E0043000 CID B105900D PID 001BB908 CSTF
[0][8]: E0044000 CID B105900D PID 004BB906 CTI
Memory zones:
Zone: "Default" Description: Default access mode
Cortex-M4 identified.
J-Link>loadfile C:\Users\mehrdad.saei\Downloads\igpio_led_output.elf 0x0
'loadfile': Performing implicit reset & halt of MCU.
ResetTarget() start
ResetTarget() end - Took 2us
Downloading file [C:\Users\mehrdad.saei\Downloads\igpio_led_output.elf]...
O.K.
J-Link>connect
>Device "MIMX8MM6_M4" selected.
Connecting to target via JTAG
InitTarget() start
JTAG selected. Identifying JTAG Chain...
TotalIRLen = 4, IRPrint = 0x01
JTAG chain detection found 1 devices:
#0 Id: 0x5BA00477, IRLen: 04, CoreSight JTAG-DP
JTAG Chain Identified. Connecting to DAP TAP...
Successfully connected to selected DAP TAP.
DAP initialized successfully.
InitTarget() end - Took 10.3ms
TotalIRLen = 4, IRPrint = 0x01
JTAG chain detection found 1 devices:
#0 Id: 0x5BA00477, IRLen: 04, CoreSight JTAG-DP
DPv0 detected
AP map detection skipped. Manually configured AP map found.
AP[0]: MEM-AP (IDR: Not set)
AP[1]: MEM-AP (IDR: Not set)
AP[2]: MEM-AP (IDR: Not set)
AP[3]: MEM-AP (IDR: Not set)
AP[4]: AHB-AP (IDR: Not set)
AP[4]: Core found
AP[4]: AHB-AP ROM base: 0xE00FF000
CPUID register: 0x410FC241. Implementer code: 0x41 (ARM)
Found Cortex-M4 r0p1, Little endian.
FPUnit: 6 code (BP) slots and 2 literal slots
CoreSight components:
ROMTbl[0] @ E00FF000
[0][0]: E000E000 CID B105E00D PID 000BB00C SCS-M7
[0][1]: E0001000 CID B105E00D PID 003BB002 DWT
[0][2]: E0002000 CID B105E00D PID 002BB003 FPB
[0][3]: E0000000 CID B105E00D PID 003BB001 ITM
[0][5]: E0041000 CID B105900D PID 000BB925 ETM
[0][7]: E0043000 CID B105900D PID 001BB908 CSTF
[0][8]: E0044000 CID B105900D PID 004BB906 CTI
Memory zones:
Zone: "Default" Description: Default access mode
Cortex-M4 identified.
J-Link>r
Reset delay: 0 ms
Reset type NORMAL: Resets core & peripherals via SYSRESETREQ & VECTRESET bit.
ResetTarget() start
ResetTarget() end - Took 2us
J-Link>g
J-Link>h
PC = 1FFE0008, CycleCnt = 1DD42C6B
R0 = 00000000, R1 = 00000000, R2 = 00000000, R3 = 00000000
R4 = 00000000, R5 = 00000000, R6 = 00000000, R7 = 00000000
R8 = 00000000, R9 = 00000000, R10= 00000000, R11= 00000000
R12= 00000000
SP(R13)= 20008000, MSP= 20008000, PSP= 00000000, R14(LR) = FFFFFFFF
XPSR = 01000000: APSR = nzcvq, EPSR = 01000000, IPSR = 000 (NoException)
CFBP = 00000000, CONTROL = 00, FAULTMASK = 00, BASEPRI = 00, PRIMASK = 00
FPS0 = 00000000, FPS1 = 00000000, FPS2 = 00000000, FPS3 = 00000000
FPS4 = 00000000, FPS5 = 00000000, FPS6 = 00000000, FPS7 = 00000000
FPS8 = 00000000, FPS9 = 00000000, FPS10= 00000000, FPS11= 00000000
FPS12= 00000000, FPS13= 00000000, FPS14= 00000000, FPS15= 00000000
FPS16= 00000000, FPS17= 00000000, FPS18= 00000000, FPS19= 00000000
FPS20= 00000000, FPS21= 00000000, FPS22= 00000000, FPS23= 00000000
FPS24= 00000000, FPS25= 00000000, FPS26= 00000000, FPS27= 00000000
FPS28= 00000000, FPS29= 00000000, FPS30= 00000000, FPS31= 00000000
FPSCR= 00000000
J-Link>
igpio_led_output.bin (15.4 KB)
igpio_led_output.elf (262.5 KB)
Best regards,
Mehrdad