Reset line staying low

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

Reset line staying low

1,256 Views
mayureshp
Contributor II

Hello 

I have S32K144 mcu on newly assembled PCB. when i measure voltage on reset line it seems to be 0.3 when observed on oscilloscope i read pulses at 500Hz. When i connect segger J-Link plus with SWD connection to MCU. I see a red light on j-link. I am guessing it is because reset is currently active low. When i flash/debug through S32KDS it is showing me below log on console. Can anyone help, how can i solve this issue. I understand that MCU is not flashed yet that is why reset is low but how to flash then?

 

Console output:

SEGGER J-Link GDB Ser

Capture.PNG

ver V6.42a Command Line Version

JLinkARM.dll V6.42a (DLL compiled Feb 1 2019 18:00:08)

Command line: -if swd -device S32K144 -endian little -speed 1000 -port 2331 -swoport 2332 -telnetport 2333 -vd -ir -localhostonly 1 -singlerun -strict -timeout 0 -nogui
-----GDB Server start settings-----
GDBInit file: none
GDB Server Listening port: 2331
SWO raw output listening port: 2332
Terminal I/O port: 2333
Accept remote connection: localhost only
Generate logfile: off
Verify download: on
Init regs on start: on
Silent mode: off
Single run mode: on
Target connection timeout: 0 ms
------J-Link related settings------
J-Link Host interface: USB
J-Link script: none
J-Link settings file: none
------Target related settings------
Target device: S32K144
Target interface: SWD
Target interface speed: 1000kHz
Target endian: little

