This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
CURRENT_DIR=$(pwd) | |
# add gazebo repo | |
sudo sh -c 'echo "deb http://packages.osrfoundation.org/gazebo/ubuntu `lsb_release -cs` main" > /etc/apt/sources.list.d/gazebo-latest.list' || { exit 1; } | |
wget http://packages.osrfoundation.org/gazebo.key -O - | sudo apt-key add - || { exit 1; } | |
sudo apt-get update || { exit 1; } | |
# install dependencies |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export ROS_IP=`ifconfig eth0 | grep 'inet addr' | awk -F: '{print $2}' | awk '{print $1}'` | |
if [ -z "$ROS_IP" ]; then | |
export ROS_IP=`ifconfig wlan0 | grep 'inet addr' | awk -F: '{print $2}' | awk '{print $1}'` | |
fi | |
if [ -z "$ROS_IP" ]; then | |
export ROS_IP="127.0.0.1" | |
fi |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using Gadfly | |
points = [100 112; 500 23.25; 1000 12.05; 2000 6.5; 3000 4.65; 4000 3.8; 5000 3.2; 6000 2.8; 7000 2.55; 8000 2.35; 9000 2.2; 10000 2.1; 11000 2.0; 12000 1.9] | |
p = plot(x=points[:,1], y=points[:,2], Geom.point) | |
velocities = [100 0.044642857; 500 0.215053763; 1000 0.414937759; 2000 0.769230769; 3000 1.075268817; 4000 1.315789474; 5000 1.5625; 6000 1.785714286; 7000 1.960784314; 8000 2.127659574; 9000 2.272727273; 12000 2.631578947] | |
pv = plot(x=velocities[:,1], y=velocities[:,2], Geom.point) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using Gadfly | |
using Cairo | |
lin_vel = 0.3 | |
ang_vel = -π/4 | |
scale_setp = 0.2 | |
time_step = 0.05 | |
trajectories = Array(Float64, convert(Int32, 1/time_step),2,0) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using Gadfly | |
using Cairo | |
max_wheel_vel = 1.6 | |
wheel_base = 0.78 | |
calc_step = 0.01 | |
arcs = Array(Float64, 0, 2) | |
data = Array(Float64, 0, 2) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using Gadfly | |
using Cairo | |
# generate scan data | |
angle_min = -1.5; | |
angle_max = 1.5; | |
angle_increment = 0.1; | |
ranges = [5.0, 5.0, 4.5, 4.0, 3.5, 3.0, 3.5, 4.0, 4.5, 5.0, 5.0, 5.0, 5.0, 5.0, 5.0, 5.0, 5.0, 5.0, 5.0, 5.0, 5.0, 5.0, 4.5, 4.0, 3.5, 3.0, 3.5, 4.0, 4.5, 5.0] | |
# put a human | |
human = [1.5, 2.5] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# human-robot following graphs |
NewerOlder