15 #ifndef TRAFFIC_SIMULATOR__VEHICLE_SIMULATION__EGO_ENTITY_SIMULATION_HPP_
16 #define TRAFFIC_SIMULATOR__VEHICLE_SIMULATION__EGO_ENTITY_SIMULATION_HPP_
24 #include <traffic_simulator_msgs/msg/entity_status.hpp>
25 #include <traffic_simulator_msgs/msg/polyline_trajectory.hpp>
26 #include <traffic_simulator_msgs/msg/vehicle_parameters.hpp>
44 const std::unique_ptr<concealer::AutowareUniverse>
autoware;
49 const std::shared_ptr<SimModelInterface> vehicle_model_ptr_;
51 std::optional<double> previous_linear_velocity_, previous_angular_velocity_;
57 const Eigen::Matrix3d initial_rotation_matrix_;
61 static auto makeSimulationModel(
63 const traffic_simulator_msgs::msg::VehicleParameters &)
64 ->
const std::shared_ptr<SimModelInterface>;
66 const bool consider_acceleration_by_road_slope_;
68 Eigen::Vector3d world_relative_position_;
78 auto getCurrentPose(const
double pitch_angle) const -> geometry_msgs::msg::
Pose;
80 auto getCurrentTwist() const -> geometry_msgs::msg::Twist;
82 auto getCurrentAccel(const
double step_time) const -> geometry_msgs::msg::Accel;
84 auto getLinearJerk(
double step_time) ->
double;
86 auto updatePreviousValues() ->
void;
93 const traffic_simulator_msgs::msg::VehicleParameters &,
double,
94 const
std::shared_ptr<
hdmap_utils::HdMapUtils> &, const rclcpp::Parameter & use_sim_time,
95 const
bool consider_acceleration_by_road_slope);
98 const traffic_simulator_msgs::msg::
EntityStatus & status, const
double current_time,
99 const
double step_time,
bool is_npc_logic_started) ->
void;
101 auto
update(const
double current_time, const
double step_time, const
bool is_npc_logic_started)
110 auto
updateStatus(const
double current_time, const
double step_time) ->
void;
Definition: entity_status.hpp:32
Definition: ego_entity_simulation.hpp:42
auto update(const double current_time, const double step_time, const bool is_npc_logic_started) -> void
Definition: ego_entity_simulation.cpp:286
const traffic_simulator_msgs::msg::VehicleParameters vehicle_parameters
Definition: ego_entity_simulation.hpp:73
const std::shared_ptr< hdmap_utils::HdMapUtils > hdmap_utils_ptr_
Definition: ego_entity_simulation.hpp:71
auto updateStatus(const double current_time, const double step_time) -> void
Definition: ego_entity_simulation.cpp:450
auto setAutowareStatus() -> void
Definition: ego_entity_simulation.cpp:171
auto overwrite(const traffic_simulator_msgs::msg::EntityStatus &status, const double current_time, const double step_time, bool is_npc_logic_started) -> void
Definition: ego_entity_simulation.cpp:220
auto calculateAccelerationBySlope() const -> double
Definition: ego_entity_simulation.cpp:351
auto requestSpeedChange(double value) -> void
Definition: ego_entity_simulation.cpp:184
auto getStatus() const -> const traffic_simulator_msgs::msg::EntityStatus
Definition: ego_entity_simulation.cpp:423
const std::unique_ptr< concealer::AutowareUniverse > autoware
Definition: ego_entity_simulation.hpp:44
auto setStatus(const traffic_simulator_msgs::msg::EntityStatus &status) -> void
Definition: ego_entity_simulation.cpp:428
Definition: lanelet_wrapper.hpp:40
geometry_msgs::msg::Pose Pose
Definition: lanelet_wrapper.hpp:66
Definition: ego_entity_simulation.hpp:29
VehicleModelType
Definition: ego_entity_simulation.hpp:30
@ DELAY_STEER_MAP_ACC_GEARED
@ DELAY_STEER_ACC_GEARED_WO_FALL_GUARD
traffic_simulator_msgs::EntityStatus EntityStatus
Definition: helper_functions.hpp:32