Prezentace aplikace PowerPointspanel/ROSWorkshop2013/2_1 SLAM.pdf · Bozetechova 2, 612 66 Brno...

19
Soso’s knowledge Laser, Kinect, Gmapping, Localization, PathPlanning Faculty of Information Technology, Brno University of Technology Bozetechova 2, 612 66 Brno [email protected] 99.99.9999

Transcript of Prezentace aplikace PowerPointspanel/ROSWorkshop2013/2_1 SLAM.pdf · Bozetechova 2, 612 66 Brno...

Page 1: Prezentace aplikace PowerPointspanel/ROSWorkshop2013/2_1 SLAM.pdf · Bozetechova 2, 612 66 Brno name@fit.vutbr.cz 99.99.9999 . Sensors XIP 2 Laser scanners Tactile sensors ... •

Soso’s knowledge

Laser, Kinect, Gmapping, Localization, PathPlanning

Faculty of Information Technology, Brno University of Technology Bozetechova 2, 612 66 Brno

[email protected]

99.99.9999

Page 2: Prezentace aplikace PowerPointspanel/ROSWorkshop2013/2_1 SLAM.pdf · Bozetechova 2, 612 66 Brno name@fit.vutbr.cz 99.99.9999 . Sensors XIP 2 Laser scanners Tactile sensors ... •

Sensors

XIP 2

Laser scanners

Tactile sensors

Stereo cameras

Kinect

Odometry sensors

Page 3: Prezentace aplikace PowerPointspanel/ROSWorkshop2013/2_1 SLAM.pdf · Bozetechova 2, 612 66 Brno name@fit.vutbr.cz 99.99.9999 . Sensors XIP 2 Laser scanners Tactile sensors ... •

Odometry sensors

• Use data from motion sensors to estimate change in position over time

• Sensitive to errors

EF 3

Page 4: Prezentace aplikace PowerPointspanel/ROSWorkshop2013/2_1 SLAM.pdf · Bozetechova 2, 612 66 Brno name@fit.vutbr.cz 99.99.9999 . Sensors XIP 2 Laser scanners Tactile sensors ... •

Odometry sensors

• Use data from motion sensors to estimate change in position over time

• Sensitive to errors

DS 4

Page 5: Prezentace aplikace PowerPointspanel/ROSWorkshop2013/2_1 SLAM.pdf · Bozetechova 2, 612 66 Brno name@fit.vutbr.cz 99.99.9999 . Sensors XIP 2 Laser scanners Tactile sensors ... •

Laser scanner (LIDAR)

• Measures distance to objects using laser pulses

• Mostly 2D, 3D lidars also exist

ZQ 5

Page 6: Prezentace aplikace PowerPointspanel/ROSWorkshop2013/2_1 SLAM.pdf · Bozetechova 2, 612 66 Brno name@fit.vutbr.cz 99.99.9999 . Sensors XIP 2 Laser scanners Tactile sensors ... •

Laser scanner (LIDAR)

• Representation of laser scan in ROS

UT 6

Header header # timestamp in the header is the acquisition time of # the first ray in the scan. # # in frame frame_id, angles are measured around # the positive Z axis (counterclockwise, if Z is up) # with zero angle being forward along the x axis float32 angle_min # start angle of the scan [rad] float32 angle_max # end angle of the scan [rad] float32 angle_increment # angular distance between measurements [rad] float32 time_increment # time between measurements [seconds] - if your scanner # is moving, this will be used in interpolating position # of 3d points float32 scan_time # time between scans [seconds] float32 range_min # minimum range value [m] float32 range_max # maximum range value [m] float32[] ranges # range data [m] (Note: values < range_min or > range_max should be discarded) float32[] intensities # intensity data [device-specific units]. If your # device does not provide intensities, please leave # the array empty.

Page 7: Prezentace aplikace PowerPointspanel/ROSWorkshop2013/2_1 SLAM.pdf · Bozetechova 2, 612 66 Brno name@fit.vutbr.cz 99.99.9999 . Sensors XIP 2 Laser scanners Tactile sensors ... •

Displaying Laser scan in RVIZ

• Play bagfile with data:

UI 7

roslaunch btb_gazebo robot_simple_world.lauch

• Run RVIZ rosrun rviz rviz

• Add – Laser Scan

• Set topic to /scan

• Set Global Options – Fixed frame to /laser

Page 8: Prezentace aplikace PowerPointspanel/ROSWorkshop2013/2_1 SLAM.pdf · Bozetechova 2, 612 66 Brno name@fit.vutbr.cz 99.99.9999 . Sensors XIP 2 Laser scanners Tactile sensors ... •

Kinect and Laser scan from Kinect

• Kinect provides RGB image, depth image, accelerometers

• Dense Point clouds are easily computed

• Disadvantage: short range

JT 8

Come at me, bro!

Page 9: Prezentace aplikace PowerPointspanel/ROSWorkshop2013/2_1 SLAM.pdf · Bozetechova 2, 612 66 Brno name@fit.vutbr.cz 99.99.9999 . Sensors XIP 2 Laser scanners Tactile sensors ... •

Kinect PCL to Laser Scan

HF 9

