ubuntu 18.04
ros distro : melodic
source:
wiki.ros.org/melodic/Installation/Ubuntu
wiki.ros.org/ROS/Tutorials/InstallingandConfiguringROSEnvironment
1. Install ROS
sudo sh -c 'echo "deb http://packages.ros.org/ros/ubuntu $(lsb_release -sc) main" > /etc/apt/sources.list.d/ros-latest.list'
sudo apt-key adv --keyserver 'hkp://keyserver.ubuntu.com:80' --recv-key C1CF6E31E6BADE8868B172B4F42ED6FBAB17C654
sudo apt update
sudo apt install ros-melodic-desktop-full
echo "source /opt/ros/melodic/setup.bash" >> ~/.bashrc
source ~/.bashrc
source /opt/ros/melodic/setup.bash
sudo apt install python-rosdep python-rosinstall python-rosinstall-generator python-wstool build-essential
sudo apt install python-rosdep
sudo rosdep init
rosdep update
2. Create a ROS Workspace
mkdir -p ~/catkin_ws/src
cd ~/catkin_ws/
catkin_make
3. Other settings
Open bashrc file
gedit ~/.bashrc
< ~/.bashrc > file
아래 내용을 붙여넣는다. 단축키 설정
source ~/catkin_ws/devel/setup.bash
alias eb='gedit ~/.bashrc'
alias sb='source ~/.bashrc'
alias cw='cd ~/catkin_ws'
alias cs='cd ~/catkin_ws/src'
alias cm='cd ~/catkin_ws && catkin_make'
export ROS_MASTER_URI=http://localhost:11311
export ROS_HOSTNAME=localhost
#export ROS_MASTER_URI=http://192.168.1.11:11311
#export ROS_HOSTNAME=192.168.1.11
source ~/.bashrc
alias : shortcut
'임시' 카테고리의 다른 글
PX4 Install (0) | 2020.09.03 |
---|