chrono::vehicle::ChDriverSTR Class Reference

## Description

Base class for a suspension test rig driver system.

A driver system must be able to report the current values of the inputs (left post, right post, steering). A concrete driver class must set the member variables m_displacementLeft, m_displacementRight, m_steering, and - if possible - the rates of change for the displacements (otherwise left at their default value of 0).

#include <ChDriverSTR.h>

Inheritance diagram for chrono::vehicle::ChDriverSTR:

## Public Member Functions

double GetDisplacementLeft () const
Get the left post vertical displacement (in the range [-1,+1])

double GetDisplacementRight () const
Get the right post vertical displacement (in the range [-1,+1])

double GetDisplacementSpeedLeft () const
Get the left post displacement rate of change.

double GetDisplacementSpeedRight () const
Get the right post displacement rate of change.

double GetSteering () const
Get the driver steering input (in the range [-1,+1])

bool Started () const
Return false while driver inputs are ignored (while the rig is reaching the ride height configuration) and true otherwise. More...

virtual bool Ended () const
Return true when driver stopped producing inputs.

Initialize output file for recording driver inputs.

bool Log (double time)
Record the current driver inputs to the log file.

## Protected Member Functions

virtual void Initialize ()
Initialize this driver system.

virtual void Synchronize (double time)
Update the state of this driver system at the current time.

void SetDisplacementLeft (double val, double min_val=-1, double max_val=1)
Set the value for the driver left post displacement input.

void SetDisplacementRight (double val, double min_val=-1, double max_val=1)
Set the value for the driver right post displacement input.

void SetSteering (double val, double min_val=-1, double max_val=1)
Set the value for the driver steering input.

## Protected Attributes

double m_displLeft
current value of left post displacement

double m_displRight
current value of right post displacement

double m_displSpeedLeft
current value of left post displacement rate of change

double m_displSpeedRight
current value of right post displacement rate of change

double m_steering
current value of steering input

double m_delay
time delay before generating inputs

## Friends

class ChSuspensionTestRig

## ◆ Started()

 bool chrono::vehicle::ChDriverSTR::Started ( ) const

Return false while driver inputs are ignored (while the rig is reaching the ride height configuration) and true otherwise.

In general, outputs from the test rig should only be collected while Started returns true.

The documentation for this class was generated from the following files:
• /builds/uwsbel/chrono/src/chrono_vehicle/wheeled_vehicle/test_rig/ChDriverSTR.h
• /builds/uwsbel/chrono/src/chrono_vehicle/wheeled_vehicle/test_rig/ChDriverSTR.cpp