0
$\begingroup$

Rosanswers logo

Hi, I have been using ROS for a while. Whenever, I pull some packages from github for understanding the work or to follow it , I found that a lot of the header files are linked to popular and useful packages (e.g. tf, tf2_ros etc. ). Due to my sole understanding, I find the need to edit some of these files which are not actually there in the package that I cloned from github. But I am not sure how to do it. It will be extremely helpful to me and will save lot of my time if someone could help me in understanding how to debug and play with any package in such a situation and make a good use it as required for my application.


Originally posted by Spartan_007 on ROS Answers with karma: 73 on 2017-10-26

Post score: 0


Original comments

Comment by Spartan_007 on 2017-10-28:
Can I use something like this for modifying required packages?

$\endgroup$

2 Answers 2

0
$\begingroup$

Rosanswers logo

What you can do is download the source of the packages in question, put them in your catkin workspace and compile them, just like you compile source for your packages by running catkin_make. Then source the setup.sh of your workspace and your environment should use the package that you compiled, not the installed one. You can verify this by typing roscd package_name and it should take you to the directory in question.

I do this when I want to slightly modify packages that other stuff uses. You can also uninstall the binaries to make sure they don't conflict with your source-built one.


Originally posted by psammut with karma: 258 on 2017-10-28

This answer was ACCEPTED on the original site

Post score: 1


Original comments

Comment by Spartan_007 on 2017-10-28:
ok, thanks.

$\endgroup$
0
$\begingroup$

This video shows how to use VS Code ROS extension for debugging. https://youtu.be/uqqHgYsskJI

Here is a guide on debugging in VS Code:

https://github.com/ms-iot/vscode-ros/blob/master/doc/debug-support.md

Debugging techniques from the command line: https://ctu-mrs.github.io/docs/software/gdb.html

$\endgroup$
1
  • 2
    $\begingroup$ While these links may answer the question, it's better to include essential parts of the solution in the answer itself and include the links for reference. Link-only answers can become invalid if the linked page changes. $\endgroup$
    – CPlus
    Commented Sep 18, 2023 at 2:12

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.