Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion cmake/modules/PacketGenerator.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ function(GENERATE_PACKETS SRCS HDRS)
OUTPUT "${H_FILE}" "${CXX_FILE}"
COMMAND ${CMAKE_COMMAND} -E make_directory ${SRC_OUTPATH}
COMMAND ${CMAKE_COMMAND} -E make_directory ${HDR_OUTPATH}
COMMAND utils::packet_generator "${MATCH_PATH}" -h "${HDR_OUTPATH}" -c "${SRC_OUTPATH}"
COMMAND utils::packet_generator "${MATCH_PATH}" cpp --output_header_folder "${HDR_OUTPATH}" --output_source_folder "${SRC_OUTPATH}"
DEPENDS ${ABS_FILE} utils::packet_generator
COMMENT "Running C++ packetGenerator compiler on ${MATCH_PATH} with root ${IDLROOT}, generating: ${CXX_FILE}, ${H_FILE}"
VERBATIM)
Expand Down
2 changes: 2 additions & 0 deletions src/rosecommon/include/crosewriter.h
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,7 @@ class CRoseReader {
bool get_uint64_t(uint64_t& data) { return read(data); }
bool get_int64_t(int64_t& data) { return read(data); }
bool get_string(std::string& data) {
data.clear();
char c = '\0';
if (!read(c)) return false;
while (c != '\0') {
Expand All @@ -108,6 +109,7 @@ class CRoseReader {
return true;
}
bool get_string(std::string& data, size_t size) {
data.clear();
for (size_t i = 0; i < size; ++i) {
char c;
if (!read(c)) return false;
Expand Down
4 changes: 2 additions & 2 deletions src/rosecommon/packets/srv_toggle_move_reply.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<packet ePacketType = "PAKWC_TOGGLE_MOVE">
<element name = "objectId" type = "uint16_t" default = "0">
<element name = "objectId" type = "uint16_t" default = "0" />
<element name = "type" type = "ToggleMove" />
<element name = "runSpeed" type = "uint16_t" default = "0">
<element name = "runSpeed" type = "uint16_t" default = "0" />

<simpleType name = "ToggleMove">
<restriction base = "uint8_t">
Expand Down