This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

inline breakpoint

When using the monitor i would like all ASSERTs to force a break out to the debugger. Is there any way of doing this with some inline C or assembler code?

Many Thanks,
Martin.

Parents
  • Sure.

    1. Create a function called assert-failed. This function should include while(1);
    2. Define the ASSERT macro to call this function when the assertion fails.
    3. Set a breakpoint on the assert_failed function.

    All your failed assertions will execution this function. The breakpoint set on it will halt the debugger.

    Jon

Reply
  • Sure.

    1. Create a function called assert-failed. This function should include while(1);
    2. Define the ASSERT macro to call this function when the assertion fails.
    3. Set a breakpoint on the assert_failed function.

    All your failed assertions will execution this function. The breakpoint set on it will halt the debugger.

    Jon

Children