Hardware in Loop Simulation
Hardware in Loop Simulation
Hardware-in-the-Loop Simulation
K.Sivanathan
Assistant Professor
Department of Mechatronics
SRM University
What is HIL Simulation?
UUT
Voltage
Desired Motor
Speed
Motor
Command Current
TCP Controller PWM
Impedance
Measured
ENCODER Speed Timing
Testing Embedded Control Systems
Virtual System Level Testing
Test System
Logging/
Test Profile Analysis
MODEL
UUT
Desired Motor
Speed Command
Motor
Controller
Measured Stimulus =
Speed
MODEL(test profile, UUT response)
Testing Embedded Control Systems
Virtual System Level Testing
Test System
Logging/
Test Profile Analysis
MODEL
UUT
Desired Motor
Speed Command
Motor
Controller
Measured Stimulus =
Speed
MODEL(test profile, UUT response)
You Need a Model…
Test System
Logging/
Test Profile Analysis
MODEL
UUT
Desired Motor
Speed Command
Motor
Controller
Measured Stimulus =
Speed
MODEL(test profile, UUT response)
What is HIL?
• HIL simulation is a most powerful test method used to test embedded
control systems more efficiently.
• When testing embedded control systems, safety, availability, or cost
considerations can make it impractical to perform all of the necessary
testing using the complete system.
• You can use HIL simulation to simulate the parts of the system that pose
these challenges, which gives you the power to thoroughly test the
embedded control device in a virtual environment before proceeding to real
world tests of the complete system.
Why Testing Embedded Control Systems using HIL?
System Level Testing
Operator Real-time
I/O ECU
Interface Processor
I/O
Operator Real-time
ECU
Interface Processor Fault
Insertion
Ethernet Analog, Digital, Bus interfaces
Hardware fault insertion to test the behavior of the ECU during signal faults
Testing Multi-ECU Systems
ECU
Operator Real-time
I/O ECU
Interface Processor
Ethernet
ECU
Ethernet
I/O ECU
Real-time
Processor Sync
When using multiple chassis for additional processing power, it is often necessary
to provide timing and data synchronization interfaces between them.
Simplified Wiring – Distributed I/O
• This approach greatly reduces HIL test system wiring cost and
complexity by making it possible for the connections between the
ECU and the I/O interfaces to be made locally (spanning less than a
meter) while a single bus cable is used to span the additional
distance to the real-time processing chassis.
• Additionally, with the modular nature of this approach, HIL test
systems can easily scale, incrementally, from a multi-ECU test
system in which all but one of the ECUs are simulated to a complete
systems integration HIL test system where none of the ECUs are
simulated.
Simplified Wiring – Distributed I/O contd.
Deterministic Bus
I/O ECU
Operator Real-time
I/O ECU
Interface Processor
Ethernet
I/O ECU
Deterministic distributed I/O interfaces greatly reduce HIL test system wiring cost and
complexity because the connections between the ECU and the I/O interfaces can be made
locally.