Replay and HIL AD Reference Architecture Theory of Operation

The Replay and HIL AD Reference Architecture provides a unified test system architecture to switch between data replay and HIL test, as well as a shared toolchain with the NI Data Record System AD.

The DUT

ADAS functionality may be implemented in one or more ECUs, collectively referred to as the device under test (DUT).

The DUT commonly includes direct and indirect connections to a variety of environmental sensors such as camera, radar, and lidar. The DUT also includes connections to other ECUs in the vehicle to monitor and control related functions such as vehicle speed and driver inputs. The DUT may use a wide variety of communication busses—such as CAN, Automotive Ethernet, GMSL, FlexRay, or LIN—for these connections. The Replay and HIL AD Reference Architecture enables you to create a test system that can emulate the behavior of these sensors and ECUs to validate the DUT in a virtual environment.

ADAS Replay

ADAS Replay allows you to read pre-recorded or pre-generated data from files and play that data back to the DUT. This functionality is distinct from what is often termed playback, which refers to viewing pre-recorded or pre-generated data. Replay is commonly used to validate software performance, interaction with I/O interfaces, algorithms compiled and deployed to the physical hardware, and more.

A Replay system has limited dynamic capabilities since it is operating from pre-recorded or pre-generated data. The data being played back cannot change based on the commands from the DUT. For example, if the DUT commands that the vehicle should turn, the camera data continues to show the path that the vehicle followed in the original recording. Pre-recorded data comes from an ADAS datalogging system, such as the Data Record System AD, while pre-generated data is synthesized from a computer model of the vehicle under test and the world around it.

The stored data corresponds to the sensors and busses connected to the DUT, such as images from cameras and object lists from radars. DUT validation often requires more than simple playback of data files. The DUT may require you to perform a startup sequence before it is ready to accept sensor data, or it may require periodic messaging or signaling to remain operational. The Replay system can perform this restbus simulation as part of its playback capabilities.

ADAS HIL

ADAS HIL allows you to test the DUT in a virtual world using hardware-in-the-loop (HIL) technology. This virtual world, which can be generated in a variety of ways, provides realistic driving scenarios by modeling the vehicle under test, roads, street signs, guard rails, other traffic, and so on. In contrast to Replay, the HIL system can respond dynamically to commands from the DUT and update the data from the emulated sensors in real time. For example, if the DUT commands that the vehicle should turn, the virtual world simulation takes into account the new vehicle orientation in relation to the other objects in the scene, and returns data according to the new field of view.

The primary use case of a HIL system is to stream data from a simulated environment and send it to a vehicle ECU with accurate timing so that the ECU performs as if it is in a real, operating vehicle. This requires simulation software with high fidelity sensor models and world environments, running on an environment server that can keep up with the timing demands of the workflow. Depending on the timing requirements, the simulation task can be distributed over multiple servers to ensure that proper system bandwidth is available for the number of sensors in the simulation to render in time.

Replay and HIL AD Reference Architecture Characteristics

The Replay and HIL AD Reference Architecture software components are built on a high-performance data movement and synchronization engine, which is a plug-in architecture designed to run on NI Linux RT targets. These software components include the RT application and additional tooling for creating plug-ins, monitoring performance, visualizing data, configuring the tester, and so on. The Replay and HIL AD Reference Architecture also includes several examples, including a representative ADAS Adaptive Cruise Control (ACC) example.

The data engine supports both Replay and HIL capabilities, which can be used together in the same application. The primary difference between Replay and HIL is the source of the data. In a Replay system, data is stored in files and passed to the emulators, whereas in a HIL system, data is dynamically generated by a simulator that passes data to the emulators and receives data generated by data ingest plug-ins.

Figure 1. Relationship Between Record, Replay, and HIL

1378

Replay and HIL AD Test System Overview

The following information represents a typical test system designed based on the Replay and HIL AD Reference Architecture.

Figure 2. Example Test System

1378

One or more environmental servers are the primary source for the sensor data that represents the environment around the vehicle. This data can be read from files (through Replay) as well as dynamically generated in response to ECU interactions (through HIL). The environmental server communicates with the system controller using an RDMA Ethernet connection for high bandwidth sensor data and standard networking for other communication. The real-time controller acts as a bridge between the environmental server and one or more ADAS ECUs. It is responsible for accurately emulating sensor and bus interfaces, including data formatting, transmission timing, and communication protocols. The ADAS ECU(s) that the controller communicates with are the DUT(s) of the system. These DUTs perform perception, planning, and control functions, and they can connect to sensors and other ECUs through several different types of automotive interfaces.

The standard network connections provide application control, run-time commands, and low-bandwidth sensor data transfer, which you can use for applications such as radar and ultrasonic. RDMA Ethernet connections provide high-bandwidth sensor data transfer, which you can use for applications such as cameras and imaging radar.

Third party simulators can interface with the NI platform through the standard software development kit. Refer to the Replay and HIL AD GitHub Repository for examples of simulation support, software installation instructions, and other information about Replay and HIL AD software. Contact your NI Services representative if you require additional information or if you need to gain access to the GitHub repository.