Identiﬁcation of Driving Safety Proﬁles in Vehicle to Vehicle Communication System Based on Vehicle OBD Information

: Driver behavior is a determining factor in more than 90% of road accidents. Previous research regarding the relationship between speeding behavior and crashes suggests that drivers who engage in frequent and extreme speeding behavior are overinvolved in crashes. Consequently, there is a signiﬁcant beneﬁt in identifying drivers who engage in unsafe driving practices to enhance road safety. The proposed method uses continuously logged driving data to collect vehicle operation information, including vehicle speed, engine revolutions per minute (RPM), throttle position, and calculated engine load via the on-board diagnostics (OBD) interface. Then the proposed method makes use of severity stratiﬁcation of acceleration to create a driving behavior classiﬁcation model to determine whether the current driving behavior belongs to safe driving or not. The safe driving behavior is characterized by an acceleration value that ranges from about ± 2 m/s 2 . The risk of collision starts from ± 4 m/s 2 , which represents in this study the aggressive drivers. By measuring the in-vehicle accelerations, it is possible to categorize the driving behavior into four main classes based on real-time experiments: safe drivers, normal, aggressive, and dangerous drivers. Subsequently, the driver’s characteristics derived from the driver model are embedded into the advanced driver assistance systems. When the vehicle is in a risk situation, the system based on nRF24L01 + power ampliﬁer/low noise ampliﬁer PA/LNA, global positioning system GPS, and OBD-II passes a signal to the driver using a dedicated liquid-crystal display LCD and light signal. Experimental results show the correctness of the proposed driving behavior analysis method can achieve an average of 90% accuracy rate in various driving scenarios


Introduction
Accidents are considered one of the most detrimental aspects of the usage of automobiles.Due to the high density of vehicles, potential threats and road accidents increase [1].Road accidents are of great importance to all humanity, and this is a challenging issue that needs to be considered [2].Ordinarily, these accidents stem from driver errors, such as speeding and aggressive driving [3].Due to the ephemeral nature of Vehicle-to-Vehicle (V2V) networks, no individual vehicle can have a good view of the other vehicle's incident report behavior to reason about trustworthiness effectively.However, if one can design an effective mechanism to collect observations and experiences about individual vehicles, it would greatly facilitate the process of aggregating partial and incomplete information into meaningful intelligence [4].Simultaneously with the increasing worldwide demand for transportation, the challenges that drivers face every day are growing considerably.The situation analysis reports that major casualties are due to the improper driving behavior of drivers.According to the accident research statistics, 75% of fatal accidents are caused by such human factors as lack of attention, stress, loss of orientation, tiredness, medical condition, etc.In 24% of the cases the unexpected behavior is the cause of the accident and only 0.7% of accidents are due to technological failures (Figure 1) [3,[5][6][7].Intersection collision avoidance application combined with driver assistance systems may aid in crucial circumstances by taking a closer look around the corner effect, even in high obstructed channel conditions, according to safety-based V2V applications [2,8,9].In case of an accident, and to cover an adequately wide area, the module must resend the relevant accident message periodically and propagate them to make other vehicles aware of the accident.They can reroute accordingly [8].Pre-collision systems are a key aspect of these systems.Whether or not the collision is avoidable because it determines the vehicle type of action should automatically take [9].The next step is to develop systems capable of warning the driver to avoid a potential collision [10].Road users must be notified of potentially dangerous situations to react on time and appropriately.The V2V communication technology aims to ensure that vehicles are warned of potentially dangerous situations [11].Driver behavior modeling is essential for comprehending the driver's involvement in the traffic system and understanding traffic flow.In terms of time and space, the relations between the main components of vehicular traffic can be interpreted as a traditional human-machine framework [12,13].Aggressive driving behavior is an essential factor that quickly leads to dangerous driving [7].To understand safe behavior, which is critical to define unsafe or at-risk behavior.Previous research suggests drivers, who engage in frequent and extreme speeding behavior are over-involved in crashes [12].It is important to identify risky or at-risk activity to comprehend safe behavior.In this article, we attempt to use an online data collection approach for modeling drivers' acceleration to measure and analyze individual driving behavior using data collected from instrumented vehicles using various data collection techniques.Graphs and analysis was used to show the findings of the tests for various aspects.The following are the main contributions of this work: 1.
To determine and collect all the requirements for the V2V and driving behavior experiments during acceleration/deceleration phases; 2.
To statistically classify then develop a method and observational schemes to quantifying safe or at-risk behavior based on driving behavior data collection; 3.
Monitoring and evaluating hardware-based warning systems in vehicles using V2V technology context based on driving behaviors that assist drivers in the decisionmaking of passing safely.
This paper is organized as follows: Section 2 presents related work, while in Section 3, along with the system methodology, we present tools and software used for driving behav-iors data collection using the instrumented vehicle.Section 4 presents the proposed system algorithm for V2V and driving behavior.Section 5 shows the study sites and research participants.In contrast, in Section 6, we introduce the numerical results and statistical analysis of speed and acceleration data on the relaying strategies and the optimization results.Section 7 presents a discussion results and, finally, we conclude in Section 8.

