Added print to print out new calculated width

This commit is contained in:
2026-03-24 20:40:14 +01:00
parent 0105984458
commit c7caa69bfa
3 changed files with 106 additions and 15 deletions

View File

@@ -33,7 +33,7 @@ public:
bool setRequest(typename Request::SharedPtr & request) override
{
auto width = getInput<double>("width").value();
auto count = getInput<double>("count").value();
double count = getInput<int>("count").value();
geometry_msgs::msg::PoseStamped pose;
get_pose(pose);
@@ -42,6 +42,8 @@ public:
double new_width = width * (1 + (theta / (2 * M_PI * count)));
request->data = new_width;
RCLCPP_INFO(logger(), "width is %lf", new_width);
setOutput("new_width", new_width);
return true;
}