MCPcopy Create free account
hub / github.com/Robotics-STAR-Lab/SOAR / chunkCallback

Method chunkCallback

src/planner/plan_env/src/multi_map_manager.cpp:330–348  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

328}
329
330void MultiMapManager::chunkCallback(const plan_env::ChunkDataConstPtr& msg)
331{
332 // Receive chunks from other drones, store them in chunk buffer
333 // if (msg->from_drone_id == drone_id_) return;
334 // if (msg->from_drone_id != 1) return;
335 // if(msg->to_drone_id != drone_id_) return;
336
337 // Ignore chunks that are in the insertion buffer
338 if (buffer_map_[msg->chunk_drone_id - 1].find(msg->idx) !=
339 buffer_map_[msg->chunk_drone_id - 1].end())
340 return;
341
342 // ROS_ERROR("received msg idx: %d, from %d to %d", msg->idx, msg->from_drone_id,
343 // msg->to_drone_id);
344 chunk_buffer_[msg->chunk_drone_id - 1].push_back(*msg);
345 buffer_map_[msg->chunk_drone_id - 1][msg->idx] = 1;
346
347 return;
348}
349
350void MultiMapManager::chunkTimerCallback(const ros::TimerEvent& e)
351{

Callers

nothing calls this directly

Calls 1

endMethod · 0.45

Tested by

no test coverage detected