mirror of
https://gitlab.com/obbart/universal_robots_ros_driver.git
synced 2026-04-10 18:10:47 +02:00
implemented serialization of general rtde headers and the request
protocol version package
This commit is contained in:
@@ -39,7 +39,19 @@ bool RequestProtocolVersion::parseWith(comm::BinParser& bp)
|
||||
}
|
||||
std::string RequestProtocolVersion::toString() const
|
||||
{
|
||||
return "accepted: " + accepted_;
|
||||
std::stringstream ss;
|
||||
ss << "accepted: " << static_cast<int>(accepted_);
|
||||
return ss.str();
|
||||
}
|
||||
|
||||
size_t RequestProtocolVersionRequest::generateSerializedRequest(uint8_t* buffer, uint16_t version)
|
||||
{
|
||||
size_t size = 0;
|
||||
size += PackageHeader::serializeHeader(buffer, PACKAGE_TYPE, PAYLOAD_SIZE);
|
||||
|
||||
size += comm::PackageSerializer::serialize(buffer + size, version);
|
||||
|
||||
return size;
|
||||
}
|
||||
} // namespace rtde_interface
|
||||
} // namespace ur_driver
|
||||
|
||||
Reference in New Issue
Block a user