#include <action_node.hpp>
◆ ActionNode()
| entity_behavior::ActionNode::ActionNode |
( |
const std::string & |
name, |
|
|
const BT::NodeConfiguration & |
config |
|
) |
| |
◆ ~ActionNode()
| entity_behavior::ActionNode::~ActionNode |
( |
| ) |
|
|
overridedefault |
◆ calculateStopDistance()
| auto entity_behavior::ActionNode::calculateStopDistance |
( |
const traffic_simulator_msgs::msg::DynamicConstraints & |
constraints | ) |
const -> double |
◆ calculateUpdatedEntityStatus()
| auto entity_behavior::ActionNode::calculateUpdatedEntityStatus |
( |
const double |
local_target_speed, |
|
|
const traffic_simulator_msgs::msg::DynamicConstraints & |
constraints |
|
) |
| const -> traffic_simulator::EntityStatus |
- Todo:
- it will be moved to route::moveAlongLaneletPose(...)
◆ calculateUpdatedEntityStatusInWorldFrame()
| auto entity_behavior::ActionNode::calculateUpdatedEntityStatusInWorldFrame |
( |
const double |
local_target_speed, |
|
|
const traffic_simulator_msgs::msg::DynamicConstraints & |
constraints |
|
) |
| const -> traffic_simulator::EntityStatus |
- Note
- Apply yaw change (delta rotation) in radians: yaw_angular_speed (rad/s) * time_step (s)
-
Apply position change
- Todo:
- first determine global desired_velocity, calculate position change using it then pass the same global desired_velocity to updatePositionForLaneletTransition()
- Note
- If it is the transition between lanelets: overwrite position to improve precision
-
Handle lanelet transition
◆ checkPreconditions()
| virtual bool entity_behavior::ActionNode::checkPreconditions |
( |
| ) |
|
|
inlineprotectedvirtual |
Reimplemented in entity_behavior::vehicle::LaneChangeAction, entity_behavior::vehicle::FollowPolylineTrajectoryAction, entity_behavior::vehicle::follow_lane_sequence::YieldAction, entity_behavior::vehicle::follow_lane_sequence::StopAtTrafficLightAction, entity_behavior::vehicle::follow_lane_sequence::StopAtStopLineAction, entity_behavior::vehicle::follow_lane_sequence::StopAtCrossingEntityAction, entity_behavior::vehicle::follow_lane_sequence::MoveBackwardAction, entity_behavior::vehicle::follow_lane_sequence::FollowLaneAction, entity_behavior::vehicle::follow_lane_sequence::FollowFrontEntityAction, entity_behavior::pedestrian::WalkStraightAction, entity_behavior::pedestrian::FollowPolylineTrajectoryAction, and entity_behavior::pedestrian::FollowLaneAction.
◆ doAction()
| virtual BT::NodeStatus entity_behavior::ActionNode::doAction |
( |
| ) |
|
|
protectedpure virtual |
Implemented in entity_behavior::vehicle::LaneChangeAction, entity_behavior::vehicle::FollowPolylineTrajectoryAction, entity_behavior::vehicle::follow_lane_sequence::YieldAction, entity_behavior::vehicle::follow_lane_sequence::StopAtTrafficLightAction, entity_behavior::vehicle::follow_lane_sequence::StopAtStopLineAction, entity_behavior::vehicle::follow_lane_sequence::StopAtCrossingEntityAction, entity_behavior::vehicle::follow_lane_sequence::MoveBackwardAction, entity_behavior::vehicle::follow_lane_sequence::FollowLaneAction, entity_behavior::vehicle::follow_lane_sequence::FollowFrontEntityAction, entity_behavior::pedestrian::WalkStraightAction, entity_behavior::pedestrian::FollowPolylineTrajectoryAction, and entity_behavior::pedestrian::FollowLaneAction.
◆ executeTick()
| auto entity_behavior::ActionNode::executeTick |
( |
| ) |
-> BT::NodeStatus |
|
override |
throws if the derived class return RUNNING.
◆ getBlackBoardValues()
| auto entity_behavior::ActionNode::getBlackBoardValues |
( |
| ) |
-> void |
|
virtual |
◆ getDistanceToConflictingEntity()
◆ getDistanceToFrontEntity()
◆ getDistanceToTrafficLightStopLine()
◆ getEntityStatus()
◆ getFrontEntityName()
- Note
- hard-coded parameter, if the Yaw value of RPY is in ~1.5708 -> 1.5708, entity is a candidate of front entity.
-
Euclidean distance is here used as a "rough" distance to filter only NPCs which possibly are in range of current horizon. Because euclidean distance is the shortest possible distance comparing it with horizon will never omit NPCs for which actual lane distance is in range of horizon.
◆ getFrontEntityNameAndDistanceByTrajectory()
| auto entity_behavior::ActionNode::getFrontEntityNameAndDistanceByTrajectory |
( |
const std::vector< geometry_msgs::msg::Point > & |
waypoints, |
|
|
const double |
width, |
|
|
const std::size_t |
num_segments |
|
) |
| const -> std::optional<std::pair<std::string, double>> |
◆ getHorizon()
| auto entity_behavior::ActionNode::getHorizon |
( |
| ) |
const -> double |
◆ getOtherEntitiesCanonicalizedEntityStatuses()
◆ getOtherEntitiesCanonicalizedLaneletPoses()
◆ getRightOfWayEntities() [1/2]
◆ getRightOfWayEntities() [2/2]
◆ getYieldStopDistance()
| auto entity_behavior::ActionNode::getYieldStopDistance |
( |
const lanelet::Ids & |
following_lanelets | ) |
const -> std::optional<double> |
◆ halt()
| void entity_behavior::ActionNode::halt |
( |
| ) |
|
|
inlinefinaloverride |
◆ providedPorts()
| static BT::PortsList entity_behavior::ActionNode::providedPorts |
( |
| ) |
|
|
inlinestatic |
◆ setCanonicalizedEntityStatus()
◆ stopEntity()
| auto entity_behavior::ActionNode::stopEntity |
( |
| ) |
const -> void |
◆ behavior_parameter_
| traffic_simulator_msgs::msg::BehaviorParameter entity_behavior::ActionNode::behavior_parameter_ |
|
protected |
◆ canonicalized_entity_status_
◆ current_time_
| double entity_behavior::ActionNode::current_time_ |
|
protected |
◆ default_matching_distance_for_lanelet_pose_calculation_
| double entity_behavior::ActionNode::default_matching_distance_for_lanelet_pose_calculation_ |
|
protected |
◆ hdmap_utils_
◆ lateral_collision_threshold_
| std::optional<double> entity_behavior::ActionNode::lateral_collision_threshold_ |
|
protected |
◆ other_entity_status_
◆ request_
◆ route_lanelets_
| lanelet::Ids entity_behavior::ActionNode::route_lanelets_ |
|
protected |
◆ step_time_
| double entity_behavior::ActionNode::step_time_ |
|
protected |
◆ target_speed_
| std::optional<double> entity_behavior::ActionNode::target_speed_ |
|
protected |
◆ traffic_lights_
The documentation for this class was generated from the following files: