Skip to content
This repository has been archived by the owner on Apr 20, 2020. It is now read-only.

TheLurps/turtlebot3_docker

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 

Repository files navigation

turtlebot3 inside docker

start x server (macOS)

MBP:~ thelurps$ export IP=$(ifconfig en0 | grep inet | awk '$1=="inet" {print $2}')
MBP:~ thelurps$ /usr/X11/bin/xhost + $IP
MBP:~ thelurps$ open -a XQuartz

run container

MBP:~ thelurps$ $CATKIN_WS='~/catkin_ws'
MBP:~ thelurps$ docker run -ti --name turtlebot3 -e DISPLAY=$IP:0 -v /tmp/.X11-unix:/tmp/.X11-unix -v $CATKIN_WS:/root/catkin_ws thelurps/turtlebot3

setup catkin workspace

ros@turtlebot3:~/catkin_ws$ mkdir src
ros@turtlebot3:~/catkin_ws$ catkin_make
ros@turtlebot3:~/catkin_ws$ source devel/setup.bash

connect to container

MBP:~ thelurps$ docker exec -ti turtlebot3 bash

setup env

MBP:~ thelurps$ source ~/catkin_ws/devel/setup.bash
MBP:~ thelurps$ export TURTLEBOT3_MODEL=waffle

launch gazebo

MBP:~ thelurps$ roslaunch turtlebot3_gazebo turtlebot3_world.launch