check busy state
Some checks failed
EIVE/eive-obsw/pipeline/pr-develop There was a failure building this commit

This commit is contained in:
2023-03-10 18:04:04 +01:00
parent 3c0b8f9e8b
commit 976235a79f
10 changed files with 43 additions and 12 deletions

View File

@ -51,3 +51,14 @@ void Ptme::addVcInterface(VcId_t vcId, VirtualChannelIF* vc) {
return;
}
}
bool Ptme::isBusy(uint8_t vcId) const {
const auto& vcInterfaceMapIter = vcInterfaceMap.find(vcId);
if (vcInterfaceMapIter == vcInterfaceMap.end()) {
sif::warning << "Ptme::writeToVc: No virtual channel interface found for the virtual "
"channel with id "
<< static_cast<unsigned int>(vcId) << std::endl;
return UNKNOWN_VC_ID;
}
return vcInterfaceMapIter->second->isBusy();
}