Skip to content
Snippets Groups Projects
Commit 0911a188 authored by Fabian Reister's avatar Fabian Reister
Browse files

VirtualRobotReader: better warnings

parent b1af7613
No related branches found
No related tags found
No related merge requests found
......@@ -95,7 +95,7 @@ namespace armarx::robot_state
ARMARX_INFO << deactivateSpam(10) << "Synchronizing robot";
TIMING_START(synchronizeRobot);
virtualRobotReader.synchronizeRobot(*virtualRobot, now);
ARMARX_CHECK(virtualRobotReader.synchronizeRobot(*virtualRobot, now));
TIMING_END_STREAM(synchronizeRobot, ARMARX_INFO);
}
......
......@@ -68,6 +68,7 @@ namespace armarx::armem::robot_state
if (not description)
{
ARMARX_WARNING << "The description of robot `" << name << "` is nota available!";
return nullptr;
}
......@@ -79,7 +80,13 @@ namespace armarx::armem::robot_state
auto robot = VirtualRobot::RobotIO::loadRobot(xmlFilename, loadMode);
robot->setName(name);
synchronizeRobot(*robot, timestamp);
const bool success = synchronizeRobot(*robot, timestamp);
if(not success)
{
ARMARX_WARNING << "Could not synchronize robot `" << name << "` with the memory!";
return nullptr;
}
return robot;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment