#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
◆ executeTick()
auto entity_behavior::ActionNode::executeTick |
( |
| ) |
-> BT::NodeStatus |
|
override |
throws if the derived class return RUNNING.
◆ foundConflictingEntity()
auto entity_behavior::ActionNode::foundConflictingEntity |
( |
const lanelet::Ids & |
following_lanelets | ) |
const -> bool |
◆ getBlackBoardValues()
auto entity_behavior::ActionNode::getBlackBoardValues |
( |
| ) |
-> void |
|
virtual |
◆ getDistanceToConflictingEntity()
◆ getDistanceToFrontEntity()
◆ getDistanceToStopLine()
auto entity_behavior::ActionNode::getDistanceToStopLine |
( |
const lanelet::Ids & |
route_lanelets, |
|
|
const std::vector< geometry_msgs::msg::Point > & |
waypoints |
|
) |
| const -> std::optional<double> |
◆ getDistanceToTargetEntity()
- Note
- getDistanceToTargetEntity working schematics
- Check if route to target entity from reference entity exists, if not try to transform pose to other routable lanelet, within matching distance (findRoutableAlternativeLaneletPoseFrom).
- Calculate longitudinal distance between entities bounding boxes -> bounding_box_distance.
- Calculate longitudinal distance between entities poses -> position_distance.
- Calculate target entity bounding box distance to reference entity spline (minimal distance from all corners) -> target_to_spline_distance.
- If target_to_spline_distance is less than half width of reference entity target entity is conflicting.
- Check corner case where target entity width is bigger than width of entity and target entity is exactly on the spline -> spline.getCollisionPointIn2D
- If target entity is conflicting return bounding_box_distance enlarged by half of the entity length.
boundingBoxLaneLongitudinalDistance requires routing_configuration, 'allow_lane_change = true' is needed to check distances to entities on neighbour lanelets
- Note
- if the distance of the target entity to the spline is smaller than the width of the reference entity
-
if the distance of the target entity to the spline cannot be calculated because a collision occurs
◆ 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.
◆ getHorizon()
auto entity_behavior::ActionNode::getHorizon |
( |
| ) |
const -> double |
◆ getOtherEntityStatus()
◆ 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 |
◆ 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
◆ 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: