CFDP fixes
All checks were successful
EIVE/-/pipeline/head This commit looks good

This commit is contained in:
2023-11-13 09:05:34 +01:00
parent 6a8f48c493
commit 4446e471d9
3 changed files with 28 additions and 10 deletions

View File

@ -1,7 +1,10 @@
from datetime import timedelta
import logging
from spacepackets.cfdp import ConditionCode
from spacepackets.util import UnsignedByteField
from tmtccmd.cfdp import CfdpUserBase, TransactionId
from tmtccmd.cfdp.mib import CheckTimerProvider, Countdown, EntityType
from tmtccmd.cfdp.user import (
TransactionFinishedParams,
MetadataRecvParams,
@ -11,6 +14,16 @@ from tmtccmd.cfdp.user import (
_LOGGER = logging.getLogger(__name__)
class EiveCheckTimerProvider(CheckTimerProvider):
def provide_check_timer(
self,
local_entity_id: UnsignedByteField,
remote_entity_id: UnsignedByteField,
entity_type: EntityType,
) -> Countdown:
return Countdown(timedelta(seconds=5.0))
class EiveCfdpUser(CfdpUserBase):
def transaction_indication(self, transaction_id: TransactionId):
_LOGGER.info(f"CFDP User: Start of File {transaction_id}")