add comment, remove skipping updateObjectsStack logic

This commit is contained in:
yuasabe 2022-05-19 16:32:49 +09:00
parent e7460ab62d
commit 65c92be3f9
1 changed files with 8 additions and 6 deletions

View File

@ -238,12 +238,12 @@ namespace v2x {
void CpmApplication::updateObjectsList(const autoware_auto_perception_msgs::msg::PredictedObjects::ConstSharedPtr msg) { void CpmApplication::updateObjectsList(const autoware_auto_perception_msgs::msg::PredictedObjects::ConstSharedPtr msg) {
updating_objects_list_ = true; updating_objects_list_ = true;
if (sending_) { // if (sending_) {
RCLCPP_INFO(node_->get_logger(), "updateObjectsStack Skipped..."); // RCLCPP_INFO(node_->get_logger(), "updateObjectsStack Skipped...");
return; // return;
} else { // } else {
// objectsList.clear(); // // objectsList.clear();
} // }
if (msg->objects.size() > 0) { if (msg->objects.size() > 0) {
for (autoware_auto_perception_msgs::msg::PredictedObject obj : msg->objects) { for (autoware_auto_perception_msgs::msg::PredictedObject obj : msg->objects) {
@ -551,6 +551,8 @@ namespace v2x {
// RCLCPP_INFO(node_->get_logger(), "[CpmApplication::send] Empty POC"); // RCLCPP_INFO(node_->get_logger(), "[CpmApplication::send] Empty POC");
} }
RCLCPP_INFO(node_->get_logger(), "[CpmApplication::send] Sending CPM with %ld objects", objectsList.size());
insertCpmToCpmTable(message, (char*) "cpm_sent"); insertCpmToCpmTable(message, (char*) "cpm_sent");
Application::DownPacketPtr packet{new DownPacket()}; Application::DownPacketPtr packet{new DownPacket()};