Noetic_Turtlesim_ROS_files 9_19_2022 ROS Data 9_19_2022 $ printenv | grep ROS NOTE: env | grep ROS (If printenv is not installed) Alias foxy or noetic harman@harman-VirtualBox:~$ noetic ROS_DISTRO was set to 'foxy' before. Please make sure that the environment does not mix paths from different distributions. harman@harman-VirtualBox:~$ printenv | grep ROS (env | grep ROS) ROS_VERSION=1 ROS_PYTHON_VERSION=3 ROS_PACKAGE_PATH=/opt/ros/noetic/share ROSLISP_PACKAGE_DIRECTORIES= ROS_DOMAIN_ID=231 ROS_ETC_DIR=/opt/ros/noetic/etc/ros ROS_MASTER_URI=http://localhost:11311 ROS_LOCALHOST_ONLY=0 ROS_ROOT=/opt/ros/noetic/share/ros ROS_DISTRO=noetic This is in my .bashrc nano .bashrc (cntl+X to Exit) $ source /opt/ros//setup.bash echo Alias foxy or noetic alias foxy='source /opt/ros/foxy/setup.bash' # Load Foxy,7_30_2021 or noetic alias noetic='source /opt/ros/noetic/setup.bash' harman@harman-VirtualBox:~$ rospack find turtlesim /opt/ros/noetic/share/turtlesim harman@harman-VirtualBox:~$ roscd turtlesim harman@harman-VirtualBox:/opt/ros/noetic/share/turtlesim$ ls -la total 36 drwxr-xr-x 6 root root 4096 Apr 2 23:59 . drwxr-xr-x 238 root root 12288 Jul 29 2021 .. drwxr-xr-x 2 root root 4096 Apr 2 23:59 cmake drwxr-xr-x 2 root root 4096 Apr 2 23:59 images drwxr-xr-x 2 root root 4096 Apr 2 23:59 msg -rw-r--r-- 1 root root 1564 Jul 31 2020 package.xml drwxr-xr-x 2 root root 4096 Apr 2 23:59 srv harman@harman-VirtualBox:/opt/ros/noetic/share/turtlesim$ cd ../.. harman@harman-VirtualBox:/opt/ros/noetic$ harman@harman-VirtualBox:/opt/ros/noetic$ tree -L 1 . ├── bin ├── env.sh ├── etc ├── include ├── lib ├── local_setup.bash ├── local_setup.sh ├── local_setup.zsh ├── setup.bash ├── setup.sh ├── _setup_util.py ├── setup.zsh └── share 5 directories, 8 files harman@harman-VirtualBox:/opt/ros/noetic$ nano setup.bash #!/usr/bin/env bash # generated from catkin/cmake/templates/setup.bash.in CATKIN_SHELL=bash # source setup.sh from same directory as this file _CATKIN_SETUP_DIR=$(builtin cd "`dirname "${BASH_SOURCE[0]}"`" > /dev/null && pwd) . "$_CATKIN_SETUP_DIR/setup.sh" tree man tree press h for help or q to quit harman@harman-VirtualBox:/opt/ros/noetic$ tree -L 2 (q to quit) (You won't believe it > 20 pages) TRY:q harman@harman-VirtualBox:/opt/ros/noetic$ tree -L 2 | more (Page by Page) harman@harman-VirtualBox:/opt/ros/noetic$ tree -L 3 | more ( A Really Long List) Turtlesim Executables --------------------------- harman@harman-VirtualBox:/opt/ros/noetic$ cd /opt/ros/noetic/lib harman@harman-VirtualBox:/opt/ros/noetic/lib$ ls -la total total 50976 (MANY MANY) harman@harman-VirtualBox:~$ harman@harman-VirtualBox:/opt/ros/noetic/lib$ cd /opt/ros/noetic/lib/turtlesim/ draw_square mimic turtlesim_node turtle_teleop_key harman@harman-VirtualBox:/opt/ros/noetic/lib/turtlesim$ ls -la total 572 drwxr-xr-x 2 root root 4096 Apr 2 23:59 . drwxr-xr-x 93 root root 20480 Sep 17 17:02 .. -rwxr-xr-x 1 root root 108944 Jan 6 2022 draw_square (Not for us to read) -rwxr-xr-x 1 root root 92512 Jan 6 2022 mimic -rwxr-xr-x 1 root root 301632 Jan 6 2022 turtlesim_node -rwxr-xr-x 1 root root 51640 Jan 6 2022 turtle_teleop_key Get the code itself https://answers.ros.org/question/246775/where-is-the-source-code-of-installed-packages/ You can retrive path to sources of specific package by typing roslocate uri , for more information about roslocate see reference. roslocate uri turtlesim (This takes us to the code) https://github.com/ros/ros_tutorials.git (ROS tutorials cpp, py, and Turtlesim https://github.com/ros/ros_tutorials.git ros_tutorials Update maintainers (#102) 2 years ago roscpp_tutorials use boost::placeholders::_1 instead of deprecated _1, 3 months ago rospy_tutorials added pointcoud2 example (#111) 2 years ago turtlesim use boost::placeholders::_1 instead of deprecated _1, 3 months ago (Boost.org Boost provides free peer-reviewed portable C++ source libraries.) harman@harman-VirtualBox:/opt/ros/noetic/lib/turtlesim$ locate ros_tutorials /home/harman/py_ws/src/ros_tutorials/turtlesim/tutorials/teleop_turtle_key.cpp harman@harman-VirtualBox:/opt/ros/noetic/share/ros_tutorials$ cd ~ harman@harman-VirtualBox:~$ cd /home/harman/py_ws/src/ros_tutorials/turtlesim/tutorials/ harman@harman-VirtualBox:~/py_ws/src/ros_tutorials/turtlesim/tutorials$ ls -la total 28 drwxrwxr-x 2 harman harman 4096 Jul 13 2021 . drwxrwxr-x 10 harman harman 4096 Jul 13 2021 .. -rw-rw-r-- 1 harman harman 3803 Jul 13 2021 draw_square.cpp -rw-rw-r-- 1 harman harman 943 Jul 13 2021 mimic.cpp -rw-rw-r-- 1 harman harman 8739 Jul 13 2021 teleop_turtle_key.cpp