Related Work
In the last ten-year period, speeding has consistently been cited as a contributing factor in most fatal crashes, which have been wholly or partially the fate of speeding behavior, and with real-time information, the forthcoming driving behavior could be predicted [13,14].Driving behavior is a subject of extensive research, and as part of efforts to improve our understanding of driver behavior, an increasing number of studies have employed improvements in technology and gaining special attention recently [15].As drivers' behavior is the leading cause of road casualties, identifying unsafe driving attitudes is an essential step towards reducing them [13].On the contrary, identifying risky or accident-prone drivers could facilitate more effective traffic safety work, coupled with the most appropriate incentives to avoid them.It is vital for the achievement of safe and efficient driving [16,17].The authors of [18] suggest a framework for identifying driver behavior that takes three anomalies in accelerations and directions into account, which are lane changes, excessive speed, and abrupt movements, while [19] proposed a data collection process using a set of vehicle sensors to identify a series of driving maneuvers to categorize driver features or assess the driver's skills.
Furthermore, ref. [20] developed a non-intrusive approach based on machine learning (ML) algorithms and dynamic vehicle data as inputs to a real-time framework for detecting and classifying driver distraction.Moreover, ref. [21] used nonlinear regression techniques and artificial neural networks (ANN) to build a driver model that can predict each human driver's regular driving on a given road segment with a realistic degree of precision.Authors in [22] verified the accessibility of the V2V using a laptop for network measurement using two vehicles to establish datasets of vehicle sensor readings associated with cellular and dedicated short-range communications (DSRC) connectivity measurements, while [23] presented a study of V2V connectivity and data collection in two research vehicles using industrial on-board units (OBU) and light detection and ranging (LiDAR).Authors in [24] proposed architecture integrates both data mining techniques and neural networks to produce a hierarchy of driving types.The authors have introduced a neural networkbased algorithm that can define the type of road on which the vehicle is traveling, as well as the degree of aggressiveness of each driver, using OBD parameters, such as altitude, acceleration, and RPM.Last but not least, ref. [25] suggested an analysis of a collision warning system (CWS) focusing on driving behavior to assess the collision danger level based on the driver's driving behavior.Unfortunately, many earlier studies relied on estimates of prevailing and pre-crash speeds, thus reducing their soundness.A speed reduction reduces the forces at impact during a crash; however, what is still unknown is whether speeding behavior leads to increased crash risk.To solve this problem, one must know something about the driver's general speeding behavior and the speeding behavior before a crash [14].Therefore, to illuminate the specific problems related to the V2V warning system based on driving behavior, three issues have been illustrated in this research.In the first issue, several criteria need to be considered in the V2V communication system, specifically regarding the forwarding message.These criteria include vehicle information, speed, location, and type of driver (Figure 2).The interactions between the key components of vehicular traffic concerning time and space can be viewed as a typical human-machine system, i.e., driver (human), car (machine), and environment [12].It is essential to comprehend the relationship between anticipating potential collisions and deploying collision avoidance techniques [26].The second issue that needs to be considered is dedicated to driver model development, which predicts each driver's normal driving on a specific road segment with a reasonable degree of accuracy [16,25].In this regard, the tradeoff and conflict among the criteria are reflected in the learning and identifying driving behavior selection process.This situation leads to disputes among attributes in the comparison, which affects the selection process.Consequently, selecting the most suitable wireless communication modules from several possible modules is considered a complicated issue.XBee systems, which are integrated devices that offer wireless networking standards with self-healing mesh networks that provide a more extended range than Bluetooth and lower power consumption than Wi-Fi, are among the most popular wireless connectivity modules used.An alternative to the XBee radio modules is nRF24L01, based on 2.4 GHz, which can improve the decision to address this problem [27,28].According to this analysis's assessment approach, two key categories were established from previous works: simulations and real time.A deep analysis of both sections' accuracy is conducted in [29] focused on the data exchange from previous articles to identify the gap in future directions that target data exchange in the V2V framework by conducting a deep review of the accuracy of both parts.Furthermore, a technology used in sharing information between moving vehicles based on driving behavior to create a collision alert system was developed, which achieved a higher accuracy rate than the other approaches by combining various types of scenarios, vehicle speed, and vehicle number, as shown in Figure 3.
Furthermore, as far as searching was feasible, a rare work that addresses V2V warning system based on the identification aggressively driving using real-time data collection and analysis based on various sensors in a near-real-time way as it is proposed in this work.Our research has addressed a more flexible method for detecting driving behavior and then presented a solution using the instantaneous reading from the OBD-II adapter to maintain the vehicles' string stability.

Methodology
This section presents the number of phases that are used to explain the research methodology.Five main phases are used to get the proposed system's objectives, as shown in Figure 4.The first phase (preliminary study) dealt with identifying and describing the research problem.The second phase (research and analysis) identifies the requirement and criteria for V2V collision warning system and driving behavior to define a method and observational schemes to monitor drivers and quantify safe or risky behavior.The third phase (hardware design) involves designing and developing a real-time hardware-based V2V warning system based on driving behavior.The final phase (usability testing) validates the performance of the proposed methodology.
A preliminary study is required to investigate the existing articles related to the V2V communication system to achieve the first objective.In this study, two investigations were conducted.First, a systematic review protocol on the V2V communication system is scrutinized.A critical analysis was then undertaken to figure out the gab and the main challenges in the V2V context presented in [29].Second, research was conducted on articles related to driving behavior techniques in the vehicular communication network.The collision warning system intends to notify the drivers about unseen or unexpected vehicles using real-time driving behavior data.The system can have an accurate real-time alert system that can alarm and allow the driver to respond to a successful product.The system can go through multiple steps to accomplish this system.In the first step, the device must detect vehicles in real time and collect all collision prediction data.The sensing functionality used should be able to distinguish between vehicle-generated signals and extraneous noise.The collected telematics data were filtered with driving behavior data and then loaded into input queues for review in the second process.It is essential to have a transceiver.An alarm system is triggered if the final process review indicates a high likelihood of a collision.

