Automotive ABS Model Overview Figure 1. Automotive ABS Functional Diagram. Introduction This model investigates the effects of vehicle velocity, wheel friction coefficient, wheel sensor processing, critical engine task processing, bus contention, and engine control unit processing of wheel sensor, critical engine tasks on an Automotive ABS System. In addition, it allows for human response time to determine overall braking distance. The model plots a histogram of the stopping distances, a timed plot of bus transactions, and a timed plot of wheel sensor latencies through the system. The model could easily be expanded. The development of this model in VisualSim is shown in this ABS-Automotive Example Page. ABS Performance Model Braking distance has three components. The first is the distance covered by the vehicle during the driver s reaction time. The second is the actual braking distance of the vehicle. Automotive Model of ABS System Page 1 of 13 8/7/004
The third is the availability of the Electronic Control Unit for processing brake signals. There are several ways to calculate the braking distance. We will show two approaches. The techniques described here have been reference to A Benchmark for Control of Antilock Braking Systems. The first approach: using the equations of motions from mechanics/kinematics: 1 x = x0 + v0 t+ a t v v v = v0 + a t => t = a We replace the time from the second equation in the first: 0 v 0 v v0 1 v v0 x = v0 + a a a vv0 v0 v vv0 + v0 x = + a a a x= (vv v ) + v vv + v ( ) 0 0 0 0 x = v v 0 v = v + a x 0 v = v + a( x x ) 0 f 0 In our case and x are zero (0) and the equation for the braking distance will be after replacing x with d: v0 d = a The sum of forces acting on the car is equal with the mass and acceleration product: F = ma It results: friction net F = µ N = µ mg F net = F friction ma = mµ g => a = µ g Replacing the calculated acceleration in the braking distance equation yields: Automotive Model of ABS System Page of 13 8/7/004
v0 v0 d = = a µ g The second approach: using the kinetic energy approach: Kinetic Energy = Work done by the Brakes KE = 1 mv Work done by the Brakes = - braking force * distance = adm, Where: m=mass, a=deceleration, d=distance, v0=initial velocity 1 1 v0 adm = mv0 => ad = v0 => d = a Discussion v0 v0 From this last formula: d = a = µ g, we can calculate stopping distances with various decelerations levels. The deceleration a = gµ where µ is the friction coefficient. Using this formula we can calculate different decelerations based on different friction coefficients i.e. for dry and wet roads. The difference between the coefficient of static friction µ and the coefficient of kinetic (dynamic) friction µ k makes the difference between ABS and normal brakes where the wheels lock: d d d non ABS = d with ABS = v0 µ g k v0 µ g v0 µ g µ = = with ABS s k non ABS v0 µ s µ g In general, the static friction coefficient is bigger than the kinetic friction coefficient, which renders the above fraction less than one (1). This means the cars with ABS where the wheels do not lock (and static friction coefficient is used) stop in less distance than k s s Automotive Model of ABS System Page 3 of 13 8/7/004
the cars with normal brakes where the wheels lock (and kinetic friction coefficient is used). Automotive Model of ABS System Page 4 of 13 8/7/004
Figure. Automotive ABS Model, Top Level View. Model Overview The Automotive ABS Model has five top level parameters: Speed_MPH Friction_Coefficient Number_of_Stops Engine_Speed_RPM Sim_Time The Speed_MPH is the straight-ahead speed of the vehicle, used in determining the stopping distance. The vehicle velocity influences the stopping distance as a squared term. The Friction_Coefficient is the coefficient for the type of driving surface. The text annotation of the model shows the typical friction coefficients: Dry Asphalt 0.80 to 1.00 Wet Asphalt 0.55 to 0.70 Snow... 0.8 to 0.30 Ice... 0.08 to 0.10 The user can set any friction coefficient (0.0 to 1.0) for a simulation to see the effect on stopping distance. The Number_of_Stops is the number of wheel samples collected, in sets of four, during the simulation. The model collects four wheel sensor events, and computes the stopping distance on the fly, not actually taking the time to stop during the simulation. If one increases the Number_of_Stops, and the model does not indicate "Model_Complete...", then this means the Sim_Time parameter must be increased. Automotive Model of ABS System Page 5 of 13 8/7/004
The Engine_Speed_RPM parameter is used in the Critical Engine Tasks block to determine how many engine events will be sent to the Engine Control Unit. The user must estimate the engine RPMs based on the vehicle Speed_MPH parameter. The Engine_Speed_RPM effects the number of engine events and in turn the number of bus transactions. As the number of bus transactions increase, the potential for bus contention increases, resulting in increased transaction delays for all bus transactions at those instances. The Wheel Transaction Latencies plot, to be discussed later, shows this effect. Engine Control Unit processing is event driven by the wheel sensor block and the critical engine tasks block. The wheel sensor block runs on four separate threads, one for each wheel, generating an ECU destined event every wheel revolution, based on the top level Speed_MPH parameter. Each data structure generated by each wheel also sets the current simulation time into the Data Structure header TIME field, used to calculate the wheel transaction latencies in the ECU block. The wheel sensor ucode is listed below: DEF DS_Out block 1553_DS ; DEF Text_Out block "str" ; DEF Wheel_Speed block 0.0 ; DEF Wheel_Time block 0.0 ; ACT Trace = false ; ACT Wheel_Speed = Speed_MPH * 1.466666667 ; ACT Wheel_Speed /= 4.97419 ; ACT Wheel_Time = 1.0 / Wheel_Speed ; ACT input wait ; ACT Text_Out = Input_Queue ; ACT DS_Out.ID = 3 ; ACT DS_Out.Transaction_Bytes = irand(, 3) ; ACT DS_Out.User_Message = "wheel" ; GTO "B_Thread" thread Wheel_ ; GTO "C_Thread" thread Wheel_3 ; GTO "D_Thread" thread Wheel_4 ; LBL Wheel_1 ; ACT Wheel_Time wait ; ACT DS_Out.TIME = TNow ; ACT output send DS_Out ; GTO Wheel_1 ; LBL Wheel_ ; ACT Wheel_Time wait ; ACT DS_Out.TIME = TNow ; ACT output send DS_Out ; GTO Wheel_ ; LBL Wheel_3 ; ACT Wheel_Time wait ; ACT DS_Out.TIME = TNow ; ACT output send DS_Out ; GTO Wheel_3 ; LBL Wheel_4 ; ACT Wheel_Time wait ; ACT DS_Out.TIME = TNow ; ACT output send DS_Out ; GTO Wheel_4 ; Automotive Model of ABS System Page 6 of 13 8/7/004
The engine tasks block is similar to the wheel sensor block, except that there is only a single thread for all of the cylinder fire events. The cylinders fire at a rate based on the Speed_MPH and Engine_Speed_RPM parameter settings. The engine task ucode consists of 14 lines of code: DEF DS_Out block 1553_DS ; DEF Text_Out block "str" ; DEF Engine_Speed block 0.0 ; ACT Trace = false ; ACT Engine_Speed = ((1.0 / ((Engine_Speed_RPM * 8.0) / 60.0))) ; ACT input wait ; ACT Text_Out = Input_Queue ; ACT DS_Out.ID = 1 ; ACT DS_Out.User_Message = "engine" ; LBL Fire_Cylinder ; ACT Engine_Speed wait ; ACT DS_Out.Transaction_Bytes = irand(,3) ; ACT output send DS_Out ; GTO Fire_Cylinder ; The ECU block accepts the Data Structures generated by the wheel sensor block and engine critical tasks block. It processes the tasks based on the 1553 bus Data Structure field, named User_Message. For the wheel sensor block, this field is set to wheel and for the engine critical tasks block this is set to engine. The ECU block looks for the wheel User_Message fields, and waits for four wheel Data Structures to compute a stopping distance. If the ECU block detects an engine task then it uses several hundred processor cycles to process the engine firing of the cylinder. If a wheel event comes in at the same time, then it must wait for the engine critical tasks to be completed before continuing. The ECU block calculates the stopping distance in a single expression, and also calculates the transaction latency in a single expression. In addition, the ECU block could be expanded to perform additional tasks. Once, the ECU block has performed the Number_Of_Stops parameter setting, and then the ECU sends a message to the modelbased shell block: "Model_Complete..." Automotive Model of ABS System Page 7 of 13 8/7/004
The Engine Control Unit ucode consists of 43 lines of code: DEF DS_In block 1553_DS ; DEF User_Reaction block 0.0 ; DEF Proc_Speed global extern ; DEF Wheel_Velocity global 0.0 ; DEF Proc_Delay block 0.0 ; DEF Brake_Delay block 0.0 ; DEF Brake_Distance block 0.0 ; DEF User_Speed_Min global extern ; DEF User_Speed_Max global extern ; DEF Brake_Count block 0 ; DEF Brake_Samples block 0 ; ACT Trace = false ; ACT Wheel_Velocity = Speed_MPH * 1.466666667 ; LBL ECU_Processing ; ACT input wait ; ACT DS_In = Input_Queue ; JIT DS_In.User_Message == "engine" Process_Task ; JIF Brake_Count == 0 + ; ACT Brake_Delay = TNow ; ACT Brake_Count ++ ; JIF Brake_Count >= 4 ECU_Processing ; ACT User_Reaction = rand(user_speed_min,user_speed_max) ; ACT Brake_Delay = TNow - Brake_Delay ; ACT User_Reaction += Brake_Delay ; ACT Brake_Distance = Wheel_Velocity * User_Reaction ; ACT Brake_Delay = ((Wheel_Velocity * Wheel_Velocity) / (.0 * Friction_Coefficient*3.0)); ACT Brake_Distance += Brake_Delay ; LBL Ready_to_Stop ; ACT output send Brake_Distance ; ACT latency send TNow - DS_In.TIME ; ACT Brake_Count = 0 ; ACT Brake_Samples ++ ; JIT Brake_Samples >= Number_of_Stops + ; GTO ECU_Processing ; ACT X send "Model_Complete..." ; ACT input wait ; ACT DS_In = Input_Queue ; GTO - ; LBL Process_Task ; ACT Proc_Delay = Proc_Speed * 500.0 ; ACT Proc_Delay wait ; GTO ECU_Processing ; Automotive Model of ABS System Page 8 of 13 8/7/004
1553 Bus Model Figure 3. 1553 Bus Port, or Remote Terminal. The 1553 Bus Port queues incoming bus transactions, and requests a grant from the bus controller, see below. Figure 4. 1553 Bus Controller. Automotive Model of ABS System Page 9 of 13 8/7/004
The 1553 Bus Controller grants requests on a first-come-first-serve basis. Model Results The Automotive ABS Model generates a message window, model-based interactive shell, three performance plots. The Message Window output: Welcome to ABS Automotive Model Select a Processor based on Speed, Power, Cost Select a User Reaction Time Model Running... Model Complete... The model-based interactive shell output/input: (a) 33 Mhz Proc, 0 mw, $.00 (b) 10 Mhz Proc, 30mW, $1.00: Enter a or b >> a (a) Fast, 5 to 10 msec (b) Average, 10 to 30 msec (c) Slow, 30 to 100 msec Enter a, b, c >> c Figure 5. ABS Braking Distance Histogram. Figure 5 represents 100 stops with the same simulator settings. The range of distances are influenced primarily by the user reaction times and to a much smaller extent the internal bus, ECU processing times. The user reaction time was selected to be a uniformly distributed variable and this plot shows the influence of this distribution. Automotive Model of ABS System Page 10 of 13 8/7/004
Figure 6. ABS Bus Transactions. Figure 6 shows engine critical tasks (multiple red events with ID = 1) and wheel tasks (multiple red events with ID = 3). One can observe that the wheel tasks occur less frequently than the engine tasks and that the events are very regular. This is consistent with the model functionality. This plot is used to verify that the model is performing as expected, more than obtaining detailed performance information. Figure 7. ABS Wheel Sensor Transaction Latencies. Automotive Model of ABS System Page 11 of 13 8/7/004
Figure 7 plots wheel sensor transaction latencies that include the time processed through the bus and ECU blocks. The spike values indicate that the wheel sensor transactions encountered contention on the bus at periodic times. This is consistent with the engine critical transactions and the wheel sensor transactions being generated at different constant rates. At predictable times, the two transaction streams try to transmit through the bus, causing contention; and in the ECU block, engine tasks consume processor cycles, causing wheel sensor transactions to wait. Other Model Variations One can modify the ABS Model parameters to see the effect on the results. Some examples: Decrease the Friction Coefficient and the Braking distance increases proportionately. Increase the Speed_MPH and the Braking distance increases at the square of the velocity. Reduce the Human Reaction time, and the Braking Histogram becomes tighter. Change the Engine_RPM, and the Wheel Sensor Transaction Latencies will spike at different times. Change the processor speed, and the Braking Distance is not visibly affected in the plots. ABS Terminology * ABS - Anti-Lock Braking System. * ABS Actuator - The work horse of the ABS system, it releases pressure in the ABS channel to modulate the brakes. * ABS Channel - The channel is the hydraulic line(s) from the ABS actuator to the wheel(s). ABS channel can consist of 1 or wheels that will pulse/modulate when the ABS actuator performs its work. * ABS Sensor - Measures the speed of a wheel. Consists of gear-shaped sensor rotor and a sensor element. The element contains a bar magnet around which a coil is wound. The sensor is installed on the back side of the brake rotor. Sine-wave current is generated by the sensor as the wheel rotates. The frequency and voltage increase(s) as the rotating speed increases. * ABS Pulse or modulation - When the ABS Actuator engages and pulses/modulates the brake pressure being applied to the ABS channel. This is the method by which the system actually works. When the brakes pulse, they are prevented from locking because they rotate for a split second. ABS Types * 1 or Channel -wheel (Rear ABS) - This ABS is usually prevalent on trucks. It consists of ABS sensors on the rear wheels and one or two ABS channels to pulse the rear wheel together (1 channel) or separately ( channels). * Channel 4-wheel Criss-cross - This is the ABS system present on the 91-94 Sentra. It consists of 4 ABS sensors (one on each wheel) and ABS channels arranged in a Automotive Model of ABS System Page 1 of 13 8/7/004
Criss-cross (Left Front & Right Rear, Right Front & Left Rear). When the right rear wheel locks up, the left front wheel & right rear wheel are pulsed together. * 3 Channel 4-wheel - This is the more common ABS system in cars. It consists of 4 wheel sensors and channels in the front (LF, RF) and one channel for the rear wheels. When one of the front wheels locks up, it pulses independently of the other wheels. When one of the rear wheels locks up, it is pulsed together with the other rear wheel, similar to a very fast pulling and releasing of the emergency brake. * 4 Channel 4-wheel - This is the ABS system present on the 95+ 00SX/Sentra. It consists of 4 ABS sensors and 4 ABS channels. All wheels pulse independently of each other, like it should be. Automotive Model of ABS System Page 13 of 13 8/7/004