2017-09-20 04:06 AM
Hi,
I'm trying to setup our new PCB with a STM32F469IGH6 MCU.
Our software includes a RealTime OS and some User Defined Modules as Testsoftware.
The Firmware formerly was written for the STM32F469 Discovery Board and I ported it to our new PCB. So I just deactivated IOs.
Unfortunatelly not all. But I think the main problem was the Clock Configuration. I didn't change it and now I think that the Clock is configured far to high.
HSE = 25MHz
PLL_M = 8
PLL_N = 360
PLL_P = 2
So I get a System Clock of about 560MHz.
The HSE on the Discovery Board ist at 8MHz. So I get a Systemclock of 180MHz on the Discovery Board.
The problem now is, that I cannot connect to the CPU anymore.
I use JLink and in Keil µVision I got this Output:
Header 1
JLink info:
------------DLL: V6.20a, compiled Sep 15 2017 18:04:38Firmware: J-Link Ultra V4 compiled Sep 15 2017 17:51:02Hardware: V4.00S/N : 504400261 Feature(s) : RDI, FlashBP, FlashDL, JFlash, GDB * JLink Info: TotalIRLen = 9, IRPrint = 0x0011* JLink Info: JTAG chain detection found 2 devices:* JLink Info: #0 Id: 0x4BA00477, IRLen: 04, CoreSight JTAG-DP* JLink Info: #1 Id: 0x06434041, IRLen: 05, STM32 Boundary Scan* JLink Info: STM32 (connect): Can not attach to CPU. Trying connect under reset.* JLink Info: TotalIRLen = ?, IRPrint = 0x..000000000000000000000000* JLink Info: TotalIRLen = 9, IRPrint = 0x0011* JLink Info: JTAG chain detection found 2 devices:* JLink Info: #0 Id: 0x4BA00477, IRLen: 04, CoreSight JTAG-DP* JLink Info: #1 Id: 0x06434041, IRLen: 05, STM32 Boundary Scan* JLink Info: STM32 (connect): Can not attach to CPU. Trying connect under reset.* JLink Info: TotalIRLen = ?, IRPrint = 0x..000000000000000000000000***JLink Error: STM32: Connecting to CPU via connect under reset failed.Error: Flash Download failed - Target DLL has been cancelledFlash Load finished at 11:55:26In JLink Commander this Output (using SWD):
Header 1
J-Link>connect
Please specify device / core. <Default>: STM32F469IGType '?' for selection dialogDevice>Please specify target interface: J) JTAG (Default) S) SWDTIF>sSpecify target interface speed [kHz]. <Default>: 4000 kHzSpeed>Device 'STM32F469IG' selected.Connecting to target via SWDFound SW-DP with ID 0x2BA01477STM32 (connect): Can not attach to CPU. Trying connect under reset.Found SW-DP with ID 0x2BA01477Found SW-DP with ID 0x2BA01477STM32 (connect): Can not attach to CPU. Trying connect under reset.Found SW-DP with ID 0x2BA01477****** Error: STM32: Connecting to CPU via connect under reset failed.Found SW-DP with ID 0x2BA01477STM32 (connect): Can not attach to CPU. Trying connect under reset.Found SW-DP with ID 0x2BA01477Found SW-DP with ID 0x2BA01477STM32 (connect): Can not attach to CPU. Trying connect under reset.Found SW-DP with ID 0x2BA01477****** Error: STM32: Connecting to CPU via connect under reset failed.Cannot connect to target.In JLink Commander this Output (using JTAG)
Header 1
Please specify device / core. <Default>: STM32F469IG
Type '?' for selection dialogDevice>Please specify target interface: J) JTAG (Default) S) SWDTIF>Device position in JTAG chain (IRPre,DRPre) <Default>: -1,-1 => Auto-detectJTAGConf>Specify target interface speed [kHz]. <Default>: 4000 kHzSpeed>Device 'STM32F469IG' selected.Connecting to target via JTAGTotalIRLen = 9, IRPrint = 0x0011JTAG chain detection found 2 devices: #0 Id: 0x4BA00477, IRLen: 04, CoreSight JTAG-DP #1 Id: 0x06434041, IRLen: 05, STM32 Boundary ScanSTM32 (connect): Can not attach to CPU. Trying connect under reset.TotalIRLen = ?, IRPrint = 0x..000000000000000000000000TotalIRLen = 9, IRPrint = 0x0011JTAG chain detection found 2 devices: #0 Id: 0x4BA00477, IRLen: 04, CoreSight JTAG-DP #1 Id: 0x06434041, IRLen: 05, STM32 Boundary ScanSTM32 (connect): Can not attach to CPU. Trying connect under reset.TotalIRLen = ?, IRPrint = 0x..000000000000000000000000****** Error: STM32: Connecting to CPU via connect under reset failed.TotalIRLen = 9, IRPrint = 0x0011JTAG chain detection found 2 devices: #0 Id: 0x4BA00477, IRLen: 04, CoreSight JTAG-DP #1 Id: 0x06434041, IRLen: 05, STM32 Boundary ScanSTM32 (connect): Can not attach to CPU. Trying connect under reset.TotalIRLen = ?, IRPrint = 0x..000000000000000000000000TotalIRLen = 9, IRPrint = 0x0011JTAG chain detection found 2 devices: #0 Id: 0x4BA00477, IRLen: 04, CoreSight JTAG-DP #1 Id: 0x06434041, IRLen: 05, STM32 Boundary ScanSTM32 (connect): Can not attach to CPU. Trying connect under reset.TotalIRLen = ?, IRPrint = 0x..000000000000000000000000****** Error: STM32: Connecting to CPU via connect under reset failed.Cannot connect to target.Some Notes regarding the Current: Without Firmware the complete Board (2 CPUs on it) took about 30-40mA.
With the misconfigured Firmware only on CPU1 it is at about 90mA. CPU heats up but I can touch it .
Why can't I connect to my CPU anymore? Is it because of the Clock Config? What happens with the CPU if I write such an Clock configuration?
Are there any possibilities to get into CPU again?
Kind regards
Andreas
Solved! Go to Solution.
2017-09-20 04:21 AM
Do you have the mcu reset connected to the debugger?
How are the BOOTx pins connected? Can you try connecting with debugger while in bootloader mode?
JW
2017-09-20 04:21 AM
Do you have the mcu reset connected to the debugger?
How are the BOOTx pins connected? Can you try connecting with debugger while in bootloader mode?
JW
2017-09-20 04:56 AM
Hi Jan,
yes Debugger is connected properly. I was able to flash this firmware and I am also able to connect to the second CPU which doesn't have any firmware now.
BOOT0 is connected to GND with a PullDown. BOOT1 is PB2 which is also set to GND over PullDown. But it should be possible to get BOOT0 to Vcc over a Pad. I will try it.
Kind regards
Andreas
2017-09-20 05:53 AM
PLL_M would need to be 25 if your HSE is 25 MHz and HSE_VALUE would also need to be coherent.
2017-09-20 11:40 PM
Hello,
thanks for your help.
Problem solved. I set the BOOT0 Pint to 3.3V and the controller booted into Bootloader Mode. Then I was able to attach to it with the debugger and erase the flash.
I already adjusted the RCC Values for my custom board. Now Firmware is running.
Kind regards
Andreas