Skip to content
Snippets Groups Projects
Commit 4fb1b8bf authored by Paul Beuchat's avatar Paul Beuchat
Browse files

Updated install scripts for the new ROS packages key. Also added partial...

Updated install scripts for the new ROS packages key. Also added partial install script to make Rasp Pi installation easier
parent 644eaea5
No related branches found
No related tags found
No related merge requests found
# --------------------------------------------------------------- #
# CLONE THE D-FaLL-System REPOSITORY
# Make the "work" directory under the users root
# > Note: the -p option means: no error if existing, make parent directories as needed
mkdir -p ~/work
# Change directory to this folder
cd ~/work
# Install git
sudo apt -y install git
# Clone the D-FaLL-System git repository
git clone https://gitlab.ethz.ch/D-FaLL/PandS-System/D-FaLL-System.git
# --------------------------------------------------------------- #
# CREATE, COPY, EDIT A FEW NECESSARY FILES
# > NOTE: the "man sh" explain that the -c option specifies "sh" to:
# "Read commands from the command_string operand instead of from the standard input.
# Add the teacher's IP address to the /etc/hosts file
sudo sh -c "echo '10.42.0.10 dfallmaster' >> /etc/hosts"
# Add a new file with the default agent ID
sudo sh -c "echo $1 >> /etc/dfall_default_agent_id"
# Add a new file with the default coordinator ID
sudo sh -c "echo 1 >> /etc/dfall_default_coord_id"
# Copy rules necessary for using the Crazyradio
sudo cp ~/work/D-FaLL-System/install/99-crazyflie.rules /etc/udev/rules.d
sudo cp ~/work/D-FaLL-System/install/99-crazyradio.rules /etc/udev/rules.d
# --------------------------------------------------------------- #
# BUILD THE D-FaLL-System ROS PACKAGE
# > NOTE: This is done by calling "catkin_make" from the folder "dfall_ws",
# where "ws" stands for workspace
# > NOTE: the package that is built is named "dfall_pkg", as specified in the file
# .../dfall_ws/src/dfall_pkg/package.xml
# > NOTE: the -j4 option specifies the: Maximum number of build jobs to be
# distributed across active packages. (default is cpu count)
cd ~/work/D-FaLL-System/dfall_ws
catkin_make
# --------------------------------------------------------------- #
# ADD TO THE .bashrc THE D-FaLL-System CONFIG AND ROS PACKAGE SETUP
# Add the D-FaLL ROS Package setup to the .bashrc
echo "source ~/work/D-FaLL-System/dfall_ws/devel/setup.bash" >> ~/.bashrc
# And run it now so that it is valid for this terminal session
source ~/work/D-FaLL-System/dfall_ws/devel/setup.bash
# Add the "Config.sh" shell script to the .bashrc
echo "source ~/work/D-FaLL-System/dfall_ws/src/dfall_pkg/launch/Config.sh" >> ~/.bashrc
# And run it now so that it is valid for this terminal session
source ~/work/D-FaLL-System/dfall_ws/src/dfall_pkg/launch/Config.sh
# --------------------------------------------------------------- #
# ADD ROS PACKAGE SERVER AND KEY AS PER:
# http://wiki.ros.org/melodic/Installation/Ubuntu
# Setup the computer to accept software from packages.ros.org
sudo sh -c 'echo "deb http://packages.ros.org/ros/ubuntu $(lsb_release -sc) main" > /etc/apt/sources.list.d/ros-latest.list'
# Setup the keys
#sudo apt-key adv --keyserver hkp://ha.pool.sks-keyservers.net:80 --recv-key 421C365BD9FF1F717815A3895523BAEEB01FA116
sudo apt-key adv --keyserver hkp://ha.pool.sks-keyservers.net:80 --recv-key C1CF6E31E6BADE8868B172B4F42ED6FBAB17C654
\ No newline at end of file
......@@ -33,7 +33,8 @@ echo $1 | grep -E -q '^[0-9]+$' || die "Numeric argument required, $1 provided"
sudo sh -c 'echo "deb http://packages.ros.org/ros/ubuntu $(lsb_release -sc) main" > /etc/apt/sources.list.d/ros-latest.list'
# Setup the keys
sudo apt-key adv --keyserver hkp://ha.pool.sks-keyservers.net:80 --recv-key 421C365BD9FF1F717815A3895523BAEEB01FA116
#sudo apt-key adv --keyserver hkp://ha.pool.sks-keyservers.net:80 --recv-key 421C365BD9FF1F717815A3895523BAEEB01FA116
sudo apt-key adv --keyserver hkp://ha.pool.sks-keyservers.net:80 --recv-key C1CF6E31E6BADE8868B172B4F42ED6FBAB17C654
# Update the package index, i.e., the list of programs
sudo apt-get update
......@@ -46,6 +47,10 @@ sudo apt-get -y upgrade
# > Note: we use the configuration: "Desktop-Full Install: (Recommended)"
sudo apt-get -y install ros-kinetic-desktop-full
# > Note: for installing on a "headless" operating system, i.e., a Raspberry Pi
# without a graphical desktop, use the configuration: "ROS-Base: (Bare Bones)"
#sudo apt -y install ros-kinetic-ros-base
# Initialise and update rosdep
# > Note: rosdep enables you to easily install system dependencies for source you want to compile and is required to run some core components in ROS
sudo rosdep init
......
......@@ -33,7 +33,8 @@ echo $1 | grep -E -q '^[0-9]+$' || die "Numeric argument required, $1 provided"
sudo sh -c 'echo "deb http://packages.ros.org/ros/ubuntu $(lsb_release -sc) main" > /etc/apt/sources.list.d/ros-latest.list'
# Setup the keys
sudo apt-key adv --keyserver hkp://ha.pool.sks-keyservers.net:80 --recv-key 421C365BD9FF1F717815A3895523BAEEB01FA116
#sudo apt-key adv --keyserver hkp://ha.pool.sks-keyservers.net:80 --recv-key 421C365BD9FF1F717815A3895523BAEEB01FA116
sudo apt-key adv --keyserver hkp://ha.pool.sks-keyservers.net:80 --recv-key C1CF6E31E6BADE8868B172B4F42ED6FBAB17C654
# Update the package index, i.e., the list of programs
sudo apt update
......@@ -46,6 +47,10 @@ sudo apt -y upgrade
# > Note: we use the configuration: "Desktop-Full Install: (Recommended)"
sudo apt -y install ros-melodic-desktop-full
# > Note: for installing on a "headless" operating system, i.e., a Raspberry Pi
# without a graphical desktop, use the configuration: "ROS-Base: (Bare Bones)"
#sudo apt -y install ros-melodic-ros-base
# Initialise and update rosdep
# > Note: rosdep enables you to easily install system dependencies for source you want to compile and is required to run some core components in ROS
sudo rosdep init
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment