I am sorry guys if I am asking a weird question,
can anyone guide me to debug in the studio.
Thanks in advance
If you tell me in which feature you find an issue, I can better understand the problem and help you to debug.
I am just a beginner to Zerynth, lik in other IDEs is there any probability of having step by step execution etc such debugging capabilities…
I am just asking this thing because I am obsessed with this way of debugging in traditional IDEs …is there any thing like this in Zerynth.
to debug your script in Python you can insert in critical points a try-except cycle printing the exception you get.
Furthermore, Zerynth Studio allows you to backtrace the exception you get; in your serial monitor, when you print the exception you can click over the exception and in the Zerynth Studio console you can find the backtrace of the exception.
Hope this can help you.
I am having the same problem. And I don’t think you have answered Boda’s question. In other IDE’s (especially for C and C++) it is possible, in debug mode, to execute each line of source code one by one, and inspect the contents of variables, registers, etc. at each step. You can also execute to break points specified in the source, or execute until a specified variable changes, etc. This is an extremely useful way of debugging, and I think it is what Boda was originally asking about.
The try-except block only works in the case of an unhandled exception, as is also the case with backtrace. But if the program runs to completion (i.e. does not raise an unhandled exception) but produces incorrect results or just doesn’t work, the only ways to discover the problem are to insert many print commands (or asserts) or use a line by line debugging tool. Adding many print commands is not optimal as the insertion of the extra commands can inadvertently alter program flow and introduce new bugs, which have to be debugged before the original problem can be debugged! Or worse still, removal of all the print commands after the program has been corrected can also create new bugs.
A line by line debugger is by far the best option for debugging, whether investigating unhandled exceptions or incorrect results.
So the question remains, does Zerynth have any kind of line by line debugging tool, and if so how do I set it up and use it?
later this month we will add support for JTag probes and GDB debugging style B) . Everything you can do with gdb will be doable from Zerynth Studio; “Python” breakpoints are in the queue, but we don’t have a deadline for them yet.
I am using esp32 DivKit, but i didn’t found, how to degub. Kindly update me, how i can debug code for esp32 Divkit