Abstract

With the advent of autonomous vehicles, in particular its adaptability to harsh conditions, the research and development of autonomous vehicles attract significant attention by not only academia but also practitioners. Due to the high risk, high cost, and difficulty to test autonomous vehicles under harsh conditions, the hardware-in-the-loop (HIL) scaled platform has been proposed as it is a safe, inexpensive, and effective test method. This platform system consists of scaled autonomous vehicle, scaled roadway, monitoring center, transmission device, positioning device, and computers. This paper uses a case of the development process of tracking control for high-speed U-turn to build the tracking control function. Further, a simplified vehicle dynamics model and a trajectory tracking algorithm have been considered to build the simulation test. The experiment results demonstrate the effectiveness of the HIL scaled platform.

1. Introduction

Autonomous vehicles, also known as self-driving vehicles or driverless vehicles, are capable of sensing the traffic environment, navigating through software algorithm, and controlling vehicle movement without driver’s decisions and actions. Such vehicles have been widely used in logistics and cargo transportation, military purpose, and planetary exploration due to its great potential ability to improve safety, increase transportation capacity and minimize pollution [18]. In the past 40 years, the development of autonomous vehicles has been greatly increased. Recently, Google, Tesla, Uber, and Baidu had demonstrated their autonomous cars, which can run on various roads company with live traffic [9]. Therefore, with the resolution of technological, societal and legal issues, people will finally free themselves from the mental and physical burden of driving [4].

Although autonomous vehicles have many advantages, recent several accidents slow down their process of commercialization. Tesla cancelled the propaganda of self-driving function, and Uber also terminated all autonomous vehicle testing. In reality, both government and academia have reached an agreement that the autonomous vehicle needs to conduct comprehensive, systematic, and rigorous tests before it is officially commercialized. However, the testing of autonomous vehicle requires extremely time-consuming work and huge economic cost [10]. An autonomous vehicle consists of five functions (as shown in Figure 1): sensing and location systems; global route planning; behavior reasoning; trajectory planning; trajectory tracking control. Among these five functions, the first four can be simulated and tested by using the data collected from the autonomous vehicle sensors. Basically, it is a test of the software function of the autonomous vehicles. However, the trajectory tracking control process needs to be tested with real vehicles as the vehicle kinematic and dynamic constraints; controller responsiveness will influence the reliability, smooth, and comfort of autonomous vehicles. For the trajectory tracking control function, it requires that the control algorithm can provide the spatial path planning and handle the direction/speed of the vehicle according to the real-time surrounding traffic information and high-accuracy map information [10].

The main two existing testing approaches of autonomous vehicle trajectory tracking are simulation testing and real vehicles testing. Although the software-based simulation has the advantages of low cost and high efficiency, the simulation model is based on the ideal mathematical model which ignores many practical factors might cause large difference between the simulation results and real cases results. It should be noted that the real world testing, although with much higher accuracy, is very time-consuming, expensive, and limited by weather and scenarios [1113]. In this regard, shortening the development cycle without sacrificing accuracy and reliability has been concerned [14]. There are many well-known testbeds around the world for testing connected and automated vehicles, such as the MCity of the University of Michigan and the GoMento test site located in Contra Costa County, California, and CU_CVIS testbed of Chang’an University in China. The former two testbeds focus on demonstration for applications of future Intelligent Transportation Systems. CU_CVIS focuses on the metafunction testing for each part of CAVs and the comprehensive performance testing under the limit conditions [15].

Hardware-in-the-loop (HIL) simulation has combined both mathematical and mechanical models to emulate real vehicles as considering the influence of gravity, resistance, and friction which may cause the inaccuracy of the model. Compared to the testing in real traffic system, the HIL has the merit of low construction cost, short development cycle, and reproducible method [16]. At present, HIL-based simulation has been widely used in the field of automotive testing. Deng et al. [17] proposed a HIL simulation system as an integral part of various autonomous driving programs, which is a laboratory environment to support the development, test and verification of many functions, and algorithms related to sensor-guided autonomous driving. Zulkefli et al. [18] proposed a HIL testbed to evaluate the performance of connected vehicle applications. This testbed integrated a laboratory powertrain research platform with a microscopic traffic simulator (VISSIM), which could be used to test various ITS applications such as CACC, Eco-Driving, and Speed Harmonization. Gietelink et al. [19] developed an indoor vehicle hardware-in-the-loop simulation system to test the advanced driver assistance systems embedded in a real vehicle. To best of our knowledge, most of HIL-based simulations embed a vehicle or vehicle parts into the system, which are usually complex and costly, and require large space. A research group from RWTH Aachen University, Germany, proposed a hardware implementation of a platoon of four 1 : 14 scaled trucks to test the cooperative platoon control algorithm [20]. As considering critical safety factors, HIL simulation system is also used to precrash threat assessment [21].

