this is useable
This commit is contained in:
@ -13,6 +13,9 @@ ReturnValue_t PusLiveDemux::demultiplexPackets(StorageManagerIF& tmStore,
|
||||
// std::endl;
|
||||
for (unsigned int idx = 0; idx < destinations.size(); idx++) {
|
||||
const auto& dest = destinations[idx];
|
||||
if (dest.isFull) {
|
||||
continue;
|
||||
}
|
||||
if ((destinations.size() > 1) and (idx < (destinations.size() - 1))) {
|
||||
// Create copy of data to ensure each TM recipient has its own copy. That way, we don't need
|
||||
// to bother with send order and where the data is deleted.
|
||||
@ -52,8 +55,21 @@ ReturnValue_t PusLiveDemux::demultiplexPackets(StorageManagerIF& tmStore,
|
||||
return result;
|
||||
}
|
||||
|
||||
void PusLiveDemux::addDestination(const char* name, const AcceptsTelemetryIF& downlinkDestination,
|
||||
uint8_t vcid) {
|
||||
uint32_t PusLiveDemux::addDestination(const char* name,
|
||||
const AcceptsTelemetryIF& downlinkDestination, uint8_t vcid) {
|
||||
auto queueId = downlinkDestination.getReportReceptionQueue(vcid);
|
||||
destinations.emplace_back(name, queueId, vcid);
|
||||
return destinations.size() - 1;
|
||||
}
|
||||
|
||||
void PusLiveDemux::setDestFull(uint32_t listIndex) {
|
||||
if (destinations.size() > 0 and listIndex <= destinations.size() - 1) {
|
||||
destinations[listIndex].isFull = true;
|
||||
}
|
||||
}
|
||||
|
||||
void PusLiveDemux::setDestAvailable(uint32_t listIndex) {
|
||||
if (destinations.size() > 0 and listIndex <= destinations.size() - 1) {
|
||||
destinations[listIndex].isFull = false;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user