Manually inserted breakpoints in AS7?

Go To Last Post
3 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I abandoned MPLABX because of the issues I was having, and reverted to running AS7 in a windows VM.

 

Does AS7 really NOT handle manually inserted breakpoints (__asm__ __volatile__("break");) ?  I expect it to break to the debugger, and then continue on the next instruction when I use one of the continue or step commands (having noticed that it wasn't a debugger-insterted break, and therefore it doesn't need to reprogram the flash with the original instruction.)  This seems to be what MPLAB does.

Instead, it gets stuck, and won't proceed beyond the break instruction.  Which is pretty useless.

 

Grr.

 

Last Edited: Fri. Sep 6, 2019 - 06:24 AM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

westfw wrote:
Instead, it gets stuck, and won't proceed beyond the break instruction.  Which is pretty useless.
I think you have to bump PC to the next opcode. ("Set Next Statement").

 

I tried this in the simulator but it seems "BREAK" is just ignore completely in the sim.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

The simulator doesn't use the on-chip debugger at all. It doesn't have to since it can look into all areas of the chip anyway.

 

When setting breakpoints the simulator keeps its own list and checks the PC, or what ever the break conditions are, every cycle. All breakpoints are "HW-breakpoints", and you can have an "unlimited" number.