Hardware-Based Phase
This section provides a concise overview of the test experiment design for designing a hardware alarm system based on data analysis of driving behavior, including various experiments and scenarios.A selection of standards and metrics were taken from prior methodologies by analyzing papers and information about the collision warning system.Few studies have been directed in hardware development for warning systems based on driving behavior context.From this point, the hardware side serves two main functions.The first is the process of collecting and exchanging data between vehicles, and this is presented in the following subsection.The second aspect is related to the process of data collection of driving behavior and how to use the available devices and software.Table 1 indicates several factors that helped to choose the optimum device that offers the required objectives.Table 1 clearly shows a few studies have been directed towards either data exchange in V2V or related to driving behavior except for one article [25] that combined these two terms.They state that the driving behavior-based alert system's performance was only tested in the lab with actual vehicle data.As a result, more analysis is requested to assess the output using various driving data and alerts that arise when driving in a real vehicle.In addition to that, reference [27] indicated the possibility of using wireless communication module nRF24L01 to send and receive data for warning based on Bluetooth and ultrasonic sensors.Finally, reference [30] proposes a driving behavior analysis approach based on OBD-II information to collect vehicle activity information via OBD-II adapters.Vehicle activity information may include vehicle speed, throttle location, engine RPM, and measured engine load, then complete data preprocessing and driving behavior modeling in offline mode using MATLAB.Hence, using wireless technologies for information exchange has the potential to affect driver behavior in the direction of better driving safety and fewer road injuries.During the implementation process of this scheme, we concentrate on a new aspect called driving behavior to overcome the problems and limitations of previous researchers.
Table 1.Related works extracted from previous articles related to V2V and driving behavior.

References
Brief Description Used Criteria Technique Dataset Used [31] This study tested the transmission range effects on V2V communications on different roads, urban and rural roads using two vehicles employed moving in opposite directions.
Connectivity and distance V2V data Hardware [22] This study proposed an intelligent traffic monitoring system based on cloud computing, mobile apps, and roadside unit (RSU).
RSU-to-RSU delay and speed V2I data Hardware [32] This study proposed an approach for safe passage of an un-signaled intersection using V2V (static and moving vehicle) in the area with low development density and multi-story buildings with extreme development density area Connectivity V2V data Hardware [27] This study presented a new approach for intelligent transportation systems (ITS) to manage traffic flow modeled as to nearby "stop and move", based on an ultrasonic sensor for distance measurement using the nRF24L01 module wireless data, vehicle-controlled by the mobile application and connecting to the Bluetooth (HC-05).
Connectivity and distance V2V data Hardware [33] This study combined vehicles with smartphones through wireless OBD-II interfaces to monitor the vehicle and trigger automated warning using Android application, OBD-II, and 3G communication.The propose is to estimates the G force experienced by the passengers in case of a frontal collision used with airbag triggers to detect accidents and send details through e-mail or SMS.

Data collection and analysis
Driving behavior data Hardware [25] This research suggests a collision warning system (CWS) based on an individual's driving behavior, which uses an artificial neural network learning algorithm to calculate the collision probability based on the driver's driving characteristics.Radar, OBD-II, the VN5610 network interface, and the controller area network (CAN).
Connectivity, distance, data collection, analysis, and warning

V2V and driving behavior data
Simulation in V2V Hardware in driving behavior [30] Driving behavior analysis system focused on vehicle OBD data to gather vehicle activity data; vehicle speed, engine RPM, throttle location, and measured engine load.Thus, construct a driving behavior classification model to assess if current driving behavior is safe or not.

Data collection and analysis
Driving behavior data Hardware

Identification Phase
Identification of driver behavior is a prerequisite for traffic studies and has several applications, including road safety analysis, microscopic traffic modeling, and ITS.Driving behavior research is beneficial for various challenges in transportation engineering.These provide data collection for mathematical analysis as well as detecting driving models and parameter estimation.Data on driving behavior is obtained using an instrumented vehicle (IV) with GPS, radar, cameras, and other sensors.Several tools for observing behavior are available, some of which run on the roadside and others on the vehicle.First, in the case of roadside sensors, an unaware driver monitored while driving on the selected vehicle in the experiment site; various technologies can be used to observe driving behaviors.Second, on-board sensors mounted on IVs allow for more extended measurements under more flexible experimental conditions and the ability to observe certain maneuvers of specific interest in a controlled manner.In this system, on-board sensors can be used to capture and analyze driver behavior data, representing data collection, transmission, and backend platforms focusing on providing services and solutions in the vehicle domain with on-board services and connected vehicle-related services.OBD-I is an automotive term referring to a vehicle's self-diagnostic and reporting capability used in modern vehicles compatible with standard computer protocols.This adapter can connect to the vehicle network using this adapter.It works similarly to a network modem or gateway.It converts messages from one protocol to another; typically, data flow in all directions to and from the electronic control unit (ECU) [30,33].Moreover, a Freematics ESP32 OBD-II Kit is built on the Freematics Esprit, an Arduino compliant ESP32 development board, as well as a 1.3" OLED display and a Freematics OBD-II universal asynchronous receiver-transmitter (UART) Adapter, as shown in Figure 5.This kit is simple to set up and use, but it can potentially prototyping advanced innovative vehicle applications with plug-and-play features.The Freematics Esprit is a board that looks like an Arduino UNO but with additional pinouts for inter-integrated circuits (I2C) and two serial UARTs [34].Furthermore, Torque Pro can also be used as a debugging tool for running the Android operating system.When used in combination with OBD-II Bluetooth, Android users can gain access to a vehicle's several sensors, as well as display and transparent trouble codes.GPS time, latitude, longitude, GPS speed, acceleration, engine load, RPM, speed (OBD), GPS vs. OBD speed difference (km/h), and GPS Accuracy (m) can all be added to the Torque program.

