Debugging rtapi_app using Eclipse GDB
21 Jan 2016 16:09 #68885
by Lakshman
Debugging rtapi_app using Eclipse GDB was created by Lakshman
Greetings All,
I followed the steps specified in the below webpage to debug rtapi_app
using Eclipse GDB.
wiki.linuxcnc.org/cgi-bin/wiki.pl?Eclipse
But I got stuck at a point where the debugger breaks when there is a break
point. It says "No source file named canterp.cc". I tried even including
compilation directory path. It doesn't seem to work.
Can someone help me with this?
Thanks,
Lakshman
I followed the steps specified in the below webpage to debug rtapi_app
using Eclipse GDB.
wiki.linuxcnc.org/cgi-bin/wiki.pl?Eclipse
But I got stuck at a point where the debugger breaks when there is a break
point. It says "No source file named canterp.cc". I tried even including
compilation directory path. It doesn't seem to work.
Can someone help me with this?
Thanks,
Lakshman
Please Log in or Create an account to join the conversation.
22 Jan 2016 07:31 - 22 Jan 2016 11:41 #68908
by ArcEye
Replied by ArcEye on topic Debugging rtapi_app using Eclipse GDB
Hi,
I see you put this on the developers list too.
Yishin Li who wrote the wiki can mostly be found on the Machinekit forum.
He is from ariasrobo.com, so it would be well worth your contacting him about your robotic arm project.
At this stage you need to pick a horse and ride that one only. Machinekit is greatly changed code wise in some aspects from Linuxcnc and rtapi_app is one file that has changed.
I suspect you are trying to find the source of the error originating at line :339 of rtapi_app, when you run canterp. I think this is just an error printing function, you need to look further back.
There is a guide to debugging rt apps in the Machinekit docs, but if you can do it with debug print outs spread through the code, you are well advised to try that, it is a lot easier
machinekit-docs.readthedocs.org/en/lates...gging-RT-components/
also search the forum posts for 'Debugging RT'
groups.google.com/forum/#!msg/machinekit...MZu5mKA/hCV2OSr4g-QJ
regards
I see you put this on the developers list too.
Yishin Li who wrote the wiki can mostly be found on the Machinekit forum.
He is from ariasrobo.com, so it would be well worth your contacting him about your robotic arm project.
At this stage you need to pick a horse and ride that one only. Machinekit is greatly changed code wise in some aspects from Linuxcnc and rtapi_app is one file that has changed.
I suspect you are trying to find the source of the error originating at line :339 of rtapi_app, when you run canterp. I think this is just an error printing function, you need to look further back.
There is a guide to debugging rt apps in the Machinekit docs, but if you can do it with debug print outs spread through the code, you are well advised to try that, it is a lot easier
machinekit-docs.readthedocs.org/en/lates...gging-RT-components/
also search the forum posts for 'Debugging RT'
groups.google.com/forum/#!msg/machinekit...MZu5mKA/hCV2OSr4g-QJ
regards
Last edit: 22 Jan 2016 11:41 by ArcEye.
Please Log in or Create an account to join the conversation.
22 Jan 2016 09:12 - 22 Jan 2016 09:15 #68909
by ArcEye
Replied by ArcEye on topic Debugging rtapi_app using Eclipse GDB
PS.
If your error is not an RT one, which is primarily what the Machinekit doc is about,
there is a lot to be said for compiling with debug options on in the compiler for posix only
(or rt-preempt if you need some rt threads for what you are trying to debug)
It makes no sense whatsoever to build for rtai unless it is that build that is failing, you
just increase the level of complexity.
If I guess what you are trying to do correctly, you are just trying to trace the error flow, to work out what specifically is throwing the error, not actually find a bug.
regards
If your error is not an RT one, which is primarily what the Machinekit doc is about,
there is a lot to be said for compiling with debug options on in the compiler for posix only
(or rt-preempt if you need some rt threads for what you are trying to debug)
It makes no sense whatsoever to build for rtai unless it is that build that is failing, you
just increase the level of complexity.
If I guess what you are trying to do correctly, you are just trying to trace the error flow, to work out what specifically is throwing the error, not actually find a bug.
regards
Last edit: 22 Jan 2016 09:15 by ArcEye.
Please Log in or Create an account to join the conversation.
22 Jan 2016 13:25 #68915
by jepler
Replied by jepler on topic Debugging rtapi_app using Eclipse GDB
The code built from the source file "canterp.cc" is never loaded in rtapi_app.
When it is loaded, it is loaded dynamically by milltask (or rs274 or the python gcodemodule) when interp_from_shlib is called with the name of the shared library to load the gcode interpreter from.
But most linuxcnc setups do not use this "libcanterp.so" interpreter, they use the normal rs274 interpreter. Only the sample configuration file configs/sim/axis/canterp.in and the test interp/plug do.
When it is loaded, it is loaded dynamically by milltask (or rs274 or the python gcodemodule) when interp_from_shlib is called with the name of the shared library to load the gcode interpreter from.
But most linuxcnc setups do not use this "libcanterp.so" interpreter, they use the normal rs274 interpreter. Only the sample configuration file configs/sim/axis/canterp.in and the test interp/plug do.
Please Log in or Create an account to join the conversation.
23 Jan 2016 16:26 #68974
by andypugh
I think this is part of the project to use canonical motion commands from the step-nc toolkit.
Replied by andypugh on topic Debugging rtapi_app using Eclipse GDB
But most linuxcnc setups do not use this "libcanterp.so" interpreter, they use the normal rs274 interpreter. Only the sample configuration file configs/sim/axis/canterp.in and the test interp/plug do.
I think this is part of the project to use canonical motion commands from the step-nc toolkit.
Please Log in or Create an account to join the conversation.
Time to create page: 0.091 seconds