mirror of
https://github.com/eclipse-openvehicle-api/openvehicle-api.git
synced 2026-02-05 15:18:45 +00:00
update vss_util tool (#2)
This commit is contained in:
@@ -221,7 +221,7 @@ void CConsole::WriteSpeed(float value)
|
||||
if (m_SpeedVD != value)
|
||||
{
|
||||
m_SpeedVD = value;
|
||||
PrintValue(g_sVehicleDeviceSpeed, "Vehicle Speed RX", m_SpeedVD, "m/s");
|
||||
PrintValue(g_sVehicleDeviceSpeed, "Vehicle Speed RX", m_SpeedVD, "km/h");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -230,7 +230,7 @@ void CConsole::SetSpeed(float value)
|
||||
if (m_SpeedBS != value)
|
||||
{
|
||||
m_SpeedBS = value;
|
||||
PrintValue(g_sBasicServiceSpeed, "Vehicle Speed RX", m_SpeedBS * 3.6f, "km/h");
|
||||
PrintValue(g_sBasicServiceSpeed, "Vehicle Speed RX", m_SpeedBS, "km/h");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -16,7 +16,10 @@
|
||||
|
||||
|
||||
/**
|
||||
* @brief Open trunk service: opens the trunk if vehicle is not moving
|
||||
* @brief Open trunk example service
|
||||
* @details This complex service checks the speed of the vehicle. in case the vehicle is oving, it prohibits the opening of the trunk.
|
||||
* Input events from basic service: vehicle speed in km/h
|
||||
* Output call for basic service: opening the trunk
|
||||
*/
|
||||
class CTrunkExampleService : public sdv::CSdvObject
|
||||
, public sdv::IObjectControl
|
||||
@@ -75,12 +78,12 @@ public:
|
||||
|
||||
/**
|
||||
* @brief Set vehicleSpeed signal
|
||||
* @param[in] value vehicleSpeed
|
||||
* @param[in] value vehicle speed in km/h
|
||||
*/
|
||||
virtual void SetSpeed(float value) override;
|
||||
|
||||
/**
|
||||
* @brief Save call to open the trunk. Opening the trunk is onkly allowed when the vehicle is not moving
|
||||
* @brief Save call to open the trunk. Opening the trunk is only allowed when the vehicle is not moving
|
||||
* @return Returns whether the trunk could be opened or not.
|
||||
*/
|
||||
virtual bool PopTrunk() override;
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
;Class name;Function name;Signal name;vss;Signal direction;type;DBC CAN name includes CAN message name
|
||||
;;;;;;;
|
||||
VD;VehicleSpeed;Speed;vehicleSpeed;Vehicle.Speed;RX;float;CAN_Input.Speed
|
||||
VD;VehicleSpeed;Speed;vehicleSpeed;Vehicle.Speed;RX;float;CAN_Input.Speed;"float vehicleSpeed = value.get<float>() * 3.6f;"
|
||||
VD;VehicleTrunk;Open;trunk;Vehicle.Body.Trunk;TX;boolean;CAN_Output.OpenTrunk
|
||||
BS;VehicleSpeed;Speed;vehicleSpeed;Vehicle.Speed;RX;float;Vehicle.Speed
|
||||
BS;VehicleTrunk;Open;trunk;Vehicle.Body.Trunk;TX;boolean;Vehicle.Body.Trunk
|
||||
|
||||
|
Reference in New Issue
Block a user