Development Phase
This phase describes using real-time driving behavior to analyze the data to decide the target vehicle to enable the V2V data exchange and warning system.In this phase, driving behavior is categorized into four main classes: safe drivers, normal, aggressive, and dangerous based on OBD-II real-time data, then enable V2V warning system based on the driving using RF24L01 + PA/LNA transceiver module.Due to the absence of developed studies focused on the side of the hardware, the realistic part was selected.Integrating two or more V2V techniques is required to compensate for the drawbacks of single techniques.The measurement of the behaviors of drivers using their trajectory data are a recent and open area of study.To take action to change this situation, identifying dangerous driving is a big move.Driving behavior information is identified in this system by measuring and analyzing their movement data, which is collected using measurement equipment to detect offensive behavior to minimize the risk of injuries and deter collisions.As a consequence, drivers are supposed to become more mindful of their driving.After the devices were connected and prepared for testing, various scenarios were identified to collect the required data.In each scenario, several tests were conducted.

Validation Phase
This process evaluates the proposed framework to support V2V collision warning systems based on driving activities to ensure product, system, and technology consistency.Testing cannot be done just at the end of construction to be successful.It must be examined continually during the life cycle to forecast system effectiveness, classify potential outcomes, and assess suitability for testing, which is a critical decision that can significantly impact the proposed system's ultimate success.Following an analysis of the collision warning system's publications and facts, specific considerations for selecting the best model should be made.A variety of principles and metrics have been derived from previous methodologies and efforts to refine and improve them.Figure 6 depicts the proposed system's appearance and hardware elements.
The proposed V2V warning system based on driving behavior comprises a preprocessor stage, driving behavior model analysis stage, and a collision potential identifier stage.An Arduino UNO board was used to build the communication mechanism.The OBD-II cable adapter and nRF24L01 unit are used in the proposed framework to make communication between vehicles.For high-speed, high-sensitivity logging or monitoring, an Adafruit ultimate GPS breakout was used to provide 10 location updates per second.A micro SD TF card reader module with a serial peripheral interface (SPI) interface and chip-level conversion is used for data logging.A Geekcreit I2C 20 × 4 LCD monitor blue module for Arduino is used to display the message to the driver inside the vehicles.The information collected from the first stage was merged in the second stage.This step involves verifying the research's requirements, limitations, and timeframe for completion and developing a mechanism for selecting the destination vehicle for broadcasting information obtained by the proposed system to exchange data between vehicles and alert the driver about the aggressive drivers.The sensor and microcontroller circuitry are built in the next step.Finally, the hardware is troubleshooting to determine its performance.Any deficiency can be remedied by changing the circuit and coding before the device is operating at full potential.Debugging is carried out to make the code better.Finally, software and hardware should be incorporated to ensure everything is running smoothly into one complete system.

Proposed System Algorithms
Vehicular networks have two types of featured applications, which are driver assistance systems and vehicle safety.Because of their distinct communication patterns, these groups need different quality of service (QoS) characteristics.Vehicle safety and driver assistance applications are designed for vehicles that communicate with one another to detect potentially dangerous conditions or vicinity incidents.When the vehicle receives a safety warning, the driver is alerted by sound or light, allowing them enough time to respond and prevent an accident.Data were generated for each attribute after all of the evaluations were calculated.The final decision was completed and structured by combining the data from all attributes.The reason behind this process is its ability to simultaneously consider various procedures for the assigned priority to each attribute.Moreover, the tradeoff and conflict among the packet loss (PKL), packet delivery ratio (PDR), throughput, latency, acceleration, and vehicle location criteria are reflected in the V2V data exchange selection process.The complete proposed system presented in Figure 7 consists of three components, which become the main contribution of this project.These three components are the OBU deployed on the vehicle for driver behavior model analysis, preprocessor system inside the vehicle for potential collision identifier, and V2V data exchange system.
In this case, V2V communication is used to provide data to intelligent driving algorithms to preserve the distance, direction, and trajectory set between vehicles.These applications are depicted by short messages intended for vehicles close to the sender and must be received instantly to avoid an accident.As a result, such communications take place between vehicles using a datagram-based transport protocol.Low latency, jitter, and error rates are needed for such applications, which do not need higher bandwidth.Meanwhile, the proposed V2V's most creative implementations are those related to driver assistance and protection.These applications do not focus on 3G/4G networks because they must function even though network coverage is limited or non-existent due to a lack of pre-existing connectivity infrastructure.Additionally, to reduce the end-to-end latency, such messages can be shared directly between vehicles rather than passing via fixed infrastructure.New communication standards for V2V systems have been introduced.The OBU is intended for the interconnection of various subsystems.By linking the OBD-II adapter and GPS, vehicle data can be gathered.The details from nearby vehicles can be obtained using the nRF24L01 system.They provide collision forewarning for drivers using information from the OBU unit.Engine start date and time, second-by-second vehicle position (latitude and longitude), location, and speed are all monitored by the on-board equipment.The suggested scheme also collects and uses data on the number of satellites and GPS signal frequency metrics.A direct link to the OBD-II engine computer port allows the equipment to have up to ten engine and emissions-related parameters from the on-board diagnostics facility.

