-
Notifications
You must be signed in to change notification settings - Fork 5
Installation
This article covers a basic installation manual to install all required software to run the simulation. The installation on the car is nearly equal but got some cornercases that are not covered here. After install and checkout of the project, please read Manual toad.sh how to run the software.
I assume we start with a clean installed system. My hardware:
- CPU AMD Ryzen 3600
- 16GB RAM
- 120 GB SSD SATA
- Nvidia GTX 1060 6 GB
This can also be installed in a VM. I tested it with Virtual-Box and activated 3D support - but don't expect too much performance from RVIZ.
Install fresh and clean Ubuntu 18.04. Activate installation of 3rd party drivers and use LVM.
On my system (NVidia Card) I cannot login. Switch to console with Ctrl+Alt+F2, login and
sudo su
apt-get update
apt-get install nvidia-driver-465
exit
After a reboot I can login.
Next do upgrade and install some basic software:
sudo su
apt-get update
apt-get -y upgrade
apt-get -y dist-upgrade
exit
Reboot
sudo su
sh -c 'echo "deb http://packages.ros.org/ros/ubuntu $(lsb_release -sc) main" > /etc/apt/sources.list.d/ros-latest.list'
apt-key adv --keyserver 'hkp://keyserver.ubuntu.com:80' --recv-key C1CF6E31E6BADE8868B172B4F42ED6FBAB17C654
sh -c 'echo "deb http://packages.osrfoundation.org/gazebo/ubuntu-stable `lsb_release -cs` main" > /etc/apt/sources.list.d/gazebo-stable.list'
apt-key adv --keyserver 'hkp://keyserver.ubuntu.com:80' --recv-key F42ED6FBAB17C654
wget http://packages.osrfoundation.org/gazebo.key -O - | sudo apt-key add -
apt-get update
apt-get -y upgrade
apt-get -y dist-upgrade
exit
sudo su
apt-get install -y vim git python-catkin-tools libsdl2-dev ros-melodic-ackermann-msgs ros-melodic-serial ros-melodic-desktop-full gazebo9 libgazebo9-dev ros-melodic-gazebo-ros-control mplayer ffmpeg mencoder netcat ros-melodic-rviz-imu-plugin ros-melodic-depthimage-to-laserscan ros-melodic-jsk-rviz-plugins
apt-get install -y libignition-math2-dev
apt-get install -y python-rosinstall python-rosinstall-generator python-wstool build-essential python-rosdep
exit
sudo su
rosdep init
rosdep update
exit
export PATHROS="/opt/ros/melodic/setup.bash"
source $PATHROS
sudo su
export PATHROS="/opt/ros/melodic/setup.bash"
source $PATHROS
python -m pip uninstall -y pip
apt-get install -y python-pip
apt-get install -y libsdl2-dev clang-format python-pyqtgraph
python2 -m pip install --upgrade pip --force
python2 -m pip install --no-cache-dir torch autopep8 cython circle-fit
pip install autopep8
exit
wstool init
wstool up
sudo su
source /etc/lsb-release
wget https://developer.download.nvidia.com/compute/cuda/repos/ubuntu1804/x86_64/cuda-ubuntu1804.pin -O /etc/apt/preferences.d/cuda-repository-pin-600
apt-key adv --fetch-keys https://developer.download.nvidia.com/compute/cuda/repos/ubuntu1804/x86_64/7fa2af80.pub
add-apt-repository "deb http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1804/x86_64/ /"
apt-get update
apt-get -y upgrade
apt-get -y dist-upgrade
apt-get -y install cuda-10-2
exit
sudo su
CUDA_HOME=/usr/local/cuda-10.2
LD_LIBRARY_PATH=${CUDA_HOME}/lib64:${LD_LIBRARY_PATH}
PATH=${CUDA_HOME}/bin:${PATH}
wget https://download.stereolabs.com/zedsdk/3.1/cu102/ubuntu18 -O /tmp/zed_sdk.run
chmod +x /tmp/zed_sdk.run
/tmp/zed_sdk.run -- silent skip_tools
exit
mkdir -p ~/ARPG
cd ~/ARPG && git clone http://github.com/kctess5/range_libc
cd ~/ARPG/range_libc/pywrapper && ./compile.sh
sudo su
rosdep fix-permissions
apt-get -y autoremove
apt-get clean
exit
export GITREPO="https://github.com/arpg-sophisticated/ar-tu-do.git"
export GITBRANCH="development"
cd ~/ARPG && git clone $GITREPO
cd ~/ARPG/ar-tu-do && git submodule init
cd ~/ARPG/ar-tu-do && git submodule update --recursive
cd ~/ARPG/ar-tu-do && rosdep update
cd ~/ARPG/ar-tu-do/ros_ws && rosdep install -y --from-paths ./src --ignore-src --rosdistro melodic
cd ~/ARPG/ar-tu-do/ && git checkout $GITBRANCH
cd ~/ARPG/ar-tu-do/ && git pull
export PATHROS="/opt/ros/melodic/setup.bash"
source $PATHROS
cd ~/ARPG/ar-tu-do/ros_ws && catkin_make
cd ~/ARPG/ar-tu-do/ros_ws && cp -a toad.example toad.settings
Now edit toad.settings and set CONFIGURED to 1 and do
cd ~/ARPG/ar-tu-do/ros_ws && ./toad.sh system run
Now the simulation should run. As we optimized parameters for real racing the car has problems with the track. Please open RQT in a second terminal
cd ~/ARPG/ar-tu-do/ros_ws && source ./devel/setup.bash && rosrun rqt_reconfigure rqt_reconfigure
and configure the parameters of the wallfollowing topic. You can find more information about the parameters in the wiki. What made 3 laps without dodge or crash:
ulr 240
tm 2
voxel off
swd 0.22
mpd 9.99
max_sp 20
mpsa 0.99
msa 30
pidp 2.5
pidi 1.0
pidd 0.02
awu 0.2
For a more optimized version of the wallfollowing please checkout wallfollowing-improvements branches.