eive-obsw/mission/tmtc/PusPacketFilter.h

25 lines
637 B
C++

#ifndef MISSION_TMTC_PUSPACKETFILTER_H_
#define MISSION_TMTC_PUSPACKETFILTER_H_
#include <fsfw/tmtcpacket/pus/tm/PusTmReader.h>
#include <optional>
#include <vector>
class PusPacketFilter {
public:
PusPacketFilter();
bool packetMatches(PusTmReader& reader) const;
void addApid(uint16_t apid);
void addService(uint8_t service);
void addServiceSubservice(uint8_t service, uint8_t subservice);
private:
std::optional<std::vector<uint16_t>> apid;
std::optional<std::vector<uint8_t>> services;
std::optional<std::vector<std::pair<uint8_t, uint8_t>>> serviceSubservices;
};
#endif /* MISSION_TMTC_PUSPACKETFILTER_H_ */