enters the Scilab debugger mode
debug enters the debug's mode for functions written in Scilab language.
The prompt becomes
This mode allows you to manage
launch execution with stop on error, execute a function step by step, ...
Commands available in debugging mode
h: Shows the debugger's help in the console.
help: In Scilab standard running mode (with GUIs), displays the debugger's help page in the help browser. Otherwise, displays the help in the console (as with "h").
(q)uit: Leaves the debug mode and returns to the normal Scilab mode.
(w)here or bt: Displays the callstack.
(e)xec or (r)un command : Executes the given Scilab command.
(d)isp var, or (p)rint var:
Displays the value of the variable
(c)ontinue: Continues the execution.
(a)bort: Aborts the execution.
step(n)ext or next: Executes the next expression.
step(i)n or in: Executes the next expression in sub function.
step(o)ut or out: Executes the next expression in previous function.
(b)reakpoint or break:
breakpoint function [line [condition]] :
Adds a breakpoint in a function at line
If a condition is specified, the breakpoint is enabled only if the condition
(del)ete [n]: Removes all breakpoints. If n is specified: removes the breakpoint #n.
enable [n]: Enables all breakpoints. If n is specified: enables the breakpoint #n.
disable [n]: Disables all breakpoints. If n is specified: disables the breakpoint #n.
(s)how [n]: Shows all breakpoints information. If n is specified: shows the breakpoint #n.
How to debug a script
Debugging a series of Scilab instructions out of any function requires first to embed them in a dummy function. Example: We want to debug the following instructions
Then we must first rewrite them as
and execute this code (in normal Scilab mode) in order to define script() in Scilab. Then breakpoints can be defined and handled within the script() function as for any other function.
|6.0.0||New version: console interface to Scilab 6 debugger.|
|Report an issue|
|<< Debugging||Debugging||where >>|