In the proposed paper, a HIL scaled platform for testing autonomous vehicle trajectory tracking (PaTAVTT) is presented, which is a mechatronic testbed consists of scaled roadway, scaled vehicles, indoor positioning subsystem, and computer-aided Graphical User Interfaces. Compared with other HIL test systems, PaTAVTT has the following advantages. First, it is equipped with an indoor ultra-wideband- (UWB-) based high-precision positioning system matches the GPS precision in outdoor field, which can record the accurate trajectory of the scaled vehicle in motion. The deviation between the real trajectory and the reference would be an important criterion to evaluate the performance of the trajectory tracking algorithm. Second, the scaled platform bridges the software-based vehicle dynamics model with the real vehicle. The algorithm modules and parameters validated by Matlab or Carsim can be downloaded into the scale vehicle. After passing the tests on PaTAVTT, the algorithms can be further transplanted into the real vehicle. Third, many external factors such as the road surface material, road geometry and slope, and static or dynamic obstacles can be tested due to the low establishment and testing costs.

In this paper, the system structure of this HIL platform and the implementation of each submodule have been described. Further, a new methodology of U-turn has been developed and tested which can also be used in an autonomous vehicle. The testing results demonstrate that the HIL platform can be used to test the trajectory planning and tracking control of an autonomous vehicle, which potentially shorten its development cycle. The remainder of this article is organized as follows. Section 2 is the overview of the PaTAVTT. Section 3 presents a real-case study and the methodology of U-turn. The simulation results are presented in Section 4. Section 5 concludes the paper.

2. Overview of PaTAVTT

In this paper, PaTAVTT consists of scaled roadway, positioning system, scaled vehicle, transmission system, and software simulator. As can be seen in Figure 2, the scaled roadway is a rounded rectangle platform which has two lanes, and the width of each lane is 37.5 cm. Additionally, the scaled roadways has different kinds of road infrastructures, such as traffic signs and LED information board.

The scaled vehicles are 37 cm in length, 30 cm in width, and 14 cm in height. The scaled vehicle is battery powered and the highest speed is 3 m/s. The positioning system is produced by Ubsense based on UWB wireless communication technology, which consists of a positioning antenna mounted on the wall and a label on the vehicle. Its positioning accuracy is about 30 cm which is approximately equal to the length of the scale vehicle. At this point, it matches the positioning precision of GPS, which has a precision of 3–5 m and is close to the length of a real vehicle. Each scaled vehicle is equipped with dual controllers and dual Central Processing Units (CPUs): one CPU is used to control the vehicle steering; the other is used to handle the output data from four kinds of sensors (UWB positioning sensor, ultrasonic distance sensor, camera/image sensor, and photoelectric encoder; see Figure 3). Ultrasonic distance sensors are used to detect the location of the front vehicle or obstacles to prevent collisions. The image sensor is used to detect the lane line to ensure that the vehicle is traveling within the lane. The photoelectric encoder is used to measure the speed and displacement of the vehicle.

The wireless communication system is realized by using 802.11ac wireless Wi-Fi technology. Wi-Fi modules are installed to smart vehicles. All wireless communication is connected to a network router using Intranet. It should be noted that the system is able to simulate the trajectory control/optimization strategies.

PaTAVTT platform can be used to test various types of autonomous vehicle tracking control functions, such as single-vehicle control and platoon control. Please refer to Table 1 for details.

3. A Case Study of U-Turn

3.1. U-Turn and Its Negative Effects to Traffic Dynamics

U-turn is a common traffic scenario which lowers vehicle speeds and affects the traffic flow. The U-turn signs from different countries are shown in Figure 4. It may cause sideslip or rollover accident if the vehicle accelerates in a U-turn maneuver [22]. As autonomous vehicles are able to automatically plan and control the trajectories, a proper U-turn algorithm can significantly improve the overall traffic efficiency, reduce fuel consumption, and minimize other negative effects.

Based on the PaTAVTT platform, this paper uses U-turn trajectory tracking as a case study and builds an autonomous vehicle dynamics model. We use Model Prediction Control (MPC) algorithm to perform and test the autonomous vehicles trajectory tracking control in U-turn scenario under different speed conditions.

3.2. Vehicle Dynamics Model

