edit commands for test controller and remove spamming logs
This commit is contained in:
@@ -321,24 +321,24 @@ private:
|
||||
// RCLCPP_INFO(this->get_logger(), "current values: %f %f %f %f", last_setpoint[0], last_setpoint[1], last_setpoint[2], last_thrust);
|
||||
if (!user_in_control)
|
||||
{
|
||||
RCLCPP_INFO(this->get_logger(), "Sending idle attitude setpoint");
|
||||
// RCLCPP_INFO(this->get_logger(), "Sending idle attitude setpoint");
|
||||
send_attitude_setpoint();
|
||||
}
|
||||
else
|
||||
{
|
||||
if (current_control_mode == CONTROL_MODE_ATTITUDE)
|
||||
{
|
||||
RCLCPP_INFO(this->get_logger(), "Sending attitude setpoint");
|
||||
// RCLCPP_INFO(this->get_logger(), "Sending attitude setpoint");
|
||||
send_attitude_setpoint();
|
||||
}
|
||||
else if (current_control_mode == CONTROL_MODE_VELOCITY)
|
||||
{
|
||||
RCLCPP_INFO(this->get_logger(), "Sending velocity setpoint");
|
||||
// RCLCPP_INFO(this->get_logger(), "Sending velocity setpoint");
|
||||
send_velocity_setpoint();
|
||||
}
|
||||
else if (current_control_mode == CONTROL_MODE_POSITION)
|
||||
{
|
||||
RCLCPP_INFO(this->get_logger(), "Sending position setpoint");
|
||||
// RCLCPP_INFO(this->get_logger(), "Sending position setpoint");
|
||||
send_position_setpoint();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -40,7 +40,7 @@ class TestController(Node):
|
||||
self.traj_req = SetTrajectory.Request()
|
||||
self.arm_req = ArmDrone.Request()
|
||||
|
||||
self.get_logger().info("\nControls:\n1 - Attitude control\n2 - Velocity control\n3 - Position control\n/ - Arm drone\nW - forward\nS - backward\nA - left\nD - right\nQ - rotate left\nE - rotate right\nSpace - up\nZ - down\nV - Down nudge\nF - Up nudge\nN - emergency stop\nEsc - exit")
|
||||
self.get_logger().info("\nControls:\n1 - Attitude control\n2 - Velocity control\n3 - Position control\n/ - Arm drone\nW - forward\nS - backward\nA - left\nD - right\nQ - rotate left\nE - rotate right\nSpace - up\nZ - down\nV - Down nudge\nF - Up nudge\nN - emergency stop\nCTRL-C - exit")
|
||||
|
||||
def spin(self):
|
||||
while rclpy.ok():
|
||||
|
||||
Reference in New Issue
Block a user