Skip to content

Commit

Permalink
Merge pull request #105 from prl-mushr/noetic-build-fixes
Browse files Browse the repository at this point in the history
Noetic build fixes
  • Loading branch information
schmittlema authored Apr 24, 2023
2 parents a39919d + b921100 commit 1704b35
Show file tree
Hide file tree
Showing 8 changed files with 25 additions and 12 deletions.
13 changes: 10 additions & 3 deletions mushr_utils/install/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
FROM ubuntu:focal

MAINTAINER Matt Schmittle <[email protected]>
LABEL maintainer="Matt Schmittle <[email protected]>"
ARG DEBIAN_FRONTEND=noninteractive
# 1 = real robot, 0 = sim (laptop)
ARG REAL
WORKDIR /root

# Install docker deps for mushr_install
Expand All @@ -22,7 +24,12 @@ ADD src/mushr/mushr_utils/install/install_scripts/mushr_install_deps.bash instal
RUN chmod +x install_scripts/mushr_install_deps.bash && install_scripts/mushr_install_deps.bash

# Hardware drivers
# 1 = real robot, 0 = sim (laptop)
ARG REAL
ADD src/mushr/mushr_utils/install/install_scripts/mushr_install_hw_drivers.bash install_scripts/mushr_install_hw_drivers.bash
RUN if [ "$REAL" = 1 ] ; then chmod +x install_scripts/mushr_install_hw_drivers.bash && install_scripts/mushr_install_hw_drivers.bash ; fi

# Set ROS_IP
RUN if [ "$REAL" = 1 ] ; then \
echo "export ROS_IP=\$(ifconfig wlan0 | grep 'inet ' | awk '{print \$2}')" >> ~/.bashrc ; \
else \
echo "export ROS_IP=\$(ifconfig eth0 | grep 'inet ' | awk '{print \$2}')" >> ~/.bashrc ; \
fi
1 change: 1 addition & 0 deletions mushr_utils/install/docker-compose-build-cpu.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,4 @@ services:
environment:
- DISPLAY=${DISPLAY}
- QT_X11_NO_MITSHM=1
- MUSHR_REAL_ROBOT=${MUSHR_REAL_ROBOT}
2 changes: 2 additions & 0 deletions mushr_utils/install/docker-compose-build-robot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ version: "3.4"
services:
mushr_noetic:
image: mushr/mushr:${MUSHR_OS_TYPE}
network_mode: "host"
build:
context: ${MUSHR_WS_PATH}/catkin_ws
dockerfile: ${MUSHR_INSTALL_PATH}/Dockerfile
Expand Down Expand Up @@ -33,3 +34,4 @@ services:
- QT_X11_NO_MITSHM=1
- NEVIAID_DRIVER_CAPABILITIES=all
- NVIDIA_VISIBLE_DEVICES=all
- MUSHR_REAL_ROBOT=${MUSHR_REAL_ROBOT}
1 change: 1 addition & 0 deletions mushr_utils/install/docker-compose-cpu.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,4 @@ services:
environment:
- DISPLAY=${DISPLAY}
- QT_X11_NO_MITSHM=1
- MUSHR_REAL_ROBOT=${MUSHR_REAL_ROBOT}
1 change: 1 addition & 0 deletions mushr_utils/install/docker-compose-robot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,3 +28,4 @@ services:
- QT_X11_NO_MITSHM=1
- NEVIAID_DRIVER_CAPABILITIES=all
- NVIDIA_VISIBLE_DEVICES=all
- MUSHR_REAL_ROBOT=${MUSHR_REAL_ROBOT}
9 changes: 1 addition & 8 deletions mushr_utils/install/install_scripts/mushr_install_deps.bash
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ apt-get update
apt-get install -y python3-catkin-tools

# Install Cython, PyTorch 1.10 at least!
pip3 install Cython torch torchvision torchaudio numpy scipy progress --upgrade
pip3 install Cython torch torchvision torchaudio numpy scipy networkx progress --upgrade

# Create OpenCV symbolic link
ln -s /usr/include/opencv4 /usr/include/opencv
Expand All @@ -35,10 +35,3 @@ rm -rf range_libc
# Create default RVIZ setup
mkdir ~/.rviz
cp ~/catkin_ws/src/mushr/mushr_utils/rviz/default.rviz ~/.rviz/

# Set ROS_IP
if [[ $MUSHR_REAL_ROBOT == 1 ]]; then
echo "export ROS_IP=\$(ifconfig wlan0 | grep 'inet ' | awk '{print \$2}')" >> ~/.bashrc
else
echo "export ROS_IP=\$(ifconfig eth0 | grep 'inet ' | awk '{print \$2}')" >> ~/.bashrc
fi
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,6 @@ qmake -qt=qt5
make clean & make

# Install push-button drivers
pip install Jetson.GPIO -y
pip install Jetson.GPIO
rm /usr/bin/python
ln -s /usr/bin/python3 /usr/bin/python
8 changes: 8 additions & 0 deletions nav-repos.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,11 @@ repositories:
type: git
url: https://github.com/prl-mushr/mushr_rhc.git
version: noetic
mushr_gp:
type: git
url: https://github.com/prl-mushr/mushr_gp.git
version: main
mushr_gprm:
type: git
url: https://github.com/prl-mushr/mushr_gprm.git
version: master

0 comments on commit 1704b35

Please sign in to comment.