Monday, April 29, 2013
Wednesday, April 17, 2013
Wednesday, April 03, 2013
Matlab Long Simulation Interactive Debug , Set Debug flag using GUI , Pause execution to debug
Create a button function:
function util_DebugGuiButtons()
global debugFlag;
uicontrol('Position',[30 10 35 40],'String','||','Callback',@wait);
uicontrol('Position',[70 10 35 40],'String','>>','Callback',@dontwait);
function wait(hObject,eventdata)
debugFlag = 1;
end
function dontwait(hObject,eventdata)
debugFlag = 0;
dbcont;
end
end
Define in top of document:
global debugFlag
Put this inside your loop :
if (debugFlag)
dbstop in file.m at line
end
Continue Button is not working as desired now. It just clears the breakpoints but does not issue dbcont command properly. I will try to figure out later.
function util_DebugGuiButtons()
global debugFlag;
uicontrol('Position',[30 10 35 40],'String','||','Callback',@wait);
uicontrol('Position',[70 10 35 40],'String','>>','Callback',@dontwait);
function wait(hObject,eventdata)
debugFlag = 1;
end
function dontwait(hObject,eventdata)
debugFlag = 0;
dbcont;
end
end
Define in top of document:
global debugFlag
Put this inside your loop :
if (debugFlag)
dbstop in file.m at line
end
Continue Button is not working as desired now. It just clears the breakpoints but does not issue dbcont command properly. I will try to figure out later.
Subscribe to:
Posts (Atom)
AI
Despite the benefits of AI we are starving for humanity.
-
It is difficult to create robot that cleans our arbitrary dirty dishes. However , if we put some digital information on dishes (special des...
-
Our parents were arranging their schedule according to sunrise and sunset. They are still consistent in their habit. However, in our generat...
-
Robot Particles Display: Current display devices can show any image for a very cheap price. But it will be very intresting if someone tr...