allow minutely rollover as well
Some checks failed
EIVE/eive-obsw/pipeline/pr-develop There was a failure building this commit
Some checks failed
EIVE/eive-obsw/pipeline/pr-develop There was a failure building this commit
This commit is contained in:
parent
8c10cbe37b
commit
283b897ae7
@ -86,7 +86,9 @@ ReturnValue_t TmStore::storePacket(PusTmReader& reader) {
|
||||
MessageQueueId_t TmStore::getCommandQueue() { return MessageQueueIF::NO_QUEUE; }
|
||||
|
||||
void TmStore::calcDiffSeconds(RolloverInterval intervalUnit, uint32_t intervalCount) {
|
||||
if (intervalUnit == RolloverInterval::HOURLY) {
|
||||
if (intervalUnit == RolloverInterval::MINUTELY) {
|
||||
rolloverDiffSeconds = 60 * intervalCount;
|
||||
} else if (intervalUnit == RolloverInterval::HOURLY) {
|
||||
rolloverDiffSeconds = 60 * 60 * intervalCount;
|
||||
} else if (intervalUnit == RolloverInterval::DAILY) {
|
||||
rolloverDiffSeconds = 60 * 60 * 24 * intervalCount;
|
||||
|
@ -15,7 +15,7 @@ struct PacketFilter {
|
||||
std::optional<std::vector<std::pair<uint8_t, uint8_t>>> serviceSubservices;
|
||||
};
|
||||
|
||||
enum class RolloverInterval { HOURLY, DAILY };
|
||||
enum class RolloverInterval { MINUTELY, HOURLY, DAILY };
|
||||
|
||||
class TmStore : public SystemObject {
|
||||
public:
|
||||
@ -41,7 +41,7 @@ class TmStore : public SystemObject {
|
||||
std::string baseName;
|
||||
std::filesystem::path baseDir;
|
||||
uint32_t rolloverDiffSeconds = 0;
|
||||
std::array<uint8_t, 8192> fileBuf{};
|
||||
std::array<uint8_t, MAX_FILESIZE> fileBuf{};
|
||||
timeval& currentTv;
|
||||
std::optional<timeval> mostRecentTv;
|
||||
std::optional<std::filesystem::path> mostRecentFile;
|
||||
|
Loading…
x
Reference in New Issue
Block a user