Model-in-the-Loop (MiL) Validation for Vehicle Control Software

Accelerating Software Validation Through Closed-Loop Virtual Testing

Modern vehicle control software demands extensive validation long before prototype vehicles become available. Our Model-in-the-Loop (MiL) validation framework enables engineering teams to verify control algorithms in a realistic virtual environment, reducing development risk, shortening validation cycles, and improving software quality from the earliest stages of development. 

Challenge

A customer was developing a new generation of vehicle control software from the ground up. Since no production hardware or prototype vehicles were available during the initial development phases, traditional validation approaches would have delayed software verification until late in the program.

 

The key challenges included:

  • Developing control software without physical prototypes
  • Validating software behaviour under thousands of driving scenarios
  • Detecting functional issues early in development
  • Ensuring controller robustness across varying vehicle and road conditions
  • Establishing an automated software validation process that could scale throughout development

The customer required a virtual validation environment capable of supporting continuous software verification before Hardware-in-the-Loop (HiL) and vehicle testing.

Solution

We developed a comprehensive Model-in-the-Loop (MiL) validation framework based on closed-loop simulation.

The virtual environment consisted of three tightly integrated components:

  • Vehicle Control Software
    • MATLAB/Simulink-based controller development
    • Modular software architecture
    • Requirement-based implementation
  • Virtual Driver
    • Automated driver model
    • Steering, throttle, and braking control
    • Repeatable driving maneuvers
    • Scenario execution without manual intervention
  • High-Fidelity Multibody Vehicle Plant Model
    • Detailed multibody vehicle dynamics
    • Suspension and steering kinematics
    • Tire dynamics
    • Powertrain representation
    • Vehicle sensors
    • Environmental interactions

Together, these models formed a complete closed-loop simulation, allowing the controller to interact with a realistic virtual vehicle exactly as it would in the real world.

Closed-Loop Simulation Architecture

This architecture enabled realistic software verification under repeatable and fully automated conditions.

Development Approach

The MIL environment was established alongside the software development process rather than after controller implementation.

Phase 1 – Framework Development

  • Software architecture definition
  • Controller interfaces
  • Plant model integration
  • Driver model integration
  • Signal management

Phase 2 – Controller Development

  • Feature implementation
  • Algorithm development
  • Requirement traceability
  • Unit-level verification

Phase 3 – Closed-Loop Validation

Automated validation of:

  • Lane keeping
  • Path following
  • Vehicle stability
  • Cornering behaviour
  • Speed control
  • Emergency manoeuvres
  • Low- and high-speed driving

Phase 4 – Virtual Sign-Off

Comprehensive regression testing was executed before software releases, ensuring that every software version met functional performance targets.

Virtual Sign-Off Strategy

A key objective was to establish a Virtual Sign-Off (VSO) process.

Instead of relying solely on physical vehicle tests, every software release underwent automated validation against an extensive library of simulation scenarios.

The virtual sign-off process included:

  • Functional verification
  • Performance validation
  • Requirement compliance
  • Regression testing
  • Controller robustness assessment
  • Corner case evaluation

This enabled engineering teams to identify software issues months before vehicle prototypes became available.

Automation

The validation environment supported fully automated execution of simulation campaigns.

Capabilities included:

  • Batch execution
  • Regression testing
  • Automatic result evaluation
  • KPI generation
  • Pass/Fail assessment
  • Test report generation
  • Continuous software validation

Automation significantly reduced manual effort while improving repeatability and test coverage.

Benefits

The Model-in-the-Loop framework delivered significant advantages throughout the software development lifecycle:

Early Software Validation

Controllers were validated from the first software iteration without requiring physical hardware.

Reduced Development Risk

Software defects were identified and corrected early, reducing downstream integration issues.

Faster Development Cycles

Continuous validation allowed rapid iteration and quicker software releases.

High Test Coverage

Thousands of scenarios could be executed automatically, far exceeding the scope of physical testing.

Repeatable Testing

Identical test conditions ensured objective comparison between software versions.

Foundation for Future Validation

The MiL environment established a seamless transition toward Software-in-the-Loop (SiL), Hardware-in-the-Loop (HiL), and vehicle testing.

Technologies

The solution leveraged industry-standard model-based development and simulation tools, including:

  • MATLAB & Simulink
  • Simulink Test
  • Stateflow
  • Automated test frameworks
  • High-fidelity multibody vehicle dynamics models
  • Requirement-based software development
  • Continuous integration workflows
  • Virtual validation pipelines

Project Outcomes

The Model-in-the-Loop validation framework became the foundation of the customer's software verification process.

Key outcomes included:

  • End-to-end closed-loop virtual validation environment
  • Vehicle control software developed and validated from scratch
  • Early functional verification before hardware availability
  • Automated virtual sign-off process for every software release
  • Significant reduction in physical testing effort
  • Improved software quality through continuous regression testing
  • Faster and more confident software releases

Conclusion

By integrating Vehicle Control Software, a Virtual Driver, and a High-Fidelity Multibody Vehicle Dynamics Plant Model into a closed-loop Model-in-the-Loop environment, we enabled continuous software validation from day one of development.

The framework provided a scalable virtual validation process that supported early defect detection, comprehensive regression testing, and automated virtual sign-off, ultimately reducing development time, lowering validation costs, and improving confidence before progressing to Hardware-in-the-Loop and real-world vehicle testing.

Information icon

We need your consent to load the translations

We use a third-party service to translate the website content that may collect data about your activity. Please review the details in the privacy policy and accept the service to view the translations.