Connecting to J-Link...
J-Link is connected.
Firmware: J-Link V11 compiled Jun 29 2021 16:12:24
Hardware: V11.00
S/N: 601009174
Feature(s): RDI, FlashBP, FlashDL, JFlash, GDB
Checking target voltage...
Target voltage: 3.35 V
Listening on TCP/IP port 2331
Connecting to target...Connected to target
Waiting for GDB connection...Connected to 127.0.0.1
Reading all registers
Read 4 bytes @ address 0x00000000 (Data = 0xFFFFFFFF)
Received monitor command: speed 1000
Target interface speed set to 1000 kHz
Received monitor command: clrbp
Received monitor command: reset
Resetting target
Received monitor command: halt
Halting target CPU...
...Target halted (PC = 0xFFFFFFFE)
Received monitor command: regs
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, R13= FFFFFFFC, MSP= FFFFFFFC, PSP= 00000000
R14(LR) = FFFFFFFF, R15(PC) = FFFFFFFE
XPSR 01000000, APSR 00000000, EPSR 01000000, IPSR 00000000
CFBP 00000000, CONTROL 00, FAULTMASK 00, BASEPRI 00, PRIMASK 00
Reading all registers
WARNING: Failed to read memory @ address 0xFFFFFFFE
Received monitor command: speed auto
Select auto target interface speed (2000 kHz)
Received monitor command: flash breakpoints 1
Flash breakpoints enabled
Received monitor command: semihosting enable
Semi-hosting enabled (Handle on BKPT)
Received monitor command: semihosting IOClient 1
Semihosting I/O set to TELNET Client
Received monitor command: SWO DisableTarget 0xFFFFFFFF
SWO disabled successfully.
Received monitor command: SWO EnableTarget 0 0 0x1 0
Failed to enable SWO. Could not measure target CPU frequency.
Read 4 bytes @ address 0xFFFFFFFE (Data = 0x00000A10)
Downloading 1024 bytes @ address 0x00000000 - Verified OK
Downloading 16 bytes @ address 0x00000400 - Verified OK
Downloading 4096 bytes @ address 0x00000410 - Verified OK
Downloading 4096 bytes @ address 0x00001410 - Verified OK
Downloading 4096 bytes @ address 0x00002410 - Verified OK
Downloading 4096 bytes @ address 0x00003410 - Verified OK
Downloading 4096 bytes @ address 0x00004410 - Verified OK
Downloading 4096 bytes @ address 0x00005410 - Verified OK
Downloading 1804 bytes @ address 0x00006410 - Verified OK
Downloading 8 bytes @ address 0x00006B1C - Verified OK
Downloading 1116 bytes @ address 0x00006B24 - Verified OK
WARNING: CPU could not be halted
ERROR: Failed to download RAMCode.
Failed to prepare for programming.
Failed to download RAMCode!
Can not read register 16 (XPSR) while CPU is running
Can not read register 20 (CFBP) while CPU is running
Can not read register 0 (R0) while CPU is running
Can not read register 1 (R1) while CPU is running
Can not read register 2 (R2) while CPU is running
Can not read register 3 (R3) while CPU is running
Can not read register 4 (R4) while CPU is running
Can not read register 5 (R5) while CPU is running
Can not read register 6 (R6) while CPU is running
Can not read register 7 (R7) while CPU is running
Can not read register 8 (R8) while CPU is running
Can not read register 9 (R9) while CPU is running
Can not read register 10 (R10) while CPU is running
Can not read register 11 (R11) while CPU is running
Can not read register 12 (R12) while CPU is running
Can not read register 14 (R14) while CPU is running
Can not read register 15 (R15) while CPU is running
Can not read register 17 (MSP) while CPU is running
Can not read r
Writing register (PC = 0x 410)
Read 4 bytes @ address 0x00000410 (Data = 0x00000000)
Read 2 bytes @ address 0x00001132 (Data = 0x0000)
WARNING: Failed to read memory @ address 0x00001132
Read 2 bytes @ address 0x00001112 (Data = 0x0000)
Read 2 bytes @ address 0x00001112 (Data = 0x0000)
Read 2 bytes @ address 0x00000CDC (Data = 0x0000)
Read 2 bytes @ address 0x00000D54 (Data = 0x0000)
Received monitor command: clrbp
Received monitor command: reset
Resetting target
Received monitor command: halt
Halting target CPU...
...Target halted (PC = 0xFFFFFFFE)
Read 2 bytes @ address 0x00001132 (Data = 0xFFFF)
Read 2 bytes @ address 0x00001132 (Data = 0xFFFF)
Read 2 bytes @ address 0x00001132 (Data = 0xFFFF)
Received monitor command: regs
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, R13= FFFFFFFC, MSP= FFFFFFFC, PSP= 00000000
R14(LR) = FFFFFFFF, R15(PC) = FFFFFFFE
XPSR 01000000, APSR 00000000, EPSR 01000000, IPSR 00000000
CFBP 00000000, CONTROL 00, FAULTMASK 00, BASEPRI 00, PRIMASK 00
Reading all registers
WARNING: Failed to read memory @ address 0xFFFFFFFE
Setting breakpoint @ address 0x00000D54, Size = 2, BPHandle = 0x0001
Setting breakpoint @ address 0x00001112, Size = 2, BPHandle = 0x0002
Setting breakpoint @ address 0x00001132, Size = 2, BPHandle = 0x0003
Starting target CPU...

0 Kudos
5 Replies

332 Views
swaraj25
Contributor I

Hello @mayureshp ,
We tried the same steps but as mentioned by you. But we are still facing the same issues. Kindly let us know what you have tried in detail. Also suggest any alternate solutions you have.

0 Kudos

1,242 Views
danielmartynek
NXP TechSupport
NXP TechSupport

Hello @mayureshp,

The periodic reset is expected as you said, the MCUs are shipped blank and core lockup reset triggers periodically.

But this should be no an issue.

Have you tried loading some examples from the S32DS IDE? Maybe the issue is in the image.

Do you have any other debugger?

 

BR, Daniel

 

 

 

0 Kudos

1,239 Views
mayureshp
Contributor II

Hello Daniel,

Yes i tried loading examples like ADC_PAL and tried flashing directly with default setting using Segger J-Link plus. but did not work.

Any way after some digging on internet. I tried changing few settings on startup tab in S32KDS and it worked. I disabled SWO pin and fixed SWD pin speed to 12000KHz. And also added monitor reset command on startup tab. below are screen-shots for configurations i used.

552 Views
HalloWorld
Contributor I
Thank you!!!!
0 Kudos

1,235 Views
danielmartynek
NXP TechSupport
NXP TechSupport

Hi @mayureshp,

Thank you for the solution,

 

BR, Daniel

0 Kudos