Update FSFW from upstream #71

Closed
muellerr wants to merge 1112 commits from development into eive/develop
2 changed files with 12 additions and 12 deletions
Showing only changes of commit 2a34c831b1 - Show all commits

View File

@ -62,9 +62,9 @@ class SerializeIF {
virtual ReturnValue_t serialize(uint8_t **buffer, size_t *size, size_t maxSize,
Endianness streamEndianness) const = 0;
/**
* Forwards to regular @serialize call with network endianness
* Forwards to regular @serialize call with big (network) endianness
*/
virtual ReturnValue_t serializeNe(uint8_t** buffer, size_t* size, size_t maxSize) {
virtual ReturnValue_t serializeBe(uint8_t** buffer, size_t* size, size_t maxSize) {
return serialize(buffer, size, maxSize, SerializeIF::Endianness::NETWORK);
}
/**
@ -103,9 +103,9 @@ class SerializeIF {
virtual ReturnValue_t deSerialize(const uint8_t **buffer, size_t *size,
Endianness streamEndianness) = 0;
/**
* Forwards to regular @deSerialize call with network endianness
* Forwards to regular @deSerialize call with big (network) endianness
*/
virtual ReturnValue_t deSerializeNe(const uint8_t** buffer, size_t* size) {
virtual ReturnValue_t deSerializeBe(const uint8_t** buffer, size_t* size) {
return deSerialize(buffer, size, SerializeIF::Endianness::NETWORK);
}
/**
@ -129,9 +129,9 @@ class SerializeIF {
return serialize(&buffer, &tmpSize, maxSize, streamEndianness);
}
/**
* Forwards to regular @serialize call with network endianness
* Forwards to regular @serialize call with big (network) endianness
*/
virtual ReturnValue_t serializeNe(uint8_t *buffer, size_t maxSize) const {
virtual ReturnValue_t serializeBe(uint8_t *buffer, size_t maxSize) const {
return serialize(buffer, maxSize, SerializeIF::Endianness::NETWORK);
}
/**
@ -154,9 +154,9 @@ class SerializeIF {
return deSerialize(&buffer, &maxSize, streamEndianness);
}
/**
* Forwards to regular @serialize call with network endianness
* Forwards to regular @serialize call with big (network) endianness
*/
virtual ReturnValue_t deSerializeNe(const uint8_t *buffer, size_t maxSize) {
virtual ReturnValue_t deSerializeBe(const uint8_t *buffer, size_t maxSize) {
return deSerialize(buffer, maxSize, SerializeIF::Endianness::NETWORK);
}
/**

View File

@ -38,7 +38,7 @@ TEST_CASE("Serialize IF Serialize", "[serialize-if-ser]") {
REQUIRE(simpleSer.serialize(&ptr, &len, buf.size(), SerializeIF::Endianness::NETWORK) == HasReturnvaluesIF::RETURN_OK);
}
SECTION("Network 1") {
REQUIRE(simpleSer.serializeNe(&ptr, &len, buf.size()) == HasReturnvaluesIF::RETURN_OK);
REQUIRE(simpleSer.serializeBe(&ptr, &len, buf.size()) == HasReturnvaluesIF::RETURN_OK);
}
CHECK(buf[0] == 1);
@ -58,7 +58,7 @@ TEST_CASE("Serialize IF Serialize", "[serialize-if-ser]") {
REQUIRE(simpleSer.SerializeIF::serialize(buf.data(), buf.size(), SerializeIF::Endianness::NETWORK) == HasReturnvaluesIF::RETURN_OK);
}
SECTION("Network 1") {
REQUIRE(simpleSer.SerializeIF::serializeNe(buf.data(), buf.size()) == HasReturnvaluesIF::RETURN_OK);
REQUIRE(simpleSer.SerializeIF::serializeBe(buf.data(), buf.size()) == HasReturnvaluesIF::RETURN_OK);
}
CHECK(buf[0] == 1);
CHECK(buf[1] == 2);
@ -123,7 +123,7 @@ TEST_CASE("SerializeIF Deserialize", "[serialize-if-de]") {
REQUIRE(simpleSer.deSerialize(&ptr, &len, SerializeIF::Endianness::NETWORK) == HasReturnvaluesIF::RETURN_OK);
}
SECTION("Network 1") {
REQUIRE(simpleSer.SerializeIF::deSerializeNe(&ptr, &len) == HasReturnvaluesIF::RETURN_OK);
REQUIRE(simpleSer.SerializeIF::deSerializeBe(&ptr, &len) == HasReturnvaluesIF::RETURN_OK);
}
CHECK(simpleSer.getU8() == 5);
CHECK(simpleSer.getU16() == 1);
@ -140,7 +140,7 @@ TEST_CASE("SerializeIF Deserialize", "[serialize-if-de]") {
REQUIRE(simpleSer.SerializeIF::deSerialize(buf.data(), buf.size(), SerializeIF::Endianness::NETWORK) == HasReturnvaluesIF::RETURN_OK);
}
SECTION("Network 1") {
REQUIRE(simpleSer.SerializeIF::deSerializeNe(buf.data(), buf.size()) == HasReturnvaluesIF::RETURN_OK);
REQUIRE(simpleSer.SerializeIF::deSerializeBe(buf.data(), buf.size()) == HasReturnvaluesIF::RETURN_OK);
}
CHECK(simpleSer.getU8() == 5);
CHECK(simpleSer.getU16() == 1);