![Page 1: Designing Autonomous Robotic Systems with MATLAB and Simulink€¦ · • Connect MATLAB and Simulink to ROS • Automatically generate C++ for ROS nodes Co-simulation with Gazebo](https://reader033.vdocuments.site/reader033/viewer/2022060607/605c973842c9c3191c072ef8/html5/thumbnails/1.jpg)
1© 2017 The MathWorks, Inc.
Designing Autonomous Robotic
Systems with MATLAB and Simulink
Carlos Santacruz-Rosero, PhD
Sr Application Engineer – Robotics
Pulkit Kapur
Sr Industry Manager – Robotics
Trudy Rippel
Account Management Team
![Page 2: Designing Autonomous Robotic Systems with MATLAB and Simulink€¦ · • Connect MATLAB and Simulink to ROS • Automatically generate C++ for ROS nodes Co-simulation with Gazebo](https://reader033.vdocuments.site/reader033/viewer/2022060607/605c973842c9c3191c072ef8/html5/thumbnails/2.jpg)
2
Robotics Applications using MATLAB and Simulink
Autonomous Ground Robots Manipulator Arms
Visual Odometry Advanced Perception and Planning
![Page 3: Designing Autonomous Robotic Systems with MATLAB and Simulink€¦ · • Connect MATLAB and Simulink to ROS • Automatically generate C++ for ROS nodes Co-simulation with Gazebo](https://reader033.vdocuments.site/reader033/viewer/2022060607/605c973842c9c3191c072ef8/html5/thumbnails/3.jpg)
3
Some challenges….
Applying Multidomain Expertise
Technical Depth and System Stability
IP Protection
End-to-End workflows
Complexity of Algorithms
![Page 4: Designing Autonomous Robotic Systems with MATLAB and Simulink€¦ · • Connect MATLAB and Simulink to ROS • Automatically generate C++ for ROS nodes Co-simulation with Gazebo](https://reader033.vdocuments.site/reader033/viewer/2022060607/605c973842c9c3191c072ef8/html5/thumbnails/4.jpg)
4
![Page 5: Designing Autonomous Robotic Systems with MATLAB and Simulink€¦ · • Connect MATLAB and Simulink to ROS • Automatically generate C++ for ROS nodes Co-simulation with Gazebo](https://reader033.vdocuments.site/reader033/viewer/2022060607/605c973842c9c3191c072ef8/html5/thumbnails/5.jpg)
5
![Page 6: Designing Autonomous Robotic Systems with MATLAB and Simulink€¦ · • Connect MATLAB and Simulink to ROS • Automatically generate C++ for ROS nodes Co-simulation with Gazebo](https://reader033.vdocuments.site/reader033/viewer/2022060607/605c973842c9c3191c072ef8/html5/thumbnails/6.jpg)
6
![Page 7: Designing Autonomous Robotic Systems with MATLAB and Simulink€¦ · • Connect MATLAB and Simulink to ROS • Automatically generate C++ for ROS nodes Co-simulation with Gazebo](https://reader033.vdocuments.site/reader033/viewer/2022060607/605c973842c9c3191c072ef8/html5/thumbnails/7.jpg)
7
Agenda
▪ Introduction
▪ Demo
▪ Conclusion
![Page 8: Designing Autonomous Robotic Systems with MATLAB and Simulink€¦ · • Connect MATLAB and Simulink to ROS • Automatically generate C++ for ROS nodes Co-simulation with Gazebo](https://reader033.vdocuments.site/reader033/viewer/2022060607/605c973842c9c3191c072ef8/html5/thumbnails/8.jpg)
8
DemoPlatform
Perception
Control
Planning
Sense
Connect
![Page 9: Designing Autonomous Robotic Systems with MATLAB and Simulink€¦ · • Connect MATLAB and Simulink to ROS • Automatically generate C++ for ROS nodes Co-simulation with Gazebo](https://reader033.vdocuments.site/reader033/viewer/2022060607/605c973842c9c3191c072ef8/html5/thumbnails/9.jpg)
9
C++ ROS node
![Page 10: Designing Autonomous Robotic Systems with MATLAB and Simulink€¦ · • Connect MATLAB and Simulink to ROS • Automatically generate C++ for ROS nodes Co-simulation with Gazebo](https://reader033.vdocuments.site/reader033/viewer/2022060607/605c973842c9c3191c072ef8/html5/thumbnails/10.jpg)
10
Ground Vehicle Co-simulation with Gazebo
![Page 11: Designing Autonomous Robotic Systems with MATLAB and Simulink€¦ · • Connect MATLAB and Simulink to ROS • Automatically generate C++ for ROS nodes Co-simulation with Gazebo](https://reader033.vdocuments.site/reader033/viewer/2022060607/605c973842c9c3191c072ef8/html5/thumbnails/11.jpg)
11
Modeling: Import CAD and URDF
![Page 12: Designing Autonomous Robotic Systems with MATLAB and Simulink€¦ · • Connect MATLAB and Simulink to ROS • Automatically generate C++ for ROS nodes Co-simulation with Gazebo](https://reader033.vdocuments.site/reader033/viewer/2022060607/605c973842c9c3191c072ef8/html5/thumbnails/12.jpg)
12
MATLAB, Simulink, and ROS
MATLAB Code
SM Models
Built-in
algorithms
Robot
ROS node
Simulation
environment
Networking
Code Generation
ROS Bag import
![Page 13: Designing Autonomous Robotic Systems with MATLAB and Simulink€¦ · • Connect MATLAB and Simulink to ROS • Automatically generate C++ for ROS nodes Co-simulation with Gazebo](https://reader033.vdocuments.site/reader033/viewer/2022060607/605c973842c9c3191c072ef8/html5/thumbnails/13.jpg)
13
Synthetic
data
Fusion & Tracking Algorithm Development Workflow
Logged
multi-sensor
data
Algorithm
Create new scenario or refine sensor model
Collect lab data
Refine algorithm
yes
no
Expected
Behavior
C Code
Generate code
Integrate
with embedded
environment
![Page 14: Designing Autonomous Robotic Systems with MATLAB and Simulink€¦ · • Connect MATLAB and Simulink to ROS • Automatically generate C++ for ROS nodes Co-simulation with Gazebo](https://reader033.vdocuments.site/reader033/viewer/2022060607/605c973842c9c3191c072ef8/html5/thumbnails/14.jpg)
14
Humanoid Simulation
![Page 15: Designing Autonomous Robotic Systems with MATLAB and Simulink€¦ · • Connect MATLAB and Simulink to ROS • Automatically generate C++ for ROS nodes Co-simulation with Gazebo](https://reader033.vdocuments.site/reader033/viewer/2022060607/605c973842c9c3191c072ef8/html5/thumbnails/15.jpg)
15
Planning and Control for Ground Robots
![Page 16: Designing Autonomous Robotic Systems with MATLAB and Simulink€¦ · • Connect MATLAB and Simulink to ROS • Automatically generate C++ for ROS nodes Co-simulation with Gazebo](https://reader033.vdocuments.site/reader033/viewer/2022060607/605c973842c9c3191c072ef8/html5/thumbnails/16.jpg)
16
Integrate with common robotics frameworks
• Import and filter ROS
bags
• Connect MATLAB and
Simulink to ROS
• Automatically generate
C++ for ROS nodes
Co-simulation with Gazebo (CAT Vehicle Simulator) Clear separation between your algorithm
and the middleware/hardware
![Page 17: Designing Autonomous Robotic Systems with MATLAB and Simulink€¦ · • Connect MATLAB and Simulink to ROS • Automatically generate C++ for ROS nodes Co-simulation with Gazebo](https://reader033.vdocuments.site/reader033/viewer/2022060607/605c973842c9c3191c072ef8/html5/thumbnails/17.jpg)
17Path Tracking for Unmanned Ground Vehicle
![Page 18: Designing Autonomous Robotic Systems with MATLAB and Simulink€¦ · • Connect MATLAB and Simulink to ROS • Automatically generate C++ for ROS nodes Co-simulation with Gazebo](https://reader033.vdocuments.site/reader033/viewer/2022060607/605c973842c9c3191c072ef8/html5/thumbnails/18.jpg)
18
Robot SimulationLow-Level ControlRobotics Algorithm
Pure Pursuit with UGV: Multi-domain simulation
![Page 19: Designing Autonomous Robotic Systems with MATLAB and Simulink€¦ · • Connect MATLAB and Simulink to ROS • Automatically generate C++ for ROS nodes Co-simulation with Gazebo](https://reader033.vdocuments.site/reader033/viewer/2022060607/605c973842c9c3191c072ef8/html5/thumbnails/19.jpg)
19
Underwater Vehicle Co-simulation with UWsim
![Page 20: Designing Autonomous Robotic Systems with MATLAB and Simulink€¦ · • Connect MATLAB and Simulink to ROS • Automatically generate C++ for ROS nodes Co-simulation with Gazebo](https://reader033.vdocuments.site/reader033/viewer/2022060607/605c973842c9c3191c072ef8/html5/thumbnails/20.jpg)
20
UAV Co-simulation with Gazebo
![Page 21: Designing Autonomous Robotic Systems with MATLAB and Simulink€¦ · • Connect MATLAB and Simulink to ROS • Automatically generate C++ for ROS nodes Co-simulation with Gazebo](https://reader033.vdocuments.site/reader033/viewer/2022060607/605c973842c9c3191c072ef8/html5/thumbnails/21.jpg)
21
Integrate Robotics Algorithms
MATLAB
Runtime
C, C++ HDL PLC
Embedded Hardware
C/C++ ++ExcelAdd-in Java
Hadoop/Spark
.NETMATLAB
ProductionServer
StandaloneApplication
Enterprise Systems
Python
![Page 22: Designing Autonomous Robotic Systems with MATLAB and Simulink€¦ · • Connect MATLAB and Simulink to ROS • Automatically generate C++ for ROS nodes Co-simulation with Gazebo](https://reader033.vdocuments.site/reader033/viewer/2022060607/605c973842c9c3191c072ef8/html5/thumbnails/22.jpg)
22
Apps: Ground Truth Labeler
Why?
1. Verifying Algorithms
2. Training Classifiers
![Page 23: Designing Autonomous Robotic Systems with MATLAB and Simulink€¦ · • Connect MATLAB and Simulink to ROS • Automatically generate C++ for ROS nodes Co-simulation with Gazebo](https://reader033.vdocuments.site/reader033/viewer/2022060607/605c973842c9c3191c072ef8/html5/thumbnails/23.jpg)
23
Perception with MATLAB
New App for
Ground Truth
Labeling
Label pixels
and regions for
semantic
segmentation
Caffe model
importer
LSTM (time series, text)
DAG Networks
Library of
pretrained
models
Multi-GPUs in
parallel
Optimized GPU
code
Training plots
NEW
PRODUCT:
GPU Coder-
Convert to
NVIDIA CUDA
code
Deploy / ShareTrain / PredictModelsData
“How do I label
my data?”
“How do I access
the latest models?”
“How do I make training
and prediction faster?”
“How do I deploy
my new model?”
![Page 24: Designing Autonomous Robotic Systems with MATLAB and Simulink€¦ · • Connect MATLAB and Simulink to ROS • Automatically generate C++ for ROS nodes Co-simulation with Gazebo](https://reader033.vdocuments.site/reader033/viewer/2022060607/605c973842c9c3191c072ef8/html5/thumbnails/24.jpg)
24
Key Takeaways
▪ 1. Productivity increased through an interactive environment to
prototype, develop, debug, and implement algorithms in robotics.
▪ 2. Model-Based Design for motion control systems allows early
verification of requirements, production code generation, and
continuous testing.
![Page 25: Designing Autonomous Robotic Systems with MATLAB and Simulink€¦ · • Connect MATLAB and Simulink to ROS • Automatically generate C++ for ROS nodes Co-simulation with Gazebo](https://reader033.vdocuments.site/reader033/viewer/2022060607/605c973842c9c3191c072ef8/html5/thumbnails/25.jpg)
25
Takeaways
▪ Workflows in robotics design and simulation, perception, planning, and controls.
▪ Meet us in San Jose during MATLAB EXPO (November 7th)
▪ ROS, ROS 2.0 and DDS support
▪ Image Processing and Computer Vision
▪ Machine Learning
▪ Deep Learning
▪ Path Planning
▪ SLAM
▪ Sensor Models and Sensor Fusion
▪ FDA Software Validation
▪ Ground truth labeling with LiDAR and Vision
▪ 3D Simulation with Physics
▪ Real-time support
▪ Code-generation for C/C++/CUDA/HDL/PLC
![Page 26: Designing Autonomous Robotic Systems with MATLAB and Simulink€¦ · • Connect MATLAB and Simulink to ROS • Automatically generate C++ for ROS nodes Co-simulation with Gazebo](https://reader033.vdocuments.site/reader033/viewer/2022060607/605c973842c9c3191c072ef8/html5/thumbnails/26.jpg)
26
% Thank you