Monday, February 25, 2013

installing ROS-electric on ubuntu


installing ROS-electric on ubuntu



First open the terminal and write the following command

“sudo sh -c 'echo "deb http://packages.ros.org/ros/ubuntu natty main" > /etc/apt/sources.list.d/ros-latest.list' “

Then add the keys (in terminal)

wget http://packages.ros.org/ros.key -O - | sudo apt-key add -

and if you are using a system that is set  to use proxy then write following command
“ wget --no-proxy http://packages.ros.org/ros.key -O - | sudo apt-key add - “



to make sure that package ros are added and can be indexed can be done as follows

rtrackp@rtrackp:~$ sudo apt-get update

verify the installation is correct by following



Then We preferred to install the complete ros that is ros desktop version by the following command. It will install ROS, rx, rviz, robot-generic libraries, 2D/3D simulators, navigation and 2D/3D perception .



If it asks for installation of packages write Y and press enter



one of the installation snapshot is shown below




It is good to add paths to your .bashrc by the following command

-->echo "source /opt/ros/electric/setup.bash" >> ~/.bashrc

Close the terminal and run the terminal again.
or just write
“  . ~/.bashrc “

To verify your installation is correct do the following command and it should take to the main directory

 “roscd”

Like shown below



if doesn’t take you to particular directory then check the path of your installation and set it in .bashrc.

Also to verify the installation do the echo to see the basic ROS Package path. it should  show something as following diagram




To verify that roscpp is installed , try to use rospack find command as follows

rospack find roscpp

it will give you the path where roscpp resides as shown below



pwd is used to go to parent working directory

Verify that you can create package with dependencies. To do this we will create the package name test_tutorial with dependency in roscpp and rospy.h
The command to create is as follows
     --- first do roscd , it will take you to working directory.
     --- then run roscreate-pkg test_tutorial std_msgs rospy roscpp

you should see the following output



to make the package we have to run rosmake, if the package compiles successfully without errors, then it is ok else check errors. To make the test_tutorial package please see the following

rtrackp@rtrackp:/opt/ros/electric/ros$ rosmake test_tutorial

and you should see the following output



--------Optional------
 
Go to and Click on “ros- Natty” and install the following software’s.

 



No comments:

Post a Comment