CARLA
Loading...
Searching...
No Matches
VehicleStatusEvent.h
Go to the documentation of this file.
1// Copyright (c) 2026 Computer Vision Center (CVC) at the Universitat Autonoma
2// de Barcelona (UAB).
3//
4// This work is licensed under the terms of the MIT license.
5// For a copy, see <https://opensource.org/licenses/MIT>.
6
7#pragma once
8
11
12namespace carla {
13namespace sensor {
14namespace data {
15
16 /// Client-side view of one VehicleStatusSensor sample (Autoware vehicle
17 /// interface). Ported from tier4/autoware-support.
20 protected:
22 friend Serializer;
23
24 public:
25 explicit VehicleStatusEvent(const RawData &data)
26 : Super(data),
27 _parsed(Serializer::DeserializeRawData(data)) {}
28
29 double GetStatusTimestamp() const { return _parsed.timestamp; }
30
31 float GetSpeed() const { return _parsed.speed_mps; }
32 float GetVelX() const { return _parsed.vel_x_mps; } // local
33 float GetVelY() const { return _parsed.vel_y_mps; } // local
34 float GetVelZ() const { return _parsed.vel_z_mps; } // local
35
36 float GetAngVelX() const { return _parsed.angVel_x_mps; } // local
37 float GetAngVelY() const { return _parsed.angVel_y_mps; } // local
38 float GetAngVelZ() const { return _parsed.angVel_z_mps; } // local
39
40 float GetRotPitch() const { return _parsed.rot_pitch; } // relative
41 float GetRotYaw() const { return _parsed.rot_yaw; } // relative
42 float GetRotRoll() const { return _parsed.rot_roll; } // relative
43
44 float GetSteer() const { return _parsed.steer; }
45 int32_t GetGear() const { return _parsed.gear; }
46 uint8_t GetTurnMask() const { return _parsed.turn_mask; }
47 uint8_t GetControlFlags() const { return _parsed.control_flags; }
48
49 private:
51 };
52
53} // namespace data
54} // namespace sensor
55} // namespace carla
Wrapper around the raw data generated by a sensor plus some useful meta-information.
Definition RawData.h:21
Base class for all the objects containing data generated by a sensor.
Definition SensorData.h:22
Client-side view of one VehicleStatusSensor sample (Autoware vehicle interface).
This file contains definitions of common data structures used in traffic manager.
Snapshot of a vehicle's kinematic + control state, streamed each tick by the Autoware VehicleStatusSe...