Low cost approach to real-time vehicle to vehicle communication using parallel CPU and GPU processing

This paper proposes a novel Vehicle to Vehicle (V2V) communication system for collision avoidance which merges four different wireless devices (GPS, Wi-Fi, ZigBee® and 3G) with a low power embedded Single Board Computer (SBC) in order to increase processing speed while maintaining a low cost. The three major technical challenges with such combinations are the limited system bandwidth, high memory requirement and slow response time during data processing when accessing various collision avoidance situations. Collision avoidance data processing includes processing data for vehicles on express ways, roads, tunnels, traffic jams and indoor V2V communication such as required in car parks. Effective methods are proposed to address these technical challenges through parallel Central Processing Unit (CPU) and Graphic Processing Unit (GPU) processing. With this, parallel V2V trilateration and parallel bandwidth optimization, multi-dimensional real time complex V2V data streaming can be attained in less than a second. The test results have shown that there is at least a 4 to 10 times improvement on processing speed with parallel CPU and GPU processing used in V2V communication depending on different road safety conditions. Keywords-component; CUDA; Parallel processing; Vehicle to Vehicle Communication; WLAN; ZigBee.


INTRODUCTION
Road safety has drawn worldwide attention due to an increasing number of accidents every year.According to the United Nations (UN) road safety report approximately 90% of road fatalities occur in low and middle income countries [1] and high portion of these accidents are due to issues directly related to the driver.
Due to its high impact, much research on Vehicular Ad-Hoc Networks (VANET) and the safety applications that go along with it have been carried out to prevent or lower the rate of accidents [2] [3] [4] [5].VANETs are the customary implementation of network communications for Intelligent Transport Systems (ITS).Dedicated Short-Range Communication (DSRC) is the standard used for V2V communication operating in 5.9 GHz.The most basic V2V communication system consists of GPS and General Packet Radio Service (GPRS) which transmit the current vehicle location to the nearby vehicle using mobile the Point to Point (P2P) network protocol.
VANET is designed to target for quicker response of the low latency network V2V communication connectivity.However as the infrastructure of the vehicles are getting more complex and the flow of traffic is increased, more sensors and electronic devices are built on-board the vehicle to enhance road safety conditions.Much research and the accompanying solutions have been implemented to lower down the cost of replacing the wireless V2V communication system which uses expensive transceivers with commonly used wireless network systems such as Wi-Fi (802.11),Wireless Broadband (802.16) ZigBee® (802.15.4) or other emerging network device [6] [7] [8] [9] [10] The objectives of this research are as follows:  LOW COST -To design a low cost V2V collision avoidance system through parallel CPU and GPU processing based on widely available GPS, Wi Fi, ZigBee® and 3G broadband units.
 LOW POWER, HIGH SPEED -Development of parallel bandwidth, data optimization and V2V trilateration algorithm, able to process the data in real time on a low power SBC.

II. RELATED WORK
Vehicular ad-hoc networks (VANET) have gain wide popularity since the mid-90s [11].VANET is an important element for accident prevention for on road vehicle.Data retrieval and clear presentation to the driver from the surrounding environment has been proven to reduce human errors while driving [12] [13].However, the wireless bandwidth for vehicle communication system is very limited [14] [15].An efficient communication protocol is needed to avoid overloading the system.
In view of this, [16] [17] [18] [19] et.al proposed the GPS and GPRS/GSM communication which tracks the location of the vehicle.The data is uploaded to the server and is monitored in real time.The main weakness for the system is that, the data is transmitted or received through GPRS/GSM which only allows a small amount of data to be transferred in and out the system.
[20] [21] [22] [23] et.al proposed the V2V communication by implementing the Collision Warning Systems (CWS) which www.ijacsa.thesai.orgare radar, camera and radio based.Radar/Ladar and camerabased collision detection is meant for detecting and viewing what is in front and at the rear of the vehicle.Their proposed method uses a radio based system which covers the side angle where a potential collision might occur.Radio based methods adopt a similar concept such as Wi-Fi stack -Time Division Multiple Access (TDMA).The main drawback for such setup is the system cost increases due to the implementation of Radar.
[24] [25] [26] [27] et.al proposed the Wireless Access for Vehicular Environment (WAVE) for V2V and Vehicle to Infrastructure (V2I) system.The proposed system uses the Road Side Unit (RSU) coordination scheme for WAVE safety services support.This means that, the Access Point (AP) or known as WAVE provider is set up along the road.The economic drawback of this method is the need to set up the high cost RSU's and this limits the number of locations that is covered.
Our work is focused on creating a cost effective real time V2V network system.This system in each vehicle consists of a Global Positioning System (GPS) satellite based positioning system and a wireless location positioning system (LPS) which was developed using low cost short range wireless ZigBee® device (IEEE 802.15.4).3G broadband is used to transmit or receive the information from the server in case of emergencies such as vehicle breakdown, traffic jam or road accidents.The methodologies for such configurations are implemented through parallel CPU and GPU processing.This method is capable of not only boosting the performance occupancy but also reduces the delay latency on data transfer between hardware and software in an efficient order.

III. PROPOSED WORK
As shown in Fig. 1, is a top down embedded system architecture view.It consists of 5 layers, Red, Green, Blue, Purple and Orange.The system can be categorized into two parts: real time data processing and non-real time data processing.The real time requirement for data processing such as with the Wi Fi, ZigBee® and GPS will be given a higher priority as compare to Broadband transmission and speech recognition.Non real time data processing

A. The Red and Green Layer
This is the hardware layer where Wi Fi, ZigBee®, GPS and Broadband Modem (represented in the block diagram) are connected and data is obtained from the real world.Data synchronization between devices was previously performed at the Green layer -Task parallelism library (TPL).TPL is one of the features in Microsoft® .netframework.The objective of using TPL is to divide the task into sections and parallel processed through the CPU.The incoming data from different devices were split into four different tasks.Each task was split into multiple threads.Threads can be parallel processed through multiple Central Processing Unit (CPU) and Graphic Processor Unit (GPU).If different data streams from the hardware devices simultaneously, data processing priority was given from the left to the right, which means the Wi Fi device has the highest priority and the Broadband device has the lowest.
Both Wi Fi device and ZigBee® consist of two parts, with a total of four devices.There are two devices in Wi Fi block diagram: Wi Fi router and Wi Fi client adapter.The Wi Fi client was installed on individual vehicle.Data transfer between Wi Fi client adapters of different vehicle is facilitated through the Wi Fi router.The maximum transmission range for the Wi Fi device is 100 meter radius wide, supporting up to 54Mbps of data transfer rate.
ZigBee® system consists of two items: the ZigBee® Coordinator and the ZigBee® router.The ZigBee® router is used to establish connection between vehicles in a mesh topology the total number depending on the ZigBee® system standard for number of devices within a mesh.Although the maximum data transfer rate for ZigBee® device is 250Kbps, it has a very low packet overhead during transfer.The data transfer rate will maintain its consistency within 100 meter radius.ZigBee® devices were used in V2V communication mainly for range estimation.ZigBee® devices are very low in power consumption.Hence, the device will therefore continue to operate even when the vehicle engine is turned off.
For outdoor location tracking, the Global Positioning System (GPS) is used.The GPS device follows the NMEA 0183 format for location and time zone retrieval.The fundamental problems for GPS are: the distance estimation tolerance is up to ±15 meters [37] and GPS can only work in outdoor environment.Therefore, the combination of ZigBee® and GPS is a necessity to solve the problem.
The 3G broadband device is used for internet connection to send or download the latest update from the centralized management server.This information includes traffic info and accident location from the vehicle itself (if any).