• Play bagfile with Kinect data: rosbag play --loop kinect_data.bag

• Run RVIZ rosrun rviz rviz

• Set Global Options – Fixed frame to /openni_camera

• Add – PointCloud2

• Set topic to: /camera/depth/points

• Run the kinect2laser launchfile: roslaunch btb_kinect_2_laser_demo kinect2laser.launch

• Add – Laser Scan

• Set topic to: /narrow_scan

Page 10: Prezentace aplikace PowerPointspanel/ROSWorkshop2013/2_1 SLAM.pdf · Bozetechova 2, 612 66 Brno name@fit.vutbr.cz 99.99.9999 . Sensors XIP 2 Laser scanners Tactile sensors ... •

GMapping

• Simultaneous Localization And Mapping

• Sensors

• Data asociation

• High dimensionality

UT 10

Page 11: Prezentace aplikace PowerPointspanel/ROSWorkshop2013/2_1 SLAM.pdf · Bozetechova 2, 612 66 Brno name@fit.vutbr.cz 99.99.9999 . Sensors XIP 2 Laser scanners Tactile sensors ... •

GMapping

• 3DOF

• Odometry + LASER

• Particle filtering

• Supported is ROS

GS 11

Page 12: Prezentace aplikace PowerPointspanel/ROSWorkshop2013/2_1 SLAM.pdf · Bozetechova 2, 612 66 Brno name@fit.vutbr.cz 99.99.9999 . Sensors XIP 2 Laser scanners Tactile sensors ... •

Gmapping - DEMO

FF 12

• Run the TB sumilator roslaunch btb_gazebo robot_simple_world.lauch

• Run GMapping roslaunch btb_navigation gmapping.launch

• Run RVIZ rosrun rviz rviz

• Run teleoperation roslaunch btb_teleop keyboard_teleop.launch

• Set Global Options – Fixed frame to /map

• Use keys (described in terminal) to move and map

Page 13: Prezentace aplikace PowerPointspanel/ROSWorkshop2013/2_1 SLAM.pdf · Bozetechova 2, 612 66 Brno name@fit.vutbr.cz 99.99.9999 . Sensors XIP 2 Laser scanners Tactile sensors ... •

Gmapping – saving/loading the map

CFF 13

• Map can be saves using map_server

• Saved as .pgm + metadata

• Impossible to load map and continue mapping using gmapping

• Save map:

• Load map:

rosrun map_server map_saver -f <map name>

rosrun map_server map_server <map name>

Page 14: Prezentace aplikace PowerPointspanel/ROSWorkshop2013/2_1 SLAM.pdf · Bozetechova 2, 612 66 Brno name@fit.vutbr.cz 99.99.9999 . Sensors XIP 2 Laser scanners Tactile sensors ... •

Localization

• The “localization” part of SLAM

• Assumes known map

• We will be working with particle filter localization

SG 14

Page 15: Prezentace aplikace PowerPointspanel/ROSWorkshop2013/2_1 SLAM.pdf · Bozetechova 2, 612 66 Brno name@fit.vutbr.cz 99.99.9999 . Sensors XIP 2 Laser scanners Tactile sensors ... •

Localization

SP 15

• Run the TB sumilator (if not running) roslaunch btb_gazebo robot_simple_world.lauch

• Load our previously built map rosrun map_server map_server <map name>

• Hide the robot anywhere you want

• Run move base roslaunch btb_navigation move_base_turtlebot_laser.launch

• Run teleoperation roslaunch btb_teleop keyboard_teleop.launch

• Run Amcl roslaunch btb_navigation amcl_turtlebot.launch

• In RVIZ – 2D pose estimate – click and drag

• Send destination goal – 2D nav goal – click and drag

Page 16: Prezentace aplikace PowerPointspanel/ROSWorkshop2013/2_1 SLAM.pdf · Bozetechova 2, 612 66 Brno name@fit.vutbr.cz 99.99.9999 . Sensors XIP 2 Laser scanners Tactile sensors ... •

Path Planning

• Responsible for calculating a global path

• assuming it is provided with:

• Map

• A goal location in that map

• robot's current pose

NNF 16

Page 17: Prezentace aplikace PowerPointspanel/ROSWorkshop2013/2_1 SLAM.pdf · Bozetechova 2, 612 66 Brno name@fit.vutbr.cz 99.99.9999 . Sensors XIP 2 Laser scanners Tactile sensors ... •

Path planning

, 17

Page 18: Prezentace aplikace PowerPointspanel/ROSWorkshop2013/2_1 SLAM.pdf · Bozetechova 2, 612 66 Brno name@fit.vutbr.cz 99.99.9999 . Sensors XIP 2 Laser scanners Tactile sensors ... •

TB2 LIVE DEMO

(ABC-1) 18

It’s ALIVE!

Page 19: Prezentace aplikace PowerPointspanel/ROSWorkshop2013/2_1 SLAM.pdf · Bozetechova 2, 612 66 Brno name@fit.vutbr.cz 99.99.9999 . Sensors XIP 2 Laser scanners Tactile sensors ... •

Záhlaví (99.99.9999) 19

It’s over, yaaay!!