Closed slux83 closed 3 years ago
The issue is caused by a wrong implementation of the transmit(frame, timeout) method. For BD frames, the method unlocks the caller as soon as a REJECT or ACCEPT is received. However, this is not enough to ensure that the next frame will be able to be accepted: in fact, looking at event E21 and E22 of the COP-1 state machine, the next call will fail if the bdOutputFlag is not ready. This flag is linked to event E45, and not to the generation of the ACCEPT response. The code has been modified to keep this into account. A unit test that could reproduce the issue has been added.
I'm trying to send the same TC packet as fast as possible (in my example 100 TC packets) that they are encoded in TC frames. It seems that once the TC frame is passed to the FOP engine (
eu.dariolucia.ccsds.tmtc.cop1.fop.FopEngine#transmit(eu.dariolucia.ccsds.tmtc.datalink.pdu.TcTransferFrame, int)
) it gets lost and the Fop Engine only gives back (via callback) a smaller amount of framesLooking at the FOP implementation it seems that this can return "false" in case the frame is not accepted. What is the correct behavior in this case?