B. The Blue Layer
The software layer, represented in Blue Layer, is the interface to the Hardware layer (Red Layer).Vehicle to vehicle communication was facilitated using Windows Communication Foundation (WCF) framework, which is a replacement for Winsock API.www.ijacsa.thesai.orgWindows Communication Foundation served as the Transmission Control Protocol/Internet Protocol (TCP/IP) stack to support communication with the router.Each vehicle has its designated Internet Protocol (IP) address and a unique ID tag.The ID tag can be transmitted through ZigBee® device from vehicle to vehicle in a star topology that used multicast protocol.The IP address is generated in random order; it follows the IPV4 format, Class C network ranging from IP address 192.168.9.4 to 192.168.9.254.IP address which range from 192.168.9.1 to 192.168.9.3 is reserved for debugging and testing purposes.If IP conflict occurs, Windows Management Instrument (WMI) will assign a new IP to the current vehicle.The vehicle to vehicle communication is within 100 meters radius and has maximum of 30 vehicles linked within the range.Each time a communication is established, the router search through the network IP polls (192.168.9.4 to192.168.9.254) for unique ID.Once the ID was identified, the properties of the vehicles, including the speed, location and the ID, are sent through the wireless communication.Once the vehicle is out of the 100 meter radius range, the IP will be released automatically so that the IP address will be available for another incoming nearby vehicle.
Without GPS, the location of the vehicle is calculated by using the distance trilateration method.This method pinpoints the vehicle location by comparing the distance of the 3 nearby vehicle.Once the location of the nearby vehicle location is identified, the vehicle location is computed through the Thread Building Block (TBB) [39].TBB allows the thread to be parallel processed on two different GPU cores.Whenever the GPS signal is available, the map will be updated accordingly to reflect the latest location of any vehicle within the 100 meters vicinity radius range.
The vehicle ID, location, speed, time and date will be sent to the server through 3G broad.The server will help to monitor the traffic flow.If any accident happened in the particular location, the server will transmit the data to alert the driver.

C. The Purple Layer
Speech recognition was located at the purple layer.It was integrated into the system based on the built-in function from Windows OS.The system is programmed to detect extreme changes in voice pitch, e.g.shouting.The system has some preprogrammed command such as -send it‖, -retrieve it‖ that allows user to interact with the system while driving.Once the system detects an abnormal tone, the system will switch to panic mode and take control of the dangerous situation automatically.The system will give audible warning such as -warning, nearby vehicle is within the range of xx meters‖.Information regarding the vehicle, for example the location and the vehicle ID, will be transferred to the server as needed.

D. The Orange Layer
The orange layer represents the Graphic Processing Unit (GPU) parallelism layer.Compute Unified Device Architecture (CUDA) programming model has two parts: Host and Device.The Host is the CPU and the Device is the GPU.Data were transferred from the Host (CPU) to the Device (GPU) in a single-program, multiple data (SPMD) for preprocessing.Thread building block [39] transfers the array of data from the parallel CPU to the CUDA core 1 and CUDA core 2 for parallel processing.The device will send the final results back to the Host.Standard C++ compiler is used for compiling data in the host, while CUDA's own ANSI C based compiler is used for compiling in the device (GPU) coding.

A. Received Signal Strength Indicator (RSSI) Trilateration to find vehicle location.
Trilateration was used to locate a vehicle in the vicinity of three other vehicles.This was done in order to monitor the relative movement of vehicles surrounding each other to predict occurrences of abrupt evasive action such as when blind spots are encountered which leads to dangerous situations.This was accomplished by monitoring wireless signal strength.GPS was not used in this case because it cannot be used in indoor (car park) or in a sheltered operation.
The basic concept of wireless signal strength is shown Fig. 2.There are two wireless devices, as the two devices getting further apart, signal strength within the radius will be getting weaker.The measurement of the signal strength which received from the device is known as Received Signal Strength Indicator (RSSI).RSSI measures the power which received from the antenna in decibel meter (dBm).Thus, higher positive RSSI value indicators stronger signal strength.As shown in Fig. 3 above, the equation of the trilateration can be written as: www.ijacsa.thesai.org ) Where r a , r b , r c = radius of circle a, b and c x a , x b , x c , y a , y b , y c , z a , z b , z c = x, y and z of GPS coordination of circle a, b, c and d The intersection point of these three circles can be anywhere in the shaded orange area.In order to minimize the estimated error, the least square error method can be used: (2) Where Wd x ,Wd y, Wd z = weight for dx, dy, dz coordination From equation ( 2), the equation can be expanded as: By using Newton-Raphson method to find the trilateration of circle a, b and c: Where The initial root value x n+1, y n+1, z n+1 of function F is chosen arbitrarily at the beginning.Every n iteration, check the absolute value of gx, gy and gz: The algorithm will stop at n iteration if gx, gy and gz value ≤ 0.1.As gx, gy and gz get closer to 0, the estimated vehicle location gets closer to the coordinate of dx, dy and dz.

