Three aliased commands are available:
debug: toggles debugging on and off
debug list: shows a list of all categories of debugging you are watching
debugc category: will add category to the list of watched debuggers. If it's already on the list, it will remove it. If no category is given, it behaves as "debug list" .
So for example if I am working on an autosipper, and am trying to debug it, I might do
debugc sipper
debug
To add the sipper category to the list of watched items, then toggle debug on. Then in my code, it may look something like this (replacing ... with relevant code):
And it will print a debugging message to the main window when it passes that branch in the code. If you pass a string or a number, it will echo it to the main window. If you pass a table for the second parameter to printDebug, it will run it through display().
And that's pretty much it in a nutshell. Package is attached, let me know if you have any questions.