# A Survey of Vehicle to Everything (V2X) Testing
## 5 V2X Testing Methods
### Function Testing
But it also faced the above problems because the testing environments were still virtual. Our team is building a function testing system which extends the HIL methods. The system uses communication devices instead of the network simulator. The architecture is shown in Figure 5, including the V2X simulation platform, V2X communication module, GNSS simulator, channel interference unit, and CAN bus simulator. The V2X simulation platform performs application scenario simulation, test cases management, test result analysis, etc. It is used to generate dynamic simulation data of the vehicle, such as vehicle speed, position, distance between vehicles, obstacles, traffic scenes, etc., and manages the entire test activity. The V2X simulation platform generates a virtual traffic scenario based on the test cases. The scenario includes a host vehicle (HV) and at least one remote vehicle (RV). The host vehicle refers to the vehicle under test in this scenario, and the RV is used to assist the HV to trigger applications. The V2X simulation platform is connected to the V2X communication module through an Ethernet interface or similar to control the transceiver behavior of the V2X communication module. It also interconnects with the GNSS simulator and the CAN bus simulator through a serial or similar port, and sends the simulation data to the V2X communication module and the device under test. The V2X communication module is used to simulate a RV in a virtual traffic scenario to generate application messages such as a basic safety message (BSM), and then sends it to a device under test through the channel interference unit. Meanwhile, the V2X communication module can also receive application messages sent by the device under test. We have two methods to obtain the application messages of the V2X communication module. One involves the V2X simulation platform directly generating application messages and sending them to the V2X communication module, as shown in Figure 5a. The second involves the V2X communication module generating corresponding application messages according to the simulation data from the GNSS simulator and the CAN bus simulator,as shown in Figure 5b. The channel interference unit simulates the communication environment, such as signal attenuation, interference, and so on. The device under test is used to simulate the HV in a virtual traffic scenario and runs V2X applications relying on simulation data. If the application is triggered, the device under test will generate a control action or warning information, which will be fed back to the V2X simulation platform through the CAN bus simulator. At this time, the HV will perform actions such as braking and issuing a warning, in the virtual traffic scenario. There may be many problems in the function testing. Firstly, time synchronization is a big challenge for testing system. Because vehicles usually spend most of their time moving at high speed and the frequency of message transmission is very high, the unsynchronized vehicles will lead to trigger the applications wrongly. How to integrate real-time simulators and non-real-time ones guaranteeing time synchronization should also be considered before building the function testing system. Secondly, extra communication simulation delay that is the simulating delay minus the real delay such as V2V delay should be low. The extra delay may be generated due to the communication models. If the extra delay is high, the communication simulation can't reflect the reality. Finally, testing scenarios which is the key of function testing should cover special situations such as traffic jams, highway, mountain area and etc. In these extreme scenarios, application may perform bad.