Acceleration and Braking
Libraries:
Vehicle Dynamics Blockset /
Vehicle Scenarios /
Drive Cycle and Maneuvers
Description
The Acceleration and Braking block generates a straight reference trajectory as a function of longitudinal displacement or time. Initial reference acceleration and deceleration are tunable. Once the target longitudinal velocity is achieved, the block executes a deceleration signal. This deceleration signal can be executed either with specified time or longitudinal displacement.
An additional option for fault tracking allows you to monitor the uniformity of parameters just before braking. The default set values are upper bounds for the standard split-mu test (ISO Standard 141512).
Note
For information on the reference generator block used in the braking test reference application, see Straight Maneuver Reference Generator.
Ports
Input
Vehicle longitudinal velocity in the body fixed frame, specified as a scalar, in m/s.
Data Types: double
Vehicle yaw rate, specified as a scalar, in rad/s.
Dependencies
To enable this parameter, select Enable fault tracking before braking.
Data Types: double
Vehicle handwheel angle, specified as a scalar, in rad.
Dependencies
To enable this parameter, select Enable fault tracking before braking.
Data Types: double
Output
Driver reference data, returned as a bus containing these block values.
Signal | Description | Units |
---|---|---|
| Longitudinal reference velocity | m/s |
| Lateral reference displacement | m |
| Vehicle global longitudinal reference position | m |
| Vehicle global lateral reference position | m |
| Vehicle global yaw reference position | rad |
| Reference path curvature | 1/m |
| Reference path curvature gradient | 1/m^2 |
Data Types: bus
Driver reference data, returned as a bus containing these block values.
Signal | Description | Units | |
---|---|---|---|
|
| Boolean signal used to override driver model steering commands | one |
| Handwheel angle | one | |
| Boolean signal used to override driver model steering commands
with zero when value is | one | |
| Boolean signal used to hold the current driver model steering
output when | one | |
|
| Boolean signal used to override driver model acceleration commands | one |
| Normalized accelerator input | one | |
| Boolean signal used to hold the current driver model acceleration
output when | one | |
| Boolean signal used to override driver model acceleration
commands with zero when value is | one | |
|
| Boolean signal used to override driver model deceleration commands | one |
| Normalized decelerator or brake input. | one | |
| Boolean signal used to hold the current driver model deceleration
output when | one | |
| Boolean signal used to override driver model deceleration
commands with zero when value is | one | |
| Normalized handbrake or park brake input | one | |
|
| Command to specify the transmission mode | one |
| Command to specify manual gear number or automatic transmission shifter position | one | |
| Command to upshift | one | |
| Command to downshift | one | |
| Normalized clutch open command for manual transmissions | one |
Note
By default, the TransCmd
bus is not actively used. Use a
Bus Assignment block to override the
TransCmd
bus to customize and extend the scenario.
Data Types: bus
Parameters
To edit block parameters interactively, use the Property Inspector. From the Simulink® Toolstrip, on the Simulation tab, in the Prepare gallery, select Property Inspector.
Maneuver Parameters
Longitudinal acceleration at the simulation start time, tStart, in m/s^2.
Programmatic Use
To set the block parameter value programmatically, use
the set_param
function.
To get the block parameter value
programmatically, use the get_param
function.
Parameter: | ax |
Values: | 0.5 (default) | positive scalar |
Data Types: | double |
Method to start deceleration. To specify a time to start decelerating the vehicle,
select Time
. To specify a displacement to start decelerating the
vehicle, select Longitudinal displacement
.
Programmatic Use
To set the block parameter value programmatically, use
the set_param
function.
To get the block parameter value
programmatically, use the get_param
function.
Parameter: | brakingType |
Values: | Time (default) | Longitudinal displacement |
Data Types: | character vector |
Simulation time when braking is initiated, in s.
Dependencies
To enable this parameter, set Brake pedal actuation to
Time
.
Programmatic Use
To set the block parameter value programmatically, use
the set_param
function.
To get the block parameter value
programmatically, use the get_param
function.
Parameter: | tBrake |
Values: | 15 (default) | positive scalar |
Data Types: | double |
The longitudinal displacement of the vehicle when braking is initiated, in m.
Dependencies
To enable this parameter, set Brake pedal actuation to
Longitudinal displacement
.
Programmatic Use
To set the block parameter value programmatically, use
the set_param
function.
To get the block parameter value
programmatically, use the get_param
function.
Parameter: | xBrake |
Values: | 200 (default) | positive scalar |
Data Types: | double |
Select this parameter to set the handwheel angle to zero degrees after braking.
Programmatic Use
To set the block parameter value programmatically, use
the set_param
function.
To get the block parameter value
programmatically, use the get_param
function.
Parameter: | steerZero |
Values: | on (default) | off |
Data Types: | character vector |
Tracking Parameters
Select this parameter to enable fault tracking before braking.
Programmatic Use
To set the block parameter value programmatically, use
the set_param
function.
To get the block parameter value
programmatically, use the get_param
function.
Parameter: | faultTracking |
Values: | off (default) | on |
Data Types: | character vector |
Transport delay buffer size. This parameter is used for the online diagnostic calculations. Use the simulation step size or hardware memory availability to specify the buffer size.
Dependencies
To enable this parameter, select Enable fault tracking before braking.
Programmatic Use
To set the block parameter value programmatically, use
the set_param
function.
To get the block parameter value
programmatically, use the get_param
function.
Parameter: | bufferSize |
Values: | 4096 (default) | positive scalar |
Data Types: | double |
Maximum allowable difference between the longitudinal velocity and the mean longitudinal velocity during the eight-second time interval prior to when braking is initiated, in m/s.
Set value to comply with ISO 14512 for braking on surfaces with split coefficient of friction.
Dependencies
To enable this parameter, select Enable fault tracking before braking.
Programmatic Use
To set the block parameter value programmatically, use
the set_param
function.
To get the block parameter value
programmatically, use the get_param
function.
Parameter: | velMaxDiff |
Values: | 1 (default) | positive scalar |
Data Types: | double |
Maximum allowable difference between the mean longitudinal velocity and longitudinal velocity reference during the eight-second time interval prior to when braking is initiated, in m/s.
Set value to comply with ISO 14512 for braking on surfaces with split coefficient of friction.
Dependencies
To enable this parameter, select Enable fault tracking before braking.
Programmatic Use
To set the block parameter value programmatically, use
the set_param
function.
To get the block parameter value
programmatically, use the get_param
function.
Parameter: | velMeanDiff |
Values: | 2 (default) | positive scalar |
Data Types: | double |
Maximum allowable difference between the yaw velocity and mean yaw velocity during the eight-second time interval prior to when braking is initiated, in deg/s.
Set value to comply with ISO 14512 for braking on surfaces with split coefficient of friction.
Dependencies
To enable this parameter, select Enable fault tracking before braking.
Programmatic Use
To set the block parameter value programmatically, use
the set_param
function.
To get the block parameter value
programmatically, use the get_param
function.
Parameter: | rMaxDiff |
Values: | 1 (default) | positive scalar |
Data Types: | double |
Maximum allowable difference between the handwheel angle and the mean handwheel angle during the eight-second time interval prior to when braking is initiated, in deg.
Set value to comply with ISO 14512 for braking on surfaces with split coefficient of friction.
Dependencies
To enable this parameter, select Enable fault tracking before braking.
Programmatic Use
To set the block parameter value programmatically, use
the set_param
function.
To get the block parameter value
programmatically, use the get_param
function.
Parameter: | steerMaxDiff |
Values: | 3 (default) | positive scalar |
Data Types: | double |
Select this parameter to stop simulation when fault occurs.
Dependencies
To enable this parameter, select Enable fault tracking before braking.
Programmatic Use
To set the block parameter value programmatically, use
the set_param
function.
To get the block parameter value
programmatically, use the get_param
function.
Parameter: | stopOnFault |
Values: | off (default) | on |
Data Types: | character vector |
Extended Capabilities
C/C++ Code Generation
Generate C and C++ code using Simulink® Coder™.
Version History
Introduced in R2024b
See Also
MATLAB Command
You clicked a link that corresponds to this MATLAB command:
Run the command by entering it in the MATLAB Command Window. Web browsers do not support MATLAB commands.
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
- América Latina (Español)
- Canada (English)
- United States (English)
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)