The trajectory tracking control of autonomous vehicles is achieved by controlling the vehicle function system. Mathematical vehicle dynamics model is useful in vehicle design, crash simulation, and kinematic behavior analysis as it provides a quick simulation analysis compared with finite element (FE) models [23]. In this regard, in this paper, we use vehicle dynamics model to be the prediction model and the autonomous vehicle dynamics model can be simplified as two-wheeled bike model.

In the plane Cartesian coordinate system (), the vehicle dynamics model has been shown in Figure 5. and are the center coordinates of the vehicle rear axle and front axle, respectively. and are velocity of the vehicle rear axle and front axle, respectively. is the driving direction of the vehicle, is the angle of front wheel, and is the wheelbase between the front and rear axle.

From Figure 5, we havewhere and are the lateral velocity and the longitudinal velocity of rear axle, respectively.

By combining (1) and (4), the model is simplified asThe general expression of (5) iswhere the state variable and the control input .

Trajectory tracking control is implemented by tracking reference vehicle. Therefore, assuming that the reference vehicle follows the given path, the reference vehicle will satisfy the above equation at any time. Using 0 to notate the reference vehicle,By using Taylor series and ignoring the higher-order function, (7) can be approximated by (8) as follows:By substituting (8) with (7), we have

The model predictive control (MPC) used in this paper is a discrete time control method. Let , where is the sampling period.

Therefore, we can discretize the continuous dynamics function and (10) is the discrete time model, which will be used as the predictive model in this research. where and are represented by

3.3. The Trajectory Tracking Control Algorithm of U-Turn Based on MPC

MPC predicts the future state or output of the system via the established prediction model, which solves the optimal control sequence based on the constraints and performance of vehicle dynamics. It can calculate the following optimal control sequence by predicting the future state or output of the control object under previous optimal control sequence. After alternating this cycle, the object can be controlled by the system. MPC is effortless to be modelled and controlled, and it also has good robustness. Then, it can be used to solve multivariable and constrained problems and implement online optimization [24].

As shown in Figure 6, the control strategy for MPC-based U-turn trajectory tracking is as follows: it starts from the th sampling period, generating a set of control increments by optimization to ensure the predicted trajectory highly fits the reference trajectory in the predictive time domain . It also limits the minimum amount changes of controlling output. is the number of sampling points of control inputs, and is the number of predictive points of the system state outputs, which usually commits .

3.4. Objective Function Design

As the objective function needs to ensure autonomous vehicle track the reference trajectory quickly and smoothly, the deviation of system state variables and the optimization of control variables should be considered. Then, the following objective function will be used to design the trajectory tracking controller,where and are weight matrixes. The first item reflects the performance of trajectory tracking; the second item reflects the constraints on changes. This function can be easily converted into a standard quadratic programming form [25]. Therefore, considering the vectors(12) can be represented bywith .

In order to simplify the solving to (12), assuming , we have where

From (15)~(16), the objective function can be converted into a standard quadratic form:where can be ignored as it is independent of and can not affect the determination of .

Thus, we can redefine the function as

This above function is expressed in standard form which can be solved by online QP problems solver such as Matlab. The amplitude constraints in the control variables of (19) can be represented asAfter solving (19), the control inputs sequence can be derived asThe first element in is applied to the system to get an actual control increment, which isAfter entering the next control cycle, we repeat the above cycle processes to achieve the whole tracking control system.

4. Simulation and Testing on PaTAVTT

According to the road design standards, as considering the vehicle sideslip, the formula to calculate the road safety speed with large transverse gradients iswhere is the tire-road adhesion coefficient; is the transverse gradient of road; is the radius of curvature; is the gravitational acceleration [26].

When the vehicle is driving on the road with large tire-road adhesion coefficient under high-speed condition, the vehicle will have an overturning moment which is caused by centrifugal force and lateral adhesion. The overturning moment may result in the gravity of the vehicle to shift to the outside tire (i.e., the phenomenon of lateral-load transfer). Once the overturning moment is increased to the extent that makes the inside tire leaves off the road, the untripped rollover will occur. The critical rollover speed of the vehicle on the load with large tire-road adhesion coefficient, , iswhere is the wheel-track and is the center of gravity height [27].

The main factor of vehicle rollover is the center of gravity height, , and if the center of gravity height is lower enough, the rollover will not occur. In this paper, the research object is small vehicles, which usually have relatively low center of gravity height. Therefore, the road safety speed, , is greater than .

In this case study, the following parameters are used: , , , , and . The simulation trajectory tracking results based on MPC under different vehicle speed conditions are shown in Figure 7. The speed varied from 8.4 m/s to 3.6 m/s with a negative step of −0.3. From the figure, we see that when the vehicle speed decreases, the vehicle movement trajectory gets closer to the reference trajectory.

