Package org.yamcs.tctm.ccsds
Class AbstractTcFrameLink
- java.lang.Object
-
- com.google.common.util.concurrent.AbstractService
-
- org.yamcs.tctm.AbstractLink
-
- org.yamcs.tctm.ccsds.AbstractTcFrameLink
-
- All Implemented Interfaces:
com.google.common.util.concurrent.Service
,SystemParametersProducer
,AggregatedDataLink
,Link
,TcDataLink
- Direct Known Subclasses:
UdpTcFrameLink
public abstract class AbstractTcFrameLink extends AbstractLink implements AggregatedDataLink, TcDataLink
Sends TC as TC frames (CCSDS 232.0-B-3) or TC frames embedded in CLTU (CCSDS 231.0-B-3).
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.yamcs.tctm.Link
Link.Status
-
-
Field Summary
Fields Modifier and Type Field Description protected CltuGenerator
cltuGenerator
protected CommandHistoryPublisher
commandHistoryPublisher
protected int
frameCount
protected MasterChannelFrameMultiplexer
multiplexer
-
Fields inherited from class org.yamcs.tctm.AbstractLink
config, disabled, eventProducer, linkName, log, timeService, yamcsInstance
-
-
Constructor Summary
Constructors Constructor Description AbstractTcFrameLink()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
ackBypassFrame(TcTransferFrame tf)
Ack the BD frames Note: the AD frames are acknowledged in the when the COP1 ack is receivedprotected void
failBypassFrame(TcTransferFrame tf, String reason)
long
getDataInCount()
long
getDataOutCount()
List<Link>
getSubLinks()
void
init(String yamcsInstance, String linkName, YConfiguration config)
Called at startup to initialize the link.void
resetCounters()
void
sendTc(PreparedCommand preparedCommand)
void
setCommandHistoryPublisher(CommandHistoryPublisher commandHistoryPublisher)
-
Methods inherited from class org.yamcs.tctm.AbstractLink
collectSystemParameters, connectionStatus, disable, doDisable, doEnable, enable, getConfig, getCurrentTime, getDetailedStatus, getEventLoop, getLinkStatus, getName, getSystemParameters, isDisabled, isRunningAndEnabled, setupSystemParameters
-
Methods inherited from class com.google.common.util.concurrent.AbstractService
addListener, awaitRunning, awaitRunning, awaitTerminated, awaitTerminated, doStart, doStop, failureCause, isRunning, notifyFailed, notifyStarted, notifyStopped, startAsync, state, stopAsync, toString
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.yamcs.tctm.Link
disable, enable, getConfig, getDetailedStatus, getLinkStatus, getName, getParent, getSpec, isDisabled, setParent, setupSystemParameters
-
-
-
-
Field Detail
-
frameCount
protected int frameCount
-
multiplexer
protected MasterChannelFrameMultiplexer multiplexer
-
commandHistoryPublisher
protected CommandHistoryPublisher commandHistoryPublisher
-
cltuGenerator
protected CltuGenerator cltuGenerator
-
-
Method Detail
-
init
public void init(String yamcsInstance, String linkName, YConfiguration config)
Description copied from interface:Link
Called at startup to initialize the link.The config corresponds to the map that is under the link definition in yamcs.instance.yaml.
- Specified by:
init
in interfaceLink
- Overrides:
init
in classAbstractLink
config
- - the configuration - cannot be null (but can be empty)
-
getDataInCount
public long getDataInCount()
- Specified by:
getDataInCount
in interfaceLink
-
getDataOutCount
public long getDataOutCount()
- Specified by:
getDataOutCount
in interfaceLink
-
resetCounters
public void resetCounters()
- Specified by:
resetCounters
in interfaceLink
-
getSubLinks
public List<Link> getSubLinks()
- Specified by:
getSubLinks
in interfaceAggregatedDataLink
-
setCommandHistoryPublisher
public void setCommandHistoryPublisher(CommandHistoryPublisher commandHistoryPublisher)
- Specified by:
setCommandHistoryPublisher
in interfaceTcDataLink
-
sendTc
public void sendTc(PreparedCommand preparedCommand)
- Specified by:
sendTc
in interfaceTcDataLink
-
ackBypassFrame
protected void ackBypassFrame(TcTransferFrame tf)
Ack the BD frames Note: the AD frames are acknowledged in the when the COP1 ack is received- Parameters:
tf
-
-
failBypassFrame
protected void failBypassFrame(TcTransferFrame tf, String reason)
-
-