Author Topic: No target connected error in STM32F7  (Read 2424 times)

0 Members and 1 Guest are viewing this topic.

Offline A.Ersoz

  • Regular Contributor
  • *
  • Posts: 75
  • Country: us
No target connected error in STM32F7
« on: March 26, 2019, 09:56:09 pm »
On my custom board, I use STM32F767 microprocessor. When I try to flash program, I get no target connected error. When I set Boot0 pin as high/low and NRST pin as low, the Keil recognize the microprocessor. But when I remove GND connection of NRST pin, power supply current value oscillates and the microprocessor goes to same error mode again. Actually, I also add pull up 10k resistor to NRST pin because this resistor is missing in my design, but the problem is still there. Do you have any idea about solution and why it happens?

Thanks
 

Offline lucazader

  • Regular Contributor
  • *
  • Posts: 155
  • Country: nz
Re: No target connected error in STM32F7
« Reply #1 on: March 26, 2019, 10:01:02 pm »
Possibly try some different connection and/or reset modes.
eg core reset, soft reset, hardware reset. Connect under reset, hotplug. etc..

Instead of using keil, perhaps try using the STMCubeprogrammer software (the new version of the st-link utility) to try and narrow down the issues.
 

Offline A.Ersoz

  • Regular Contributor
  • *
  • Posts: 75
  • Country: us
Re: No target connected error in STM32F7
« Reply #2 on: March 26, 2019, 10:05:41 pm »
So you mean it is related with at software end?

I first time to hear STM32Cube Prog. Is it an IDE?
 

Offline thm_w

  • Super Contributor
  • ***
  • Posts: 2213
  • Country: ca
 

Offline lucazader

  • Regular Contributor
  • *
  • Posts: 155
  • Country: nz
Re: No target connected error in STM32F7
« Reply #4 on: March 26, 2019, 11:27:09 pm »
More just trying to narrow down if it is related to some settings in keil, or if it is a problem with your PCB
 

Offline Howtosx

  • Newbie
  • Posts: 2
  • Country: ai
Re: No target connected error in STM32F7
« Reply #5 on: March 27, 2019, 06:47:27 am »
Not only useful but can still be extended again
 

Offline ajb

  • Super Contributor
  • ***
  • Posts: 1772
  • Country: us
Re: No target connected error in STM32F7
« Reply #6 on: March 27, 2019, 02:05:38 pm »
How are you connecting to the mcu? What debug probe? SWD or JTAG using a built-in bootloader?  What settings? Please share a schematic showing your mcu's reset and programming circuitry (including any other devices that may be connected to the programming lines)
 

Offline A.Ersoz

  • Regular Contributor
  • *
  • Posts: 75
  • Country: us
Re: No target connected error in STM32F7
« Reply #7 on: March 27, 2019, 02:29:10 pm »
How are you connecting to the mcu? What debug probe? SWD or JTAG using a built-in bootloader?  What settings? Please share a schematic showing your mcu's reset and programming circuitry (including any other devices that may be connected to the programming lines)

I use debugger connector placing on the PCB for flashing my codes. Schematic was attached to the post.


 

Offline A.Ersoz

  • Regular Contributor
  • *
  • Posts: 75
  • Country: us
Re: No target connected error in STM32F7
« Reply #8 on: March 27, 2019, 03:36:03 pm »
More just trying to narrow down if it is related to some settings in keil, or if it is a problem with your PCB

I also tried to connect with CubePrg and got an error like attached file.
 

Offline lucazader

  • Regular Contributor
  • *
  • Posts: 155
  • Country: nz
Re: No target connected error in STM32F7
« Reply #9 on: March 27, 2019, 06:36:02 pm »
It seems you are using an stlink v2 or v2.1.
There are a few funny things in this screenshot.

1) what is the error that the program prints if the debug probe is not attached to the board?
2) the target voltage of 1.15v seems to be off. this should be 3.3v (probably) and this might be something to do with the power supply current oscillating.
3) check the firmware of the st-link is up to date

 

Offline A.Ersoz

  • Regular Contributor
  • *
  • Posts: 75
  • Country: us
Re: No target connected error in STM32F7
« Reply #10 on: March 27, 2019, 06:49:49 pm »
It seems you are using an stlink v2 or v2.1.
There are a few funny things in this screenshot.

1) what is the error that the program prints if the debug probe is not attached to the board?
2) the target voltage of 1.15v seems to be off. this should be 3.3v (probably) and this might be something to do with the power supply current oscillating.
3) check the firmware of the st-link is up to date



Yes, I use ST Link v2.

