update vss_util tool (#2)

This commit is contained in:
tompzf
2025-11-12 15:40:23 +01:00
committed by GitHub
parent 6ed4b1534e
commit 2fb043b2be
37 changed files with 485 additions and 179 deletions

View File

@@ -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");
}
}

View File

@@ -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;

View File

@@ -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
1 Class name Function name Signal name vss Signal direction type DBC CAN name includes CAN message name
2
3 VD VehicleSpeed Speed vehicleSpeed Vehicle.Speed RX float CAN_Input.Speed
4 VD VehicleTrunk Open trunk Vehicle.Body.Trunk TX boolean CAN_Output.OpenTrunk
5 BS VehicleSpeed Speed vehicleSpeed Vehicle.Speed RX float Vehicle.Speed
6 BS VehicleTrunk Open trunk Vehicle.Body.Trunk TX boolean Vehicle.Body.Trunk