Skip to content

Commit

Permalink
change warn to debug in distributed handles and state-/commandpublisher
Browse files Browse the repository at this point in the history
  • Loading branch information
mamueluth committed May 22, 2023
1 parent 6f9de32 commit 6241a0e
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 8 deletions.
6 changes: 3 additions & 3 deletions hardware_interface/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,14 @@ endif()

set(THIS_PACKAGE_INCLUDE_DEPENDS
control_msgs
controller_manager_msgs
controller_manager_msgs
lifecycle_msgs
pluginlib
rclcpp
rclcpp
rclcpp_lifecycle
rcpputils
rcutils
std_msgs
std_msgs
TinyXML2
tinyxml2_vendor
)
Expand Down
6 changes: 3 additions & 3 deletions hardware_interface/include/hardware_interface/handle.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -254,7 +254,7 @@ class DistributedReadOnlyHandle : public ReadOnlyHandle
void get_value_cb(const std_msgs::msg::Float64 & msg)
{
value_ = msg.data;
RCLCPP_WARN_STREAM(node_->get_logger(), "Receiving:[" << value_ << "].");
RCLCPP_DEBUG_STREAM(node_->get_logger(), "Receiving:[" << value_ << "].");
}

std::string get_value_topic_name_;
Expand Down Expand Up @@ -405,7 +405,7 @@ class DistributedReadWriteHandle : public ReadWriteHandle
auto msg = std::make_unique<std_msgs::msg::Float64>();
msg->data = value;

RCLCPP_WARN(node_->get_logger(), "DistributedCommandInterface Publishing: '%.7lf'", msg->data);
RCLCPP_DEBUG(node_->get_logger(), "DistributedCommandInterface Publishing: '%.7lf'", msg->data);
std::flush(std::cout);

command_value_pub_->publish(std::move(msg));
Expand All @@ -417,7 +417,7 @@ class DistributedReadWriteHandle : public ReadWriteHandle
void get_value_cb(const std_msgs::msg::Float64 & msg)
{
value_ = msg.data;
RCLCPP_WARN_STREAM(
RCLCPP_DEBUG_STREAM(
node_->get_logger(), "DistributedCommandInterface Receiving:[" << value_ << "].");
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@
#include <map>
#include <stdexcept>

#include "rclcpp/rclcpp.hpp"

using namespace std::chrono_literals;

namespace distributed_control
Expand Down Expand Up @@ -105,7 +107,7 @@ void CommandForwarder::publish_value_on_timer()
{
msg->data = std::numeric_limits<double>::quiet_NaN();
}
RCLCPP_WARN(node_->get_logger(), "Publishing: '%.7lf'", msg->data);
RCLCPP_DEBUG(node_->get_logger(), "Publishing: '%.7lf'", msg->data);
std::flush(std::cout);

// Put the message into a queue to be processed by the middleware.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@
#include <map>
#include <stdexcept>

#include "rclcpp/rclcpp.hpp"

using namespace std::chrono_literals;

namespace distributed_control
Expand Down Expand Up @@ -97,7 +99,7 @@ void StatePublisher::publish_value_on_timer()
// Make explicit note implicit!!!
msg->data = std::numeric_limits<double>::quiet_NaN();
}
RCLCPP_WARN(node_->get_logger(), "Publishing: '%.7lf'", msg->data);
RCLCPP_DEBUG(node_->get_logger(), "Publishing: '%.7lf'", msg->data);
std::flush(std::cout);

// Put the message into a queue to be processed by the middleware.
Expand Down

0 comments on commit 6241a0e

Please sign in to comment.