Performance and State Monitoring

vMicro's Serial Debugger helps monitor the performance of your embedded system, allowing near realtime charting of memory usage, as well as performance monitoring of tracepoints.

This is only supported using the vMicro Serial Debugger as Hardware Debugging impacts the system too heavily to be used for performance monitoring.

 

Warning 16 Warning performance monitoring cannot exceed the serial rate your PC can handle.

 

Free Memory Monitoring

This can be enabled using the Debugger > Monitor Free Memory Option.  Once the debugger starts, the chart will automatically appear in the IDE for you (as below):-

Free Memory Monitor Chart in vMicro

The "Interval (ms)" option seen here is the frequency the chart is updated at, the data polling speeds are explained in the following sections.

 

Custom Break / Trace Messages

Add messages and/or {variables} and {function()} to break-points via 'break-point>action>message'

Add =? to the end of a variable name to enable update of the variable value during a debug session: ie: "Motor volts: {myVar=?}"

Tracepoint with custom message and variable tracking

 

Performance Monitoring

Performance Monitoring will add timing statistics to all breakpoints, which can be seen in the output window.  This will show the total uptime, as well as the time elapsed between this breakpoint and the previous one hit.

This can be enabled from Debugger > Performance Monitoring

Output Window with Performance Statistics

 

Tracepoint Timing

To set the tracepoint to output periodically use milliseond values in the "breakpoint > conditon > hit counter"

e.g. Multiples of 250 would be 4 debugger updates per second

vMicro TracePoint with Hit Counter Settings

If you wish this to become a different interval instead of the default of ms you can edit the "Report Frequency Type", and to alter the default interval use the "Report Frequency"

vMicro > Project Properties > (Micro Debug Reporting Section) > Report Frequency Type / Report Frequency

vMicro Serial Debugger Project Options

Warning 16 Warning If you set the Type to "No Filter" you need to ensure your code will not overload the Serial port on your PC, with either HitCounts as above, or delays in the code.

More Information can be found about Using Breakpoint and Tracepoint Hit Counters and Conditions

 

Pin Monitoring

vMicro will automatically monitor all pins on your board, and create a visualisation to make it simpler to analyse.

These can be enabled from the Debugging > Monitor Analog / Digital Pins options, or by including a tracepoint in your program with {@ReportDigital} and / or {@ReportAnalog}

Digital and Analog Pin Visualisations in vMicro



Custom Charting

Include special vars such as  {@Plot.MyWindow.MyChartName sensor1Value} to plot custom values on to your own charts, to track whatever is needed in your project...



Crash Exception Decoder

If your ESP board is crashing, you may be able to use the exception decoder to understand the issue further.  How to use this and further advice can be found here.