Algorithmic Procedures of the V2V Data Exchange
Vehicle-to-vehicle communication helps vehicles form spontaneous wireless networks on the go and transfer data over an ad-hoc mesh network.Individual vehicles use the information from the network to create a dynamic view of their surroundings.The proposed algorithm uses an nRF24L01 + PA/LNA transceiver antenna installed close to the windshield altogether with an OBD-II reader and GPS chipset to provide information, such as the speed, location, and distance of the surroundings vehicles based on driving behavior.The sensors send a signal every time interval ∆t to scan the surrounding vehicles according to their drivers' behavior.The detector sensor can detect all vehicles traveling in the same and opposite directions that could collide or present a risk to the passing vehicle.The algorithms use a reading sensor and a processing unit with a driver-vehicle interface (DVI) unit to decide whether or not a "safety" message should be shown for the driver of the passing vehicle, as seen in Figure 8.It is well documented that various wireless technologies have different association times and data rates.These parameters play a significant role in successful communication in the proposed V2V system.By using computing and communication devices, vehicles can communicate with each other using V2V based communications.Vehicles assumed that they periodically broadcast their geolocations, speeds, etc., a piece of information in the network.There are two types of scenarios for V2V communications: (i) vehicles traveling in opposite directions and (ii) vehicles traveling in the same direction.It can be noted that the time interval during which two vehicles can communicate directly depends on their relative speed.The algorithm procedures of V2V data exchange can be explained as follows: 1.
The system defines the vehicle mode, whether in receiving or transmitting mode.In receiving, the nRF24L01 continues searching for vehicles within the selected vehicle's coverage range.If one of any vehicles with abnormal behavior enters the field, the system automatically displays a warning message for the driver.The message can be auditory, visual, haptic, or a combination of any of these.The message does not deactivate until the algorithm confirms that a safe pass is possible.2.
The system can estimate the location and the time required for each detected vehicle to reach the conflict point using a previously presented methodology using a haversine formula.

3.
The algorithm can recognize multiple vehicles, and the procedures outlined above are followed for each passing vehicle.4.
In the case of transmitting mode, the system moves directly to the second stage of transmission.The method in each vehicle calculates and defines driving behavior.If any abnormal behavior is found in the vehicle, send reports about vehicle position and speed, route direction, traffic, and road conditions.The information is added to the network and serves as a safety warning for the other vehicles.Based on the four cases mentioned above, the V2V data exchange algorithm is described in Algorithm 1.

Algorithmic Procedures of the Driving Behaviors
Driving behavior is a contributing factor in most road crashes.As a consequence, there is a significant benefit in identifying drivers who engage in unsafe driving practices.Furthermore, it is critical to developing advanced driver assistance systems toward increasing vehicle automation levels.Innovatively, a developed driving behavior analysis approach is proposed based on vehicle OBD-II and V2V algorithms.The suggested system gathers vehicle activity data, such as vehicle speed and engine RPM.Data of a driving behavior collected from the driving tests are used to develop a driving behavior model.Data from the OBD-II interface that were not used for learning were used for the test scenario.The proposed approach then employs V2V algorithms to build a driving behavior classification model, which can then be used to decide if the actual driving behavior is safe or not.The targeted critical behavior identified for this paper is acceleration, and therefore, "safe performance" is based on driving within the confines of the proposed acceleration values.The algorithm procedures of driving behavior are done first by initializing the OBD-II connection.Then the system starts gathering driving data to determine driving status in acceleration or deceleration, which can be done from a series of consecutive readings calculations obtained from OBD-II reader.The driving mode is defined in terms of the difference between two successive readings, where upon reaching a certain number of readings (5 or 10 flags).The driver's behavior is defined, then these flags are stored and sent to neighboring vehicles.The main program workflow is illustrated in Figure 9, representing the driving behaviors data collection and identification process.
The system calculates the conflict point based on the driver input data and the identification sensor warning, which is then used to measure the passing vehicle's time to clear the opposing vehicle's direction.The vehicle safety application is developed on the LCD screen to display driving information and provide crash warnings because the OBD does not provide a user interface (UI) to communicate with the driver.The "safe" signal is displayed if the surrounding vehicle can pass safely.A "not safe" warning stated, and the moving vehicle must be stopped because it is unsafe.This system gathers data about the nearby vehicles' driver behavior.The map section of the app displays the current vehicle's position and the coordinates of nearby vehicles on the screen.When the device detects an oncoming collision, the driver is notified with a screen warning and a voice alert.The comprehensive details section displays the vehicle's driving data, including its position (longitude and latitude), direction, heading, acceleration, and so on.Algorithm 2 describes the pseudo-code for the successful driving behavior technique developed for the proposed V2V data exchange scheme.drivers participated in fifteen experiments in three vehicles (Hyundai Sonata, Hyundai Santa Fe, and Renault Safrane).
The second data collection took place in Iraq for two months, from December 2019 to the end of January 2020, in Baghdad and Babylon.Seven drivers participated in fifteen experiments in three vehicles (Hyundai Sonata, Hyundai Santa Fe, and Renault Safrane).

