Open a terminal inside scripts folder and create a file name server.py. Copy the content from server.txt and paste. Open a terminal in the same location and Run
chmod +x server.py
to enable execute permission.
Open a terminal inside scripts folder and create a file name client.py. Copy the content from client.txt and paste. Open a terminal in the same location and Run
chmod +x client.py
to enable execute permission.
Open lab_2_3dPose/CMakeLists.txt and add following lines to the bottom of the file.
catkin_install_python(PROGRAMS scripts/client.py scripts/server.py
DESTINATION ${CATKIN_PACKAGE_BIN_DESTINATION}
)
Go to root of the workspace
cd ~/robotics/
catkin build
or
catkin_make
Go to root of the workspace and run
roscore
Go to root of the workspace and on a new terminal
cd ~/robotics/
source devel/setup.bash
or
rosrun lab_2_3dPose server.py
Go to root of the workspace and on a new terminal
cd ~/robotics/
source devel/setup.bash
or
rosrun lab_2_3dPose client.py