1
0
mirror of https://gitlab.com/obbart/universal_robots_ros_driver.git synced 2026-04-12 19:10:47 +02:00

Parse unknown states to default RobotStates

This commit is contained in:
Felix Mauch
2019-04-10 10:01:17 +02:00
parent 4dc4cc0fb0
commit fcc1e62ab5
5 changed files with 37 additions and 12 deletions

View File

@@ -172,6 +172,14 @@ public:
parse(val.rotation);
}
void rawData(std::unique_ptr<uint8_t>& buffer, size_t& buffer_length)
{
buffer_length = buf_end_ - buf_pos_;
buffer.reset(new uint8_t[buffer_length]);
memcpy(buffer.get(), buf_pos_, buffer_length);
consume();
}
void parseRemainder(std::string& val)
{
parse(val, size_t(buf_end_ - buf_pos_));