Numerical Results and Discussions
The data exchange in V2V is measured using several vehicles with various locations and scenarios based on the nRF24L01 + PA/LNA wireless transceiver module with an external antenna and the Arduino Uno board connected to collect the data in each experiment scenario.The nRF24L01 + PA/LNA module is abundant in the market and at low prices and provides much better coverage than other devices.The data transfer rate was set at 250 Kbps, and the output power was 0 dBm.The two devices were connected via seven wires: power supply (3.3VCC), ground (GND), chip select not (CSN), chip enable (CE), serial clock (SCK), master in, slave out (MISO), and master out, slave in (MOSI)-attached to PCs through a USB cable in both the transmitter and receiver.There are two essential components in aggregating data from multiple vehicles.The first component describes the communication process by which the data are transmitted to the vehicle and what form the data takes for a given process.The second component in data aggregation involves how the data are stored and indexed appropriately for any detection algorithm.For data collection, there are several steps involved in connecting and installing the nRF24L01 V2V device.After completing the installation and uploading codes to collect data on the microcontroller, connect a 9 v battery to power up the device.Next, each device is mounted inside the vehicle; then, the system directly starts sending information to nearby vehicles and receiving data if any vehicle enters the first vehicle's coverage area.Each message includes information about this vehicle and the count number of the sent data.Once this vehicle has joined the other vehicle's coverage area, the second vehicle begins receiving these messages from its entry into coverage until its exit from the broadcast range.The overlapping area between moving vehicles can be classified into three cases: total overlapping, no overlapping, or partial overlapping.The probabilities of conjunction and disjunction in extreme cases, complete overlapping, and no overlapping are easy to calculate.However, the third case to determine the conjunction and disjunction probability values is different since the overlap between two events is a variable.Once the total overlapping occurred, the vehicle (vehicle 1) transmitting data to the other vehicles within the coverage area (Figure 10a).On the other side, another vehicle (vehicle 2) entered the coverage area, receiving all information sent from the first vehicle (Figure 10b).

Packet Delivery Ratio (PDR) of the nRF24L01 + PA/LNA Antenna
The results of PDR given by the nRF24L01 + PA/LNA antennas are presented and explained in this section.PDR is defined as the number of received packets divided by the number of transmitted packets.The experiments used two OBUs at varying distances and calculated the package delivery rate to test the efficiency of the V2V under various scenarios.The distances ranged from (0-300) m, with a 25 m interval.Furthermore, the tests were carried out in two scenarios.First, by setting the nRF24L01 + PA/LNA with lower power and high data rate of the transmitter.Second, we change the setting of the nRF24L01 + PA/LNA to maximum power and lower the data rate of the transmitter.At 250 Kbps, the nRF24L01 + PA/LNA has the best receiver sensitivity, which is −94 dBm.The receiver sensitivity decreases to −82 dBm at a 2 MBps data rate.Setting the output power also helps to extend the range of the transmission range in the proposed system.The output power of the nRF24L01 + PA LNA is set to 0 dB, −6 dB, −12 dB, or −18 dB.All of the experiments were conducted outside, with a spacing between the two nRF modules ranging from 25 to 300 m.For each distance, 1000 packets are sent, and the PDR is determined by dividing the number of successfully received packets by the total number of sending packets.The results are shown in Figure 11.
According to these results, the PDRs of the nRF24L01 + PA/LNA decrease noticeably as distance increases.When the distance between the vehicles is less than or equivalent to 225 m, the sensor's PDR is greater than or equal to 62%, while the vehicles are traveling in the same direction.The module runs at low power and high data rate, while in the second experiment, we see a great improvement in the PDR ratio reaching 70%.The clear effect on PDR can also be observed in other experiments, whether two vehicles in the opposite direction or without traffic islands.At 250 Kbps, the receiver is almost ten times more sensitive than at 2 Mbps, meaning it can read a ten times weaker signal.As a result, lowering the data rate vastly increases the range that can be achieved.As a result, a data rate of 250 Kbps is more than adequate.A better signal is sent through the air, while the  The results of PDR given by the nRF24L01 + PA/LNA antennas are presented and explained in this section.PDR is defined as the number of received packets divided by the number of transmitted packets.The experiments used two OBUs at varying distances and calculated the package delivery rate to test the efficiency of the V2V under various scenarios.The distances ranged from (0-300) m, with a 25 m interval.Furthermore, the tests were carried out in two scenarios.First, by setting the nRF24L01 + PA/LNA with lower power and high data rate of the transmitter.Second, we change the setting of the nRF24L01 + PA/LNA to maximum power and lower the data rate of the transmitter.At 250 Kbps, the nRF24L01 + PA/LNA has the best receiver sensitivity, which is −94 dBm.The receiver sensitivity decreases to −82 dBm at a 2 MBps data rate.Setting the output power also helps to extend the range of the transmission range in the proposed system.The output power of the nRF24L01 + PA LNA is set to 0 dB, −6 dB, −12 dB, or −18 dB.All of the experiments were conducted outside, with a spacing between the two nRF modules ranging from 25 to 300 m.For each distance, 1000 packets are sent, and the PDR is determined by dividing the number of successfully received packets by the total number of sending packets.The results are shown in Figure 11.
According to these results, the PDRs of the nRF24L01 + PA/LNA decrease noticeably as distance increases.When the distance between the vehicles is less than or equivalent to 225 m, the sensor's PDR is greater than or equal to 62%, while the vehicles are traveling in the same direction.The module runs at low power and high data rate, while in the second experiment, we see a great improvement in the PDR ratio reaching 70%.The clear effect on PDR can also be observed in other experiments, whether two vehicles in the opposite direction or without traffic islands.At 250 Kbps, the receiver is almost ten times more sensitive than at 2 Mbps, meaning it can read a ten times weaker signal.As a result, lowering the data rate vastly increases the range that can be achieved.As a result, a data rate of 250 Kbps is more than adequate.A better signal is sent through the air, while the output power is set to 0 dB.At these points, we further analyze the forward collision warning that monitors a vehicle's speed, the vehicle's speed in front of it, and the distance between the vehicles designed to prevent or reduce the severity of a collision based on the driving behaviors.