B. Bandwidth Optimization 1) Media Access Control (MAC) Address Lookup Table (LUT)
In order to implement the technique discussed previously, the ZigBee® was used to initiative data transfer from vehicle to vehicle and the WiFi network was used to transfer higher volumes of data.The Zigbee® has a lower overhead and therefore establishes the connection faster while the WiFi has a larger overhead (slower connection) but is able to handle higher amounts of data.Hence by using both in parallel we obtain a better performance.
Bandwidth optimization for the ZigBee® and WiFi systems is important because of the amount of data transfer which occurs from the surrounding vehicles at any given time.This amount adds uncertainty to the system hence optimization is needed.As this information is also processed in real time to predict dangerous situations, bandwidth optimization is a necessary part of feasibly implementing the trilateration technique discussed previously.In order to optimize the bandwidth usage for the Wi Fi, a Lookup Table (LUT) is used to map the MAC addresses of the Wi Fi router with ZigBee® coordinator and ZigBee® router.
As previously mentioned the WiFi network is used to transfer trilateration data between vehicles.Wi Fi was designed for data streaming and the maximum data streaming bandwidth from one Wi Fi device to another is up to 54 Mega bit per second (Mbps).However, establishing a connection between a Wi Fi client and a Wi Fi router connection requires some time.
As shown in Fig. 4, OpenWRT Wi Fi router is configured to be in a mesh topology.Wi Fi routers (yellow dot) can take up to 5 second to establish a single connection from the client (purple dots).It is more common to have the Wi Fi router to be fixed permanently on a particular spot, for example inside a building whereby the clients join the same Wi Fi router network.www.ijacsa.thesai.org

2) Data Transfer Optimization
The wireless distance from one device to another is directly proportional to the rate of change of data transfer.In other words, the further the distance between vehicle 1 and vehicle 2 is, the weaker the wireless signal will be.Weak wireless signal limit less data to be transmitted or received from vehicle 1 to vehicle 2.
In order to find the optimal data transmission distance between vehicle 1 and vehicle 2, data optimization method is implemented to the system.As shown in Table I, the data transmission occurs only when the Wi Fi signal strength is greater than 10%.If the signal is low, the data which has the highest priority will be transmitted.The data transfers are as follows:

C. Parallel CPU and GPU Implementation
The Parallel Central Processing Unit (CPU) and Graphic Processing Unit (GPU) improve overall system performance with greater processing speed.It is crucial to implement the parallelization threads in a proper manner.In order to obtain an optimal result with parallelism, the system is relies strongly on the combination of CPU and GPU hardware performance strength, specifically favoring different type of memories for prioritize memories sequential access [41].Currently, the limitation on CPU and GPU bandwidth become the bottleneck for hardware acceleration.There are limited bandwidth data to compute per cycle, CPU and GPU have to wait for the cycle to complete before proceeding.Compute Unified Device Architecture (CUDA), is a multithreaded GPU programming library designed by NVidia® to perform general purpose computation on a GPU.The GPU threads are executed through kernel [42].A kernel has similar function to C programming function; the only difference is that the kernel function is requested from the CPU to the GPU device.The host (CPU) will sent the matrix array of data to the device (GPU) for arithmetic calculation.The final arithmetic value is then transferred back to the host.

1) Parallel CPU and GPU Implementation
The system is implemented in two folds.As shown in Fig. 1, there are 4 tasks handled by WLAN, ZigBee®, GPS and 3G broadband.Firstly prioritize the task.Among them, both WLAN and ZigBee® have the highest priority, followed by GPS and 3G broadband.Secondly, split the tasks into multiple threads.By using -divide and conquer‖ technique, each thread is partitioned into multiple parts.At the maximum performance occupancy, each part will not have more than 512 threads. ) Lastly, the data matrix is sent to GPU for parallel calculation.Once the final answer has been obtained from the parallel GPU, it is transfer back to CPU for further processing.
Table II shows the 4 tasks implemented using Parallel CPU and GPU or Parallel CPU processing.certain time period at middle or side of the road.If so transmit the coordination to the server, the vehicle could be having an accident or break down on the road.