The snapshots of lab tests are presented in Figure 8. Using the simulation results, we deploy 5 scaled vehicles to conduct the trajectory tracking experiment, and we set the desired speed of the vehicles the one tenth of the simulation reference speed ( m/s). The testing results on PaTAVTT platform are shown in Figure 9. As can be seen in the figure, the trajectories are pretty close which demonstrates the effectiveness of the proposed testing platform.

Furthermore, we calculated the parameters of the trajectories of 5 homogenous vehicles as shown in Table 2. The trajectory overlap ratio (TOR) is defined as follows:where is the number of the total trajectory points at a sampling period of 0.04 s and is the number of the trajectory points located in the reference trajectory buffer, which is a stripe with a width equal to the scaled vehicle and takes the reference trajectory as its mean axle. From the table, it can be concluded that the proposed U-turn algorithm does well in repeatability, robustness, and trajectory tracking.

We further apply the proposed algorithm to real world testing environments (see Figure 10) and conduct the same U-turn trajectory experiment for 10 times. Experimental results (see Figure 11) show that the algorithm can generate very consistent results. This further demonstrates the effectiveness of the proposed methodology and the scaling effect can be controlled. Moreover, the control effect of the same MPC algorithm on a real vehicle is better than that on a scaled vehicle (see Table 3), mainly because the real vehicle is equipped with ESP and other electronic devices to help control the stability of the vehicle.

5. Conclusion

It is difficult to test real autonomous vehicle under harsh conditions. Using the hardware-in-loop scaled platform to test scaled autonomous vehicle becomes an apparent alternative. In this paper, we use the HIL platform to test the slip of scaled autonomous passing through U-turn under high-speed condition. After comparing its result with the real vehicle testing, we have proved the feasibility of using HIL scaled platform as surrogates of the real autonomous vehicle for testing automated vehicle. Note that the proposed test platform has a very high flexibility in simulating real world traffic operations, including those with purely traditional vehicles. For example, it can be used for conducting traffic capacity analysis [2830], Long Distance Commuter lane (Qu and Wang, 2015), traffic oscillations [31, 32], traffic safety analysis [3335], and others. At the end of this paper, we use a simple case study of high-speed U-turn to build the tracking control function. A simplified vehicle dynamics model and a trajectory tracking algorithm have been considered to build the simulation test. The experiment results demonstrate the effectivity of HIL scaled platform.

In the future, we will continue this research on three aspects. Firstly, we will theoretically discuss the factors that result in the trajectory difference between scaled vehicles and real vehicles with the same trajectory tracking algorithm. Secondly, we will test scaled vehicles on its dynamic trajectory planning and tracking performance under traffic disturbances. Last but not least, we will utilize PaTAVTT to conduct experiments and validations on the trajectory optimization and control of multiple scaled and connected vehicles.

Notations

:The center coordinates of the vehicle rear axle
:The center coordinates of the vehicle front axle
:Velocity of the vehicle rear axle
:Velocity of the vehicle front axle
:The driving direction of the vehicle
:The angle of front wheel
:The wheelbase between the front and rear axle
:The lateral velocity of rear axle
:The longitudinal velocity of rear axle
:The configuration (position and orientation) of the center of the axis of the wheels
:State output of the reference vehicle
:Control input
:Control input of the reference vehicle
:The convergence of to
:Associated perturbation control input of the reference vehicle
:The sampling period
:The sampling time
:Control increments
:The number of sampling points of control inputs
:The number of predictive points of the system state outputs
:Weight matrix
:Weight matrix
:Objective function
:(A Hessian matrix) the quadratic part of the objective function
:The linear part
:Tire-road adhesion coefficient
:Transverse gradient of road
:Radius of curvature
:Gravitational acceleration
:The road safety speed with large transverse gradients
:The critical rollover speed of the vehicle on the load with large tire-road adhesion coefficient
:Wheel-track
:The center of gravity height
:The number of the total trajectory points at a sampling period
:The number of the trajectory points located in the reference trajectory buffer
:Lower bound of the input vector
:Upper bound of the input vector.

Conflicts of Interest

The authors declare that there are no conflicts of interest regarding the publication of this paper.

Acknowledgments

The research is supported by the National Natural Science Foundation of China (no. 51278058), the Fundamental Application Research Program of China Ministry of Transport (no. S2013JC9397), the 111 Project (no. B14043), the Funds for Key Scientific and Technological Innovation Team of the Shaanxi Province, (no. 2017KCT-29), the Zhejiang Provincial Natural Science Foundation (no. LY16E080003), and the Joint Laboratory of Internet of Vehicles sponsored by Ministry of Education and China Mobile.