Driving Behavior Acceleration Data Recognition
The proposed system generates a warning message and an estimated distance for the vehicles based on their driving behaviors within the coverage area.Recognition of driving behaviors is a subjective mechanism dependent on the driver's experience and response to changing environmental constraints over time.Driving environment and behaviors are well recognized to depend on individual experience and calculation with a high degree of ambiguity.As a result, developing a high-level design solution that incorporates existing technology and cognitive systems to develop a unique approach to understanding driving behavior trends is critical.At the beginning of the proposed design, the V2V system defined driving behavior using specified codes.The system read each instantaneous OBD-II reading speed to calculate the instantons acceleration or deceleration of each driver.Figure 12 shows the longitudinal acceleration for normal and aggressive drivers.In this case, analyzing instantaneous vehicle parameters recorded during real-time road tests is useful.OBD-II adapters can collect a range of objective vehicle and driving style details, which can be used for driver style identification due to advances in mobile sensor technology and these devices' technical capabilities.To gather data for driving activities, we performed real-time experiments.In these observations, an Android program collected vehicle engine data when a driver executed real driving events.To establish the ground-truth experiment, the beginning and end timestamps of the driving events were recorded.A few researchers addressed acceleration rates that are related to causality and a high chance of road accidents.According to [17], the probability of collision begins at 4.0 m/s 2 .In contrast, comparable findings were obtained for a risk of accident interference about 5.0 m/s 2 in [25,35].Reference [13] suggested a stratification of acceleration focused on numerous publications to describe driving types.In case of acceleration they proposed different types of driving: risky (from 7.0 m/s 2 to 12.0 m/s 2 ), offensive (from 3.5 m/s 2 to 7.0 m/s 2 ), natural (from 1.5 m/s 2 to 3.5 m/s 2 ), and stable (0 m/s 2 -1.5 m/s 2 ).Considering the mentioned works and based on our experiments to build a driving style table to allow the V2V warning system using driving behavior online data, we propose an acceleration stratification consisting of many classes to measure vehicle acceleration and braking.By measuring in-vehicle acceleration based on real time tests, it is possible to categorize driving behavior into four distinct categories: dangerous, aggressive, hostile, normal and safe or non-aggressive drivers, as shown in Figure 13.The system produces a warning message and a distance estimate for vehicles based on driver behavior within the proposed system's coverage area.Recognition of driving behavior is a contextual process that depends on the driver's perception and response to changing external pressures.Individual variability in knowledge and measurement is well understood to underpin the driving atmosphere and behavior.A high-level architecture paradigm integrating modern technologies and cognitive frameworks to provide a new approach to recognizing underlying behavior patterns is crucial.The various experiments show acceleration data similar to previous researchers, with a few slight variations.As seen in Figure 14, these data were inserted into the proposed scheme to characterize driving efficiency.Table 2 proposes a stratification of acceleration with four significant acceleration classes speeds used in the proposed V2V warning system based on driving behavior real-time data.Acceleration values ranging from around 2 m/s 2 are indicative of safe driving behavior.On the other hand, standard driving can require more efficient but still expected braking, resulting in more intense acceleration values ranging from 2 to 4 m/s 2 .The probability of a collision begins at 4 m/s 2 , which represents aggressive drivers in this analysis.According to the dangerous assessment, the driver uses abrupt motions in terms of speeding starting at 7 m/s 2 .These variations in acceleration results were noted for future conflicts due to the differences in the drivers who conducted the experiments.We can see from the fact that some of them drove instinctively, while the others drove aggressively.As seen in Figure 15, the test results were successful where the driver's behavior was shown based on real-time acceleration readings obtained from the OBD-II system attached to the vehicles.
The proposed algorithm uses an nRFL24L01 with an OBD-II transceiver that can be mounted in a passing vehicle.These sensors provide information, such as the impeding and opposing vehicles' speed, direction, and distance at any period (∆t).Sensors send a signal to search the lane for any oncoming traffic.The algorithms use a reading sensor and a processing unit with a DVI unit to evaluate whether a "secure" message should be shown for the passing vehicle's driver.First, the transmitter is placed inside the first vehicle with the OBD-II connected to the engine control unit (ECU) to obtain driving behavior and consider it as a power source for the board as a whole.In the second vehicle, the receiving device is placed on the dashboard of the second vehicle.A suitable and reliable external warning system has been used to inform the drivers about the driving conditions.However, getting the driver's attention is a difficult task and is linked to his or her psychological conduct.Humans tend to adjust and completely disregard statistical regularities.One suggestion is to use lighting LEDs as a visual stimulus in the vicinity of nearby vehicles to attract drivers' interest.In contrast, a big screen with a consistent background color installed on the dashboard suffice to get the driver's attention.The V2V device uses a 20 × 4 I2C character LCD mounted on the microcontroller testing board for testing.The display is capable of displaying four lines of twenty dot matrix characters.If normal behavior occurs, the green LED starts flickering as a simple type of additional alert for the driver.It displays Normal on the board to notify the driver inside the vehicle, especially the surrounding vehicles is normal, and it does not represent any threat with no further calculation or analysis needed, as shown in Figure 16.For aggressive and dangerous driving behavior experiments, two vehicles have been used in leading and the following position on the highway roads to check the system performance in aggressive and dangerous behavior.The nRF24L01 + PA/LNA transceiver antenna data and the vehicle type and flag status were sent to neighboring vehicles.On the receiving vehicle's far side, the system displays the transmitted flag while measuring the distance between moving vehicles with the GPS unit built into the board.Moreover, as long as the sending vehicle is within the receiving vehicle's coverage area, the V2V system turned on the orange LED with a periodic assessment of the distance between vehicles, whether the vulnerability is approaching or drifting away.Figure 17 indicates a warning signal shown by the LCD installed in the V2V system.The risky evaluation signifies that the driver makes abrupt motions in acceleration, starting with 7 m/s 2 .The warning system is triggered based on these results, using the same procedures as in aggressive behavior.The receiving vehicle device displays the sent flag and uses the GPS unit placed on the receiving board to calculate the distance between the two moving vehicles.The buzzer and the red LED should be enough to catch the driver's attention.As long as the sending vehicle is within the receiving vehicle's coverage range, the V2V device continuously updates the distance between two vehicles, whether the vehicles are approaching or drifting away.Figure 18 indicates a dangerous signal displayed by the LCD installed in the V2V system.