1) No STM32 target found!
2) Actually, I didn't understand the target voltage. How can I control it?
3) Yes, I updated it.
 

Offline aldi

  • Contributor
  • Posts: 20
  • Country: nl
Re: No target connected error in STM32F7
« Reply #11 on: March 27, 2019, 07:15:49 pm »
The target voltage is the voltage that the STlink measures at pin 1/2, its connected to 3V3 in your schematic. You should check the power supply for stability issues, and check the wiring from board to STlink.
Also: Not sure but it think that the resistor on pin 19 of the connector may connect the STlink 3V3 to ground?
« Last Edit: March 27, 2019, 07:20:58 pm by aldi »
 

Offline A.Ersoz

  • Regular Contributor
  • *
  • Posts: 75
  • Country: us
Re: No target connected error in STM32F7
« Reply #12 on: March 28, 2019, 07:07:36 pm »
I almost solved the problem but not exactly. I assembled new board with only power parts and microcontroller. Then, I have faced same problem. So the common situation among these boards are jumping cables which are connecting ST link adapter to PCB debugger connector. I replaced them and the problem is solved in the new board. However, in the old board, the problem is still there. I suspect that when I remove the GND from NRST pin, power supply current oscillates. During this oscillation, something happens and the microcontroller protects or closes itself.
 

Offline A.Ersoz

  • Regular Contributor
  • *
  • Posts: 75
  • Country: us
Re: No target connected error in STM32F7
« Reply #13 on: March 28, 2019, 07:50:06 pm »
Guys, I solved the problem completely just minutes ago. On the output of the OpAmps, there is a MUX (MAX396EQI). I used its package downloading from Ultralibrarian website and integrated in my design. But when I double check it with comparing its datasheet its package design is completely wrong. So, now I removed the MUX and total current consumption is 54mA. Now, I will do Boot0 high/low and NRST low cycle again. I hope Keil is also recognized it.
 

Online Yansi

  • Super Contributor
  • ***
  • Posts: 3290
  • Country: 00
  • STM32, STM8, AVR, 8051
Re: No target connected error in STM32F7
« Reply #14 on: March 28, 2019, 10:30:52 pm »
CubeProgrammer is a PoS... avoid it while you can as a plague!

Use STLINK Utility software instead of that.
 

Offline lucazader

  • Regular Contributor
  • *
  • Posts: 155
  • Country: nz
Re: No target connected error in STM32F7
« Reply #15 on: March 29, 2019, 01:51:11 am »
CubeProgrammer is a PoS... avoid it while you can as a plague!

Use STLINK Utility software instead of that.

I tend to disagree, at least for my purposes.
1) I am developing on Linux. the Cube programmer is available on linux.
2) There is a handy to use cli interface, which i find very convenient when integrating with vscode.
3) you can easily change the connection interface, speed and reset types without the stlink utility trying to connect to the target (always seems to do this when you go into the settings in stlink utility)
4) more convenient ui for erasing specific sectors etc (useful for when you use custom boot-loaders)

It does have downsides, like much higher memory usage because java. But on the whole i definitely think its better.

But yea each to their own!
 

Online Yansi

  • Super Contributor
  • ***
  • Posts: 3290
  • Country: 00
  • STM32, STM8, AVR, 8051
Re: No target connected error in STM32F7
« Reply #16 on: April 01, 2019, 10:48:09 pm »
You can disagree with whatever you want, but you shall probably take the suggestion more seriously, if one you know... works "there" and knows which tools are buggy and which are not. I would never trust the Cube Programmer. STLink Utility always for any sanity checks.

STLINK Utility also has CLI, so now you know.  :-+

It even supports multiple STLINKs at once ;)

It would also help, if the OP could attach a schematic and also a PCB layout screenshot, so we could independ
//EDIT: Oh, I see it. Why haven't I see it before?

You are missing a 100nF cap to GND on the NRST line. Power supply decoupling extremely inadequate I see just a couple of 100nF caps. To little for 100 (or more?) pin package with a 200MHz thing inside. Each VDD pin needs to have its own 100nF.
« Last Edit: April 01, 2019, 10:59:09 pm by Yansi »
 

Offline lucazader

  • Regular Contributor
  • *
  • Posts: 155
  • Country: nz
Re: No target connected error in STM32F7
« Reply #17 on: April 01, 2019, 11:06:29 pm »
Well each to their own i guess.
I have found st-link utility more buggy and less likely to connect.
Wonder why we are getting different experiences?

Anyway the ability to run the Cube Programmer on linux is much more beneficial to me, it means i can actually use the program!
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf