21 #ifndef MSDevice_DriverState_h 22 #define MSDevice_DriverState_h 104 return "driverstate";
111 void setParameter(
const std::string& key,
const std::string& value);
122 double initialAwareness,
123 double errorTimeScaleCoefficient,
124 double errorNoiseIntensityCoefficient,
125 double speedDifferenceErrorCoefficient,
126 double speedDifferenceChangePerceptionThreshold,
127 double headwayChangePerceptionThreshold,
128 double headwayErrorCoefficient,
129 double maximalReactionTime);
void update()
update internal state
Representation of a vehicle in the micro simulation.
double mySpeedDifferenceChangePerceptionThreshold
static void insertOptions(OptionsCont &oc)
Inserts MSDevice_DriverState-options.
std::string getParameter(const std::string &key) const
try to retrieve the given parameter from this device. Throw exception for unsupported key ...
double myInitialAwareness
MSDevice_DriverState & operator=(const MSDevice_DriverState &)
Invalidated assignment operator.
static double getErrorNoiseIntensityCoefficient(const SUMOVehicle &v, const OptionsCont &oc)
double myMaximalReactionTime
static double getInitialAwareness(const SUMOVehicle &v, const OptionsCont &oc)
static double getSpeedDifferenceErrorCoefficient(const SUMOVehicle &v, const OptionsCont &oc)
static double getMaximalReactionTime(const SUMOVehicle &v, const OptionsCont &oc)
static double getHeadwayErrorCoefficient(const SUMOVehicle &v, const OptionsCont &oc)
Representation of a vehicle.
std::shared_ptr< MSSimpleDriverState > myDriverState
The driver state of the holder.
void setParameter(const std::string &key, const std::string &value)
try to set the given parameter for this device. Throw exception for unsupported key ...
double myErrorNoiseIntensityCoefficient
static double getMinAwareness(const SUMOVehicle &v, const OptionsCont &oc)
std::shared_ptr< MSSimpleDriverState > getDriverState() const
return internal state
static double getErrorTimeScaleCoefficient(const SUMOVehicle &v, const OptionsCont &oc)
static void buildVehicleDevices(SUMOVehicle &v, std::vector< MSVehicleDevice *> &into)
Build devices for the given vehicle, if needed.
MSVehicle * myHolderMS
The holder vehicle casted to MSVehicle*.
~MSDevice_DriverState()
Destructor.
A storage for options typed value containers)
void initDriverState()
Initializeses the driver state parameters.
Abstract in-vehicle device.
static double getHeadwayChangePerceptionThreshold(const SUMOVehicle &v, const OptionsCont &oc)
double mySpeedDifferenceErrorCoefficient
double myHeadwayErrorCoefficient
double myHeadwayChangePerceptionThreshold
The ToC Device controls transition of control between automated and manual driving.
MSDevice_DriverState(SUMOVehicle &holder, const std::string &id, double minAwareness, double initialAwareness, double errorTimeScaleCoefficient, double errorNoiseIntensityCoefficient, double speedDifferenceErrorCoefficient, double speedDifferenceChangePerceptionThreshold, double headwayChangePerceptionThreshold, double headwayErrorCoefficient, double maximalReactionTime)
Constructor.
Provides an interface to an error whose fluctuation is controlled via the driver's 'awareness'...
double myErrorTimeScaleCoefficient
static double getSpeedDifferenceChangePerceptionThreshold(const SUMOVehicle &v, const OptionsCont &oc)
const std::string deviceName() const
return the name for this type of device