cancel
Showing results for 
Search instead for 
Did you mean: 

PSoC 4 MCU

New Contributor II

 I have recently run into an issue with the debugger. Over half of the time I try to run my  program within a debugging session, the processor fails to start. If I reset the program, it works. If I set a break point, the program will halt at that location, but then I am unable to step. Almost all of the time I am debugging, I am having to think of ways to work around the chip "hanging". It's completely bizarre. This occurs with two different MiniProg3 units I've used (rev A and B).

   

Now here's the fascinating part. If I revert my code back to an earlier version in which I did not notice the problem, debugging works as well as ever. So, something changed that is affecting debugging. I am only using 60% of the code space with debugging enabled.

   

Any thoughts on how an application could prevent the debugger from working?

0 Likes
Reply
5 Replies
Anonymous
Not applicable

 I do not have creator at home, so not sure if PSOC4 is the same as PSoC5. But there is an icon on the tool bar to disable interrupts.

   

If there is, then disable the interrupt after the break point and you should be able to step. ( you may need to use 2 steps the fist time after first disable using the icon)

0 Likes
Reply
Esteemed Contributor II
        Have a look into this thread.http://www.cypress.com/?app=forum&id=2233&rID=79061   
   
Bob   
0 Likes
Reply
New Contributor II

 Yes, I am aware of these issues and debug with interrupt issues in mind. This is not what I am seeing in the latest revision of my code. I see all the halmarks for the above referenced debugging issues in the previous revision. This latest revision simply will not debug. I have never encountered a situation in which I could not start the program executing using the run button. I have always been able to pause and restart code at any point with the debugger. The behavior is presently so unpredictable so as to make debugging almost impossible.

0 Likes
Reply
New Contributor II

 I want to give an example. When I first start the debugging process, the PC points to the first instruction. I then press "run". Now I see nothing happening. I press "pause" and I am sent into the disassembly. The PC has stopped at 0x000003C2, which is the thirst instruction after main. I am hung at movs r3, #0. It doesn't matter if I press run again then pause, the PC never moves again.

0 Likes
Reply
New Contributor II
        What's up with this really small editing box? I found the problem. Thanks for the thoughts everyone. I was enabling the watchdog in the wrong location. Mistakes like that are good to keep one humble!   
0 Likes
Reply