Discussion
The results in this study present the research methodology phases that are used to evaluate the performance of the hardware developed against multiple V2V scenarios and to validate the V2V warning system.Data collection methods and the techniques of data processing for V2V used in this study have been described to monitor and investigate driving behavior.Different scenarios were carried out based on real-world experimental testing using nRF24L01 + PA/LNA V2V system mounted inside the vehicles, which is a multimodal communication device intended for data transfer between vehicles in leader and tail vehicles, opposite direction.The driving behaviors studied were dealing with speed, acceleration, and RPM pedal when leaving from a stationary position at a signalized intersection, roundabout, and stops.Designing hardware that can collect the required data and developed hardware performance is evaluated against multiple scenarios and multiple criteria evaluation metrics.It was experimentally verified that the driving behaviors proposed model accurately reflected the driver's driving behaviors.The proposed methodology has retained some advantages for other literature studies because of the simultaneous use of acceleration, RPM, and vehicle location.In particular, the proposed system had excellent performance in terms of both convenience and safety, providing salient collision warnings to drivers by reducing unnecessary warnings.The estimation results revealed that modeling the decision to pass makes a statistically significant contribution to explaining passing behavior.To improve the quality of the data that vehicle-based components could use to issue warnings, an inertial measurement unit to detect acceleration forces used.In addition, a driver-vehicle interface would be essential for issuing warnings to the driver; such warnings could be audial or visual with the corresponding required hardware.

Figure 3 .
Figure 3. Gap study from several articles based on data exchange in V2V(vehicle-to-vehicle) and driving behavior system.

Figure 5 .
Figure 5. Data collection tools for driving behavior.

Figure 6 .
Figure 6.Schematic diagram of the proposed data exchange in the vehicle-to-vehicle system.

Figure 10 .
Figure 10.A detailed example of data exchange in the V2V system.

Figure 10 .
Figure 10.A detailed example of data exchange in the V2V system.

Figure 11 .
Figure 11.PDR with the impact of distance in multiple V2V scenarios using nRF24L01 + PA/LNA.

Figure 12 .
Figure 12.Longitudinal acceleration and deceleration for the normal and aggressive driver.

Figure 13 .
Figure 13.Analysis of driving behavior based on acceleration results.

Figure 14 .
Figure 14.V2V data exchange system for point-to-point connection network layout.

Figure 15 .
Figure 15.Test results of the proposed method.

Figure 16 .
Figure 16.V2V warning system based on driving behavior.

Figure 17 .
Figure 17.Real-time results for V2V systems related to aggressive driving results.

Figure 18 .
Figure 18.Real-time results for V2V systems related to dangerous driving results.

Table 2 .
Defining behaviors based on experiments.