2) Two dimension Newton-Raphson using parallel CPU and GPU
Used in the trilateration calculation, the Newton-Raphson algorithm parallel CPU and GPU optimization steps are as follow: Radius of circle r a , r b , r c in meters = 10 (RSSI-A+Xơ)/10n (7) Where A = RSSI value of distance in 1 meters = -40dBm Xơ = Value of random noise = 0 n = path loss component value from 2 to 4.
From Equation ( 4), ( 5), ( Assume Wd x , Wd y , Wd z = 0 *Note: The initial value for x d , y d , z d were assigned randomly on the first iteration.1. Create a task through Task parallel Library (one of the .netframework 4.0 features) and name it as Task4.2. Within Task4 parallel function, check for the coordination of the GPS from nearby vehicle, if no GPS signal can be found, take the RSSI value only.3. Split the Task into two threads using Thread Building Block so that it can be parallel process using two GPU core at the same time.4. Allocate the array of 100 x 100 matrix array in GPU 5. Allocate the block and threads in GPU global memory a.
Compute the RSSI to distance value using equation ( 7 x y z z y x x y z into equation ( 4), ( 5) and ( 6) c.
Compute Inverse matrix of J from equation ( 9 iii. synchronous threads iv.move the value to Transfer the final answer of xn, yn, zn from the GPU back to CPU Compute the final coordinate xn, yn, zn of current vehicle location and transmit to other vehicle using Windows Communication Foundation (WCF).

A. Software Setup
The following software in Table VII is used to compile and implement the proposed parallel system: V2V WiFi IP address conflict reset.

Speech Recognition SDK 11.0 [33]
Based on Microsoft® OS Speech recognition

B. Hardware Setup
The system was tested on a 2.6GHz x86 Intel Centrino dual core mobile processor, with 4 Gigabytes of RAM and two NVidia® 8800M GTX GPU graphic card with Scale Link Interface (SLI) disabled.The 8800GTX consist of 768MB RAM, 6 stream multiprocessors, with each multiprocessor consist of 16 stream processors, which comes to the total of 96 stream processors.Each multiprocessor has 8192 of 32-bit registers; each multiprocessor can have up to 768 threads.Threads are partitioned into thread blocks which can consist of up to a maximum of 512 threads, and can be furthered be divided into warps of 32 threads.
The following hardware devices in

C. Trial run
As a trial run, the system was tested in an outdoor environment on a local surface road.For safety reasons the vehicle maximum speed limit was set to 60kmh.For indoor testing, the GPS setting is deactivated.The vehicle to vehicle distance estimation is based on the ZigBee® trilateration and Wi Fi signal for distance judgment.
As shown in Fig. 5, the red spot shows the current vehicle location while the green spot indicate other vehicles within 100 meters radius.With this information, the system analyzes the potentially dangerous incoming vehicles and warns the driver www.ijacsa.thesai.orgabout vehicles at blind spot, hidden corners or idle vehicle on the middle of the road.Table XII shows the results for the time taken for vehicle A to search for vehicle B within 100 meter radius.The total time taken to detect the vehicle in normal road condition has been reduced tremendously from 4.6 sec to 426 millisecond with the used of parallel CPU and GPU processing.In term of speed, it has significantly improved approximately 10 times on the system performance.

D. On road conditions 1) Scenario 1 Express way and road tunnel condition
Under normal traffic conditions, vehicles are communicating in a star topology protocol.There are two different wireless connections on each vehicle, Wi Fi and ZigBee® signal.www.ijacsa.thesai.orgWhile waiting for the Wi Fi client to link up with other vehicles, ZigBee® coordinator and ZigBee® router have established the connection and estimated the trilateration distance between vehicle to vehicle and transmit the location through ZigBee® from vehicle to vehicle.At the same time, GPS location is transmitted through Wi Fi signal.If the vehicle is in a tunnel, the GPS will not be functional.Thus, the distance estimation will rely solely on ZigBee® RSSI from one vehicle to another.

2) Scenario 2 Traffic jam condition (ZigBee® off)
In this scenario, the system will pin point the vehicle current location using GPS solely.The GPS location from one vehicle to another is transmitted through Wi Fi until it reaches 100m radius or maximum of 30 vehicles (whichever comes first) on a single hop transmission.Although the Wi Fi takes a few seconds to establish a connection with the client, it is still reasonable for the driver to wait for the time delay in a traffic congested area.

3) Scenario 3 Indoor car park condition (GPS off)
The 3 rd scenario is in an indoor car park as shown in Fig. 9. ZigBee® routers and ZigBee® coordinators from vehicle 2 to 7 remained functioning even though the vehicle engine is switch off; the RSSI data is transmitted on every second interval.The car park is normally divided into different sections.Assume there are 10 vehicles parked on both left and right row.As vehicle 1 moved towards the direction of vehicle 2 and 5, the RSSI from vehicle 2 to 7 is received by the ZigBee® router of vehicle 1.The estimated error is ±3 meters, which is approximately 2 vehicle space.The results in Table XII have shown that, by using parallel CPU and GPU, the time taken can be decreased up to 10 times of normal CPU alone implementations without parallel processing.However the results can further be improved when better hardware CPU and GPU options (in terms of performance per cost) become available.In comparison to other related work in the domain our results in Table XIV shows that the techniques implemented here are lower costs using lower power but with higher or similar speed performance.
Looking forward, the next objective is to port the current system to a mobile device such as a multi core OS hand phone.This porting will further reduce the cost and at the same no additional processing hardware is required other than the mobile phone.The total cost can further be reduced and the design can have much lower power consumption in order to achieve the same performance as the system discussed here.www.ijacsa.thesai.org

