Merge remote-tracking branch 'origin/develop' into mueller/spi-cache-spi-dev-in-com-if

This commit is contained in:
Robin Müller 2022-05-11 15:44:45 +02:00
commit dafcaa6007

View File

@ -8,7 +8,7 @@ class SourceSequenceCounter {
uint16_t sequenceCount = 0;
public:
SourceSequenceCounter() : sequenceCount(0) {}
SourceSequenceCounter(uint16_t initialSequenceCount = 0) : sequenceCount(initialSequenceCount) {}
void increment() {
sequenceCount = (sequenceCount + 1) % (SpacePacketBase::LIMIT_SEQUENCE_COUNT);
}
@ -31,6 +31,7 @@ class SourceSequenceCounter {
sequenceCount = newCount;
return *this;
}
operator uint16_t() { return this->get(); }
};