Porting mros2 as an Mbed library.
Dependents: mbed-os-example-mros2 example-mbed-mros2-sub-pose example-mbed-mros2-pub-twist example-mbed-mros2-mturtle-teleop
mros2_msgs/std_msgs/msg/int16.hpp
- Committer:
- smoritaemb
- Date:
- 2022-03-19
- Revision:
- 7:c80f65422d99
- Parent:
- 2:159877d749c2
File content as of revision 7:c80f65422d99:
#include <string> namespace std_msgs { namespace msg { class Int16 { public: std::string getTypeName(); int16_t data; void copyToBuf(uint8_t *addrPtr) { memcpy(addrPtr, &data, 2); addrPtr += 2; } void copyFromBuf(const uint8_t *addrPtr) { memcpy(&data, addrPtr, 2); addrPtr += 2; } void memAlign(uint8_t *addrPtr){ return; } uint8_t getTotalSize() { return 2; } private: std::string type_name = "std_msgs::msg::dds_::Int16"; }; }//namspace msg }//namespace std_msgs namespace message_traits { template<> struct TypeName<std_msgs::msg::Int16*> { static const char* value() { return "std_msgs::msg::dds_::Int16_"; } }; }