Figure 2 .
Figure 2. Received Signal Strength Based on the signal strength, there are 3 common methods to measure the distance between two points: Received Signal Strength Indicator (RSSI), Time of Arrival (TOA) and Angle Of Arrival (AOA).The simplest and cheapest method is the Received Signal Strength (RSS) method as it doesn't required additional hardware.As shown in Fig. 3, in order to estimate a location, at least three wireless devices were needed to triangulate the position of the 4th wireless device.There are three wireless devices, a, b and c.Wireless device d is within the intersection of a, b and c.The coordination of a, b and c can be obtained from either the Wi Fi or a fix point ZigBee® router from the vehicle.

Figure 4 .
Figure 4. Wi Fi router and Wi Fi Clients In this V2V communication system, there are 5 devices: GPS, ZigBee® coordinator, ZigBee® router, Wi Fi client and Wi Fi router.Each device of every vehicle has a unique MAC address and the same MAC address cannot be repeated.Based on the Wi Fi 802.11 standards [40] Wi Fi MAC address can be obtained whenever the Wi Fi wireless signal is transmitted.The signal contains information on the Network Type, Authentication, Encryption and Basic Set Service Set Identification (BSSID).BBSID has divided into 5 sections: wireless MAC address, Signal Strength, Signal Type and Data Transfer rate represented in Mega bit per second (Mbps).The Wi Fi router wireless MAC address format is as follow: CC: XX: XX: XX: XX: XX CC = country code from 00-FF (Hexadecimal), representing 256 different countries based on a unique country code ID store on the server.XX = Wi Fi MAC address (expressed in 2 bytes Hexadecimal from 00 -FF) Since the Wi Fi router's MAC address is unique for each vehicle, the following LUT is generated: CC: XX: XX: XX: XX: XX, YY: YY: YY: YY: YY: YY: YY: YY, ZZ: ZZ: ZZ: ZZ: ZZ: ZZ: ZZ: ZZ Where YY= ZigBee® coordinator MAC address ZZ= ZigBee® router (node) MAC address

1 .
Transmit the GPS coordination for maximum of 5 vehicle within 20 meters Wi Fi range 2. Scan for MAC address of ZigBee® coordinator and router of any vehicle nearby, once it found, linked up all the nodes together so that data can be transferred from one vehicle to another.Scanning stop when it reaches 10 vehicles or GPS coordination with Wi Fi radius of 40 meters (whichever comes first).3. Scan and established the coordination between Wi Fi and ZigBee®, for any nearby vehicle.Stop scanning after it reaches 20 vehicles or Wi Fi range of 60 meters (whichever comes first) 4. Scan and established the connection of up to 25 vehicles up to 80 meters Wi Fi radius.Scan and established the connection of up to 30 vehicles up to 100 meters Wi Fi radius www.ijacsa.thesai.org( , , ) ) www.ijacsa.thesai.org ) d. Allocate the share memory 10x10x10 of GPU: shared_memory[threadIdx.x][threadIdx.y][threadIdx.
i. Check weather is it the first time running the While loop, if so take the initial value of Step e) or else skip step i and proceed straight to step ii.ii.shared_memory[threadIdx.x][thread Idx.y][threadIdx.z]= Compute the equation (10) using

Fig. 6
Fig.6 and 7shows the data transfer rate against distance for Wi Fi and RSSI against distance for ZigBee® signal respectively.The experimental results were obtained within line of sight of two vehicles on an express way during the test drive.The Wi Fi transfer rate from Vehicle 1 Wi Fi client to Vehicle 2 Wi Fi router is directly proportional to the distance.As for the ZigBee® router on vehicle 1 and 2, the data transfer rate remains consistent at 250Kbps as wireless signal strength directly proportional to the distance.

Fig. 8
Fig. 8 shows how the communication of Vehicle 1 to 5 is established on normal express way.Each vehicle is linked up to 30 vehicles either on a single hop Wi Fi router to Wi Fi client communication or Wi Fi router to Wi Fi router multi hop communication.

Figure 8 .
Figure 8. V2V -Normal condition Table XIII shows how V2V communicate with each other on a road.From Fig. 8, Vehicle ID=1 communicates with the other vehicle ID=2, 3, 4 and 5, vehicle ID=2 communicates with vehicle ID=1, 3, 4 and 5 in a star topology.Similarly for vehicle ID=3, Vehicle ID = 4 and Vehicle ID = 5.

Figure 9 .
Figure 9. V2V -Indoor car park VI.CONCLUSIONSThis paper has presented an efficient V2V communication implementation for driver safety by implementing the following methods: 1) Using a variety of real time V2V wireless communication protocols in different circumstances that optimizes performance, and 2) utilizing parallel CPU and GPU processing to accommodate real time processing of massive amounts of data.The methods implemented here are an improvement on past solutions due to the lower cost and lower power consumption of the proposed system without sacrificing performance.

TABLE I .
WI FI SIGNAL STRENGTH

TABLE II .
PARALLEL TASK DISTRIBUTION Create a task and name it as Task1 using Task parallel Library (one of the .netframework 4.0 features) 2. Search nearby vehicle Wi Fi router for BSSI wireless MAC address, if different BSSI wireless MAC address is found, go to step 3, else go to step 8. 3. Allocate the matrix array in GPU device 4. Store the WiFi MAC and LUT to global kernel of the GPU 5. Compare the WiFi MAC to match the LUT 6.Once a match is found, transfer the match back to CPU host.If not, continue with Step 6.If no match is found, go to Step 2. 7. Connect the wireless client based on the match, check for wireless data transfer optimization algorithm to optimize the data transfer bandwidth.If the WiFi router is further than 100 meters radius, release the IP for the next vehicle.If any IP address collision, reconfigure a new IP address.8. Go back to step 2.

TABLE VII . SOFTWARE SETUP Software Methodology/Algorithms used in this research CUDA 4.1 [28]
Table VIII used in this work are:

TABLE VIII .
HARDWARE SETUP

Table X and
Table XI are the RSSI value on a field test within line of sight.The error rate for Wi Fi Packet Error rate is within 10%.A 5dBi and 2dBi omnidirectional is used for Wi Fi and ZigBee® devices.The test results have shown that the trilateration range estimation for ZigBee® is within ±3 meters tolerance.

TABLE XI
*Maximum ZigBee® Node to node enumeration = 30ms

TABLE XIV .
COST AND PERFORMANCE COMPARISON