cancel
Showing results for 
Search instead for 
Did you mean: 

Crystal stops oscillating when debugging

chichkinei
Associate II
Posted on May 09, 2014 at 03:22

Hi, I have a board with an STM32F429 and an 8 MHz crystal on the HSE pins. I'm using Atollic TrueSTUDIO to upload and debug code. I can upload code without a problem, but as soon as the the debugger starts, the crystal stops oscillating and I'm unable to step through the code. Any ideas what might be causing this?

4 REPLIES 4
chichkinei
Associate II
Posted on May 09, 2014 at 05:10

Ok, the crystal no longer stops for some reason, but I get communication errors unless I pull down the SW data line. Is this a requirement?

chen
Associate II
Posted on May 09, 2014 at 10:29

Hi

You have probably used the IO pins that the debugger uses.

Check which IO pins you have used and which pins are used for the debugging device.

Do NOT use the pins that the debugger uses!

chichkinei
Associate II
Posted on May 21, 2014 at 05:47

I'm not using the SWD pins for anything else. This problem has developed further. A week ago I switched from the original 16 MHz crystal (I mistyped as 8 MHz in the OP) to an 8 MHz crystal for testing and it worked fine for a week. Now I just switched back to a 16 MHz crystal and for a few moments the crystal oscillated fine. Now, the crystal won't start up at all, but I can still step through code in the debugger. Any advice?

chen
Associate II
Posted on May 21, 2014 at 11:10

OK.

Are you sure you are running off the HSE, could you actually be running off the HSI?

I think the capcaitor values for 8MHz and 16MHz are different, are you sure the right values for the crystal as used?

Check the HSE is working by routing it to an output pin.