Scaling up Model-Based Design: Moving from First Success to Optimized Deployment 提升基于模型的设计 : 从第一次成功到优化部署 Paul Barnard Director, Design Automation MathWorks paul.barnard@mathworks.com 2016 The MathWorks, Inc. 1
When I step into a new car these days, I don t smell leather anymore, I smell software 这些天当我走进一辆新车的时候, 我不再闻到真皮座椅的味道, 而是闻到了软件的气息 MATLAB Automotive Conference, Stuttgart, 2015 2
John Lauckner, CTO at General Motors 3
Recalls in the automotive industry 汽车行业的召回 Increasing news of recalls 不断增加的召回新闻 Often due to ECU software bug 原因通常是 ECU 的软件缺陷 SW complexity worsens situation 软件复杂程度使形势更加严峻 Expensive, damaging to OEMs 给整车厂商带来昂贵的破坏性后果 4
Recalls in the automotive industry 汽车行业的召回 SOFTWARE NOW TO BLAME FOR 15 PERCENT OF CAR RECALLS YOU CAN'T JUST HOLD THE HOME AND LOCK BUTTONS TO SOLVE THIS ONE Bengt Halvorson / The Car Connection Posted June 2, 2016 5
Altran study: Study participants reported that quality improvement was a strong reason to move to Model-Based Design Altran 研究表明 : 质量改进是转向采用基于模型设计的重要原因 MathWorks Automotive Virtual Conference, June 2013 Dr. Jens Zimmermann, Altran 6
MAB 1998 3 Organizations 1998 年,MathWorks 咨询委员会 (MAB) 起始于三个组织 Alex Ohata Toyota Armin Muller Daimler-Benz Ken Butts Ford First MAB Germany 1998 MAB 2015 Boston: 107 Organizations Europe, China, Japan, Korea, India 2005 年,MathWorks 咨询委员会 (MAB) 波士顿 : 拥有 107 个组织参加另外还有欧洲 / 中国 / 日本 / 韩国 / 印度等等 7
Model-Based Design Adoption 采用基于模型的设计 Partnership Accelerates Innovation Research Prototype Production Process improvements MAB 1970 1980 1990 2000 2010 2020 Tool improvements 8
Automatic Code Generation has been an Important Motivation for Deploying Model-Based Design 自动代码生成已经成为采用基于模型设计的重要驱动力 Daimler: Vehicle Controller Delphi: Radar Module Caterpillar: Machine Control GM: Hybrid Powertrain Continental: Active Suspension Delphi: Common Rail Diesel Toyota: Hybrid Control Unit Lear: Body Control Module Cummins: Diesel EMS CNH: Combine Control Unit GM: HVAC Module Vodafone: Telematics 9 9
MATLAB and Simulink Help Engineers Put ADAS and Autonomous Driving on the Road MATLAB 和 Simulink 帮助工程师将 ADAS 与自主驾驶在真实路面上得以实现 10
Model-Based Design and Code Generation for AEB Sensor Fusion 11
Surveys from 3 continents, 176 companies representing 30,000+ users 以下调查来自于 : 三个大陆,176 家公司, 代表了 30000 多名用户 3% 1% 1% 1% Automotive 4% Aerospace and Defense 7% Industrial Automation 8% 37% Rail, Ships, and Other Transportation Electronics and Semiconductors Medical Devices 18% Energy Production Communications Source: 2015 MathWorks Model-Based Design Survey 20% Other Metals, Materials and Mining 12
Perceived Current Benefit Versus Traditional Methods 与传统方法相比, 可以看出当前 MBD 的优势 MBD Component Benefit Desktop simulation 4.17 Graphical authoring of algorithms 4.14 Real-Time Prototyping 4.05 Production code deployment 4.04 Plant modeling 4.04 On target prototyping 3.93 Hardware-in-the-Loop 3.91 Model verification 3.72 Textual authoring of algorithms 3.66 Code verification 3.62 5 = very high 4 = high 3 = medium 2 = low 1 = very low 13
Perceived Current Benefit Versus Traditional Methods 与传统方法相比, 可以看出当前 MBD 的优势 MBD Component Benefit Desktop simulation 4.17 Graphical authoring of algorithms 4.14 Real-Time Prototyping 4.05 Production code deployment 4.04 Plant modeling 4.04 On target prototyping 3.93 Hardware-in-the-Loop 3.91 Model verification 3.72 Textual authoring of algorithms 3.66 Code verification 3.62 趋势表明 : 如果你刚接触 MBD, 可以考虑从以下方面作为开展 MBD 的突破口 1. 桌面仿真 2. 可执行的需求描述 3. 快速原型与产品代码生成 14
Cummins in 2007 康明斯,2007 年 采用代码生成 : 功能设计与快速原型目标码生成在真实硬件中进行测试 MathWorks Automotive Conference Dearborn, MI June 2007 15
Difference between perceived current benefit and future benefit 当前获得的优势与未来可获得优势的区别 Delta in MBD Component benefit* Code verification 0.40 Plant modeling 0.39 Model verification 0.38 Hardware-in-the-Loop 0.34 Desktop simulation 0.32 Production code deployment 0.31 Textual authoring of algorithms 0.30 Graphical authoring of algorithms 0.29 On target prototyping 0.28 Real-Time Prototyping 0.26 调查结果建议如果你正在应 用 MBD, 接下来请考虑关注 以下两方面 : 1. 验证与确认 2. 被控对象物理建模 16
Model-Based Design Maturity Auto Industry Maturity: 汽车行业基于模型设计的成熟度 : Top 20%, Average, Bottom 20% Modeling 100 80 Enterprise Management 60 40 Simulation and Analysis 20 0 Process, Tools and Infrastructure Implementation Verification and Validation 17
Model-Based Design Auto Industry Leaders: Trends and Focus Areas 汽车行业基于模型设计的领导者 : 趋势与关注领域 Enterprise-level Model-Based Design strategy Strategic measures and indicators Training and knowledge management Supplier collaboration and management Enterprise Management Modeling 100 80 60 40 20 0 Scalable architecture Plant modeling Modeling for reuse Simulation and Analysis System-level simulation and optimization Virtual calibration capability Multi-core Hardware software co-design Process, Tools and Infrastructure Process definition and improvement Continuous upgrade strategy Improved metrics and estimation methods Regression testing framework Verification and Validation Implementation AUTOSAR HDL code Further reduction of manual tasks Low Medium High Requirements traceability Automated test generation and execution Regulations and standards compliance 18
Cummins: Model-Based Design Deployment History 康明斯 : 基于模型设计的部署历史 基于模型设计为软件工程师带来的益处 Model Based Controls: Moving Beyond Software Domain, Ed Hodzen, Director, Advanced Engineering, Cummins, Inc., MathWorks Automotive Conference, May 2015, Plymouth, Michigan, USA 19
Cummins: Moving Beyond Software Domain 康明斯 : 超越软件范畴加速系统开发 Model Based Controls: Moving Beyond Software Domain, Ed Hodzen, Director, Advanced Engineering, Cummins, Inc., MathWorks Automotive Conference, May 2015, Plymouth, Michigan, USA 20
Applying MBD is a Step-by-Step Process 采用基于模型设计是一个循序渐进的过程 Virtual Verification & Validation System Validation Fully Leveraged Model-Based Design System Level Simulation Hardware- In-Loop Test Simulation based Development Graphical Specs Rapid Prototyping Production Code Gen Simulation Real-Time Testing Production 21
What Capabilities Can I Leverage? 1. System modeling 系统建模 2. Verification and Validation 验证与确认 22
What Capabilities Can I Leverage? 1. System modeling 系统建模 2. Verification and Validation 验证与确认 23
Full system 完整系统 PHYSICAL SYSTEM SOFTWARE COMPOSITION Component A Component C Component B 24
System model 系统模型 25
Multi-Tool Simulation Integration 多工具仿真集成 Track, Tires, Track, DriverTires, [Tool Driver A] [Tool A] 1.0 Control Control [Simulink] [Simulink] R2015a Electronics Electronics [Simscape] [Simscape] R2014b Drive-train [Tool Drivetrain B] [Tool B] 2.0 Suspension [Tool Suspension C] [Tool C] 3.0 Thermal [Tool Thermal D] [Tool D] 2.3 S-function S-function FMI S-function Simulink as your Simulation Integration Platform 26
Simulation Integration Platform Characteristics 仿真集成平台的特征 Authoring environment for component Models 不同组件模型的构建环境 Mature and extensive API for 3 rd party component integration 成熟与广泛的第三方组件集成接口 Multidomain simulation environment 多域仿真环境 Scalable environment 可扩展的环境 Analysis and Debug capabilities 分析与调试能力 27
Simulation Integration Platform Characteristics 仿真集成平台的特征组件模型的构建环境 Authoring environment for component Models 不同组件模型的构建环境 Mature and extensive API for 3 rd party component integration 成熟与广泛的第三方组件集成接口 Multidomain simulation environment 多域仿真环境 Scalable environment 可扩展的环境 Analysis and Debug capabilities 分析与调试能力 28
Simulation Integration Platform Characteristics 仿真集成平台的特征组件模型的构建环境 29
Depth of solution Physical modeling 物理建模 Simscape Breadth of platform Power systems Electronics Multibody Fluids Driveline.. 30
Simscape Runtime Parameters ( Simscape 运行时参数 ) During HIL tests Vehicle Mass: Shaft Compliance: Final Drive Ratio: In protected models During iterative simulation workflows For power systems and other modeling domains 31
Simulation Integration Platform Characteristics 仿真集成平台的特征分析与调试能力 Authoring environment for component Models 不同组件模型的构建环境 Mature and extensive API for 3 rd party component integration 成熟与广泛的第三方组件集成接口 Multidomain simulation environment 多域仿真环境 Scalable environment 可扩展的环境 Analysis and Debug capabilities 分析与调试能力 32
Simulation Integration Platform Characteristics 仿真集成平台的特征分析与调试能力 仿真集成平台必须具备以下能力 : 分析仿真结果 仿真过程中选择并监测信号 比较仿真值 诊断未预计到的行为 向前和后退调试 设置时间和条件断点 提供诊断信息 33
What Capabilities Can I Leverage? 1. System modeling 系统建模 2. Verification and Validate 验证与确认 34
Verification and validation 验证与确认 : Automate testing and find design errors 自动化测试并发现设计缺陷 Polyspace Simulink Design Verifier Simulink Test HDL Verifier Simulink Code Inspector Simulink Verification & Validation 35
Simulink Test New Features in R2016a Simulink Test 在 2016a 版本中的新功能 Test Harnesses Test Sequence Block Test Manager Harness list dialog Library harnesses Simulink functions/export function models support (AutoSAR) Externally-saved harnesses Requirements linking Syntax highlighting Tab completion Enhanced symbol sidebar Message I/O, function call Description column "verify" statement API Requirements linking Coverage Parallel test execution Report customization Iterations Dependency/impact analysis Test for subsystems Real-time test cases (SLRT) 36
Simulink Test R2016a: Author and execute real-time tests 构建并执行实时测试 Run tests/assessments on Simulink Real-Time target Start simulation tests from model, application, connect to running target Test sequence assessments to verify behavior without stopping the test Bring back real-time test data for analysis in the test manager 37
Verification 验证 Fast and Small Iterations 快速与微小迭代 Certification Requirements tracing Simulation Property proving Test management Code inspection Test generation HIL Standards checks Code verification SIL PIL 38
Summary 总结 Model-Based Design is in widespread use for new product development 基于模型设计在新产品开发中得到广泛应用 Automatic code generation provides significant benefit 自动代码生成带来了显著优势 Often the first technology to adopt by automotive companies Widespread usage including high performance and safety critical applications Beyond code generation 自动代码生成以外 Model verification and closed loop simulation are key to front loading System modeling extends the scope and benefit of Model-Based Design MathWorks focus is to evolve the tooling for Model-Based Design 迈斯沃克公司专注于基于模式设计相关工具的设计与发展 39