102 return "driverstate";
109 void setParameter(
const std::string& key,
const std::string& value);
120 double initialAwareness,
121 double errorTimeScaleCoefficient,
122 double errorNoiseIntensityCoefficient,
123 double speedDifferenceErrorCoefficient,
124 double speedDifferenceChangePerceptionThreshold,
125 double headwayChangePerceptionThreshold,
126 double headwayErrorCoefficient,
127 double freeSpeedErrorCoefficient,
128 double maximalReactionTime);
The ToC Device controls transition of control between automated and manual driving.
std::shared_ptr< MSSimpleDriverState > getDriverState() const
return internal state
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*.
double myErrorTimeScaleCoefficient
static double getSpeedDifferenceChangePerceptionThreshold(const SUMOVehicle &v, const OptionsCont &oc)
static void insertOptions(OptionsCont &oc)
Inserts MSDevice_DriverState-options.
MSDevice_DriverState(const MSDevice_DriverState &)
Invalidated copy constructor.
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 freeSpeedErrorCoefficient, double maximalReactionTime)
Constructor.
static double getErrorTimeScaleCoefficient(const SUMOVehicle &v, const OptionsCont &oc)
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 getHeadwayErrorCoefficient(const SUMOVehicle &v, const OptionsCont &oc)
const std::string deviceName() const
return the name for this type of device
void initDriverState()
Initializeses the driver state parameters.
double myFreeSpeedErrorCoefficient
~MSDevice_DriverState()
Destructor.
static double getSpeedDifferenceErrorCoefficient(const SUMOVehicle &v, const OptionsCont &oc)
static double getFreeSpeedErrorCoefficient(const SUMOVehicle &v, const OptionsCont &oc)
double myHeadwayChangePerceptionThreshold
static double getMaximalReactionTime(const SUMOVehicle &v, const OptionsCont &oc)
double myMaximalReactionTime
double mySpeedDifferenceChangePerceptionThreshold
std::shared_ptr< MSSimpleDriverState > myDriverState
The driver state of the holder.
std::string getParameter(const std::string &key) const
try to retrieve the given parameter from this device. Throw exception for unsupported key
static double getMinAwareness(const SUMOVehicle &v, const OptionsCont &oc)
void update()
update internal state
static double getHeadwayChangePerceptionThreshold(const SUMOVehicle &v, const OptionsCont &oc)
double myHeadwayErrorCoefficient
static double getErrorNoiseIntensityCoefficient(const SUMOVehicle &v, const OptionsCont &oc)
static double getInitialAwareness(const SUMOVehicle &v, const OptionsCont &oc)
double myInitialAwareness
MSDevice_DriverState & operator=(const MSDevice_DriverState &)
Invalidated assignment operator.
double mySpeedDifferenceErrorCoefficient
Provides an interface to an error whose fluctuation is controlled via the driver's 'awareness',...
Abstract in-vehicle device.
Representation of a vehicle in the micro simulation.
A storage for options typed value containers)
Representation of a vehicle.