mirror of
https://github.com/nasa/fprime.git
synced 2025-12-11 23:38:06 -06:00
Add Framing subtopologies and use them within Com subtopologies (#4113)
* Update ComX subtopologies to not include ComStub and update Ref * Cosmetic updates * Working FramingCcsds subtopology used in ComCcsds * Revert Ref to use ComCcsds * Move FramingSubtopology into ComCcsds build module * Working ComFprime subtopology * Cosmetic updates * formatting
This commit is contained in:
parent
77f286f3ed
commit
d014f30a96
@ -27,8 +27,8 @@
|
|||||||
#include "Svc/Subtopologies/FileHandling/SubtopologyTopologyDefs.hpp"
|
#include "Svc/Subtopologies/FileHandling/SubtopologyTopologyDefs.hpp"
|
||||||
|
|
||||||
// ComCcsds Enum Includes
|
// ComCcsds Enum Includes
|
||||||
#include "Svc/Subtopologies/ComCcsds/Ports_ComPacketQueueEnumAc.hpp"
|
|
||||||
#include "Svc/Subtopologies/ComCcsds/Ports_ComBufferQueueEnumAc.hpp"
|
#include "Svc/Subtopologies/ComCcsds/Ports_ComBufferQueueEnumAc.hpp"
|
||||||
|
#include "Svc/Subtopologies/ComCcsds/Ports_ComPacketQueueEnumAc.hpp"
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* \brief required ping constants
|
* \brief required ping constants
|
||||||
@ -50,12 +50,24 @@
|
|||||||
* ```
|
* ```
|
||||||
*/
|
*/
|
||||||
namespace PingEntries {
|
namespace PingEntries {
|
||||||
namespace Ref_blockDrv {enum { WARN = 3, FATAL = 5 };}
|
namespace Ref_blockDrv {
|
||||||
namespace Ref_pingRcvr {enum { WARN = 3, FATAL = 5 };}
|
enum { WARN = 3, FATAL = 5 };
|
||||||
namespace Ref_rateGroup1Comp {enum { WARN = 3, FATAL = 5 };}
|
}
|
||||||
namespace Ref_rateGroup2Comp {enum { WARN = 3, FATAL = 5 };}
|
namespace Ref_pingRcvr {
|
||||||
namespace Ref_rateGroup3Comp {enum { WARN = 3, FATAL = 5 };}
|
enum { WARN = 3, FATAL = 5 };
|
||||||
namespace Ref_cmdSeq {enum { WARN = 3, FATAL = 5 };}
|
}
|
||||||
|
namespace Ref_rateGroup1Comp {
|
||||||
|
enum { WARN = 3, FATAL = 5 };
|
||||||
|
}
|
||||||
|
namespace Ref_rateGroup2Comp {
|
||||||
|
enum { WARN = 3, FATAL = 5 };
|
||||||
|
}
|
||||||
|
namespace Ref_rateGroup3Comp {
|
||||||
|
enum { WARN = 3, FATAL = 5 };
|
||||||
|
}
|
||||||
|
namespace Ref_cmdSeq {
|
||||||
|
enum { WARN = 3, FATAL = 5 };
|
||||||
|
}
|
||||||
} // namespace PingEntries
|
} // namespace PingEntries
|
||||||
|
|
||||||
// Definitions are placed within a namespace named after the deployment
|
// Definitions are placed within a namespace named after the deployment
|
||||||
|
|||||||
@ -32,7 +32,6 @@
|
|||||||
"Svc.FrameAccumulator": "Ref.frameAccumulator",
|
"Svc.FrameAccumulator": "Ref.frameAccumulator",
|
||||||
"Svc.FprimeDeframer": "Ref.deframer",
|
"Svc.FprimeDeframer": "Ref.deframer",
|
||||||
"Svc.FprimeRouter": "Ref.fprimeRouter",
|
"Svc.FprimeRouter": "Ref.fprimeRouter",
|
||||||
"Svc.FprimeFramer" : "Ref.fprimeFramer",
|
"Svc.FprimeFramer": "Ref.framer",
|
||||||
"Svc.ComStub": "Ref.comStub"
|
"Svc.ComStub": "Ref.comStub"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -90,21 +90,35 @@ module ComCcsds {
|
|||||||
"""
|
"""
|
||||||
}
|
}
|
||||||
|
|
||||||
instance fprimeRouter: Svc.FprimeRouter base id ComCcsdsConfig.BASE_ID + 0x03000 \
|
instance fprimeRouter: Svc.FprimeRouter base id ComCcsdsConfig.BASE_ID + 0x03000
|
||||||
|
|
||||||
instance comStub: Svc.ComStub base id ComCcsdsConfig.BASE_ID + 0x04000 \
|
instance tcDeframer: Svc.Ccsds.TcDeframer base id ComCcsdsConfig.BASE_ID + 0x04000
|
||||||
|
|
||||||
instance tcDeframer: Svc.Ccsds.TcDeframer base id ComCcsdsConfig.BASE_ID + 0x05000 \
|
instance spacePacketDeframer: Svc.Ccsds.SpacePacketDeframer base id ComCcsdsConfig.BASE_ID + 0x05000
|
||||||
|
# NOTE: name 'framer' is used for the framer that connects to the Com Adapter Interface for better subtopology interoperability
|
||||||
|
instance framer: Svc.Ccsds.TmFramer base id ComCcsdsConfig.BASE_ID + 0x06000
|
||||||
|
|
||||||
instance spacePacketDeframer: Svc.Ccsds.SpacePacketDeframer base id ComCcsdsConfig.BASE_ID + 0x06000 \
|
instance spacePacketFramer: Svc.Ccsds.SpacePacketFramer base id ComCcsdsConfig.BASE_ID + 0x07000
|
||||||
|
|
||||||
instance tmFramer: Svc.Ccsds.TmFramer base id ComCcsdsConfig.BASE_ID + 0x07000 \
|
instance apidManager: Svc.Ccsds.ApidManager base id ComCcsdsConfig.BASE_ID + 0x08000
|
||||||
|
|
||||||
instance spacePacketFramer: Svc.Ccsds.SpacePacketFramer base id ComCcsdsConfig.BASE_ID + 0x08000 \
|
instance comStub: Svc.ComStub base id ComCcsdsConfig.BASE_ID + 0x09000
|
||||||
|
|
||||||
|
topology FramingSubtopology {
|
||||||
|
# Usage Note:
|
||||||
|
#
|
||||||
|
# When importing this subtopology, users shall establish 5 port connections with a component implementing
|
||||||
|
# the Svc.Com (Svc/Interfaces/Com.fpp) interface. They are as follows:
|
||||||
|
#
|
||||||
|
# 1) Outputs:
|
||||||
|
# - ComCcsds.framer.dataOut -> [Svc.Com].dataIn
|
||||||
|
# - ComCcsds.frameAccumulator.dataReturnOut -> [Svc.Com].dataReturnIn
|
||||||
|
# 2) Inputs:
|
||||||
|
# - [Svc.Com].dataReturnOut -> ComCcsds.framer.dataReturnIn
|
||||||
|
# - [Svc.Com].comStatusOut -> ComCcsds.framer.comStatusIn
|
||||||
|
# - [Svc.Com].dataOut -> ComCcsds.frameAccumulator.dataIn
|
||||||
|
|
||||||
instance apidManager: Svc.Ccsds.ApidManager base id ComCcsdsConfig.BASE_ID + 0x09000 \
|
|
||||||
|
|
||||||
topology Subtopology {
|
|
||||||
# Active Components
|
# Active Components
|
||||||
instance comQueue
|
instance comQueue
|
||||||
|
|
||||||
@ -112,16 +126,13 @@ module ComCcsds {
|
|||||||
instance commsBufferManager
|
instance commsBufferManager
|
||||||
instance frameAccumulator
|
instance frameAccumulator
|
||||||
instance fprimeRouter
|
instance fprimeRouter
|
||||||
instance comStub
|
|
||||||
instance tcDeframer
|
instance tcDeframer
|
||||||
instance spacePacketDeframer
|
instance spacePacketDeframer
|
||||||
instance tmFramer
|
instance framer
|
||||||
instance spacePacketFramer
|
instance spacePacketFramer
|
||||||
instance apidManager
|
instance apidManager
|
||||||
|
|
||||||
connections Downlink {
|
connections Downlink {
|
||||||
|
|
||||||
|
|
||||||
# ComQueue <-> SpacePacketFramer
|
# ComQueue <-> SpacePacketFramer
|
||||||
comQueue.dataOut -> spacePacketFramer.dataIn
|
comQueue.dataOut -> spacePacketFramer.dataIn
|
||||||
spacePacketFramer.dataReturnOut -> comQueue.dataReturnIn
|
spacePacketFramer.dataReturnOut -> comQueue.dataReturnIn
|
||||||
@ -130,25 +141,20 @@ module ComCcsds {
|
|||||||
spacePacketFramer.bufferDeallocate -> commsBufferManager.bufferSendIn
|
spacePacketFramer.bufferDeallocate -> commsBufferManager.bufferSendIn
|
||||||
spacePacketFramer.getApidSeqCount -> apidManager.getApidSeqCountIn
|
spacePacketFramer.getApidSeqCount -> apidManager.getApidSeqCountIn
|
||||||
# SpacePacketFramer <-> TmFramer
|
# SpacePacketFramer <-> TmFramer
|
||||||
spacePacketFramer.dataOut -> tmFramer.dataIn
|
spacePacketFramer.dataOut -> framer.dataIn
|
||||||
tmFramer.dataReturnOut -> spacePacketFramer.dataReturnIn
|
framer.dataReturnOut -> spacePacketFramer.dataReturnIn
|
||||||
# Framer <-> ComStub
|
|
||||||
tmFramer.dataOut -> comStub.dataIn
|
|
||||||
comStub.dataReturnOut -> tmFramer.dataReturnIn
|
|
||||||
# ComStatus
|
# ComStatus
|
||||||
comStub.comStatusOut -> tmFramer.comStatusIn
|
framer.comStatusOut -> spacePacketFramer.comStatusIn
|
||||||
tmFramer.comStatusOut -> spacePacketFramer.comStatusIn
|
|
||||||
spacePacketFramer.comStatusOut -> comQueue.comStatusIn
|
spacePacketFramer.comStatusOut -> comQueue.comStatusIn
|
||||||
|
# (Outgoing) Framer <-> ComInterface connections shall be established by the user
|
||||||
}
|
}
|
||||||
|
|
||||||
connections Uplink {
|
connections Uplink {
|
||||||
# ComStub <-> FrameAccumulator
|
# (Incoming) ComInterface <-> FrameAccumulator connections shall be established by the user
|
||||||
comStub.dataOut -> frameAccumulator.dataIn
|
|
||||||
frameAccumulator.dataReturnOut -> comStub.dataReturnIn
|
|
||||||
# FrameAccumulator buffer allocations
|
# FrameAccumulator buffer allocations
|
||||||
frameAccumulator.bufferDeallocate -> commsBufferManager.bufferSendIn
|
frameAccumulator.bufferDeallocate -> commsBufferManager.bufferSendIn
|
||||||
frameAccumulator.bufferAllocate -> commsBufferManager.bufferGetCallee
|
frameAccumulator.bufferAllocate -> commsBufferManager.bufferGetCallee
|
||||||
# FrameAccumulator <-> Deframer
|
# FrameAccumulator <-> TcDeframer
|
||||||
frameAccumulator.dataOut -> tcDeframer.dataIn
|
frameAccumulator.dataOut -> tcDeframer.dataIn
|
||||||
tcDeframer.dataReturnOut -> frameAccumulator.dataReturnIn
|
tcDeframer.dataReturnOut -> frameAccumulator.dataReturnIn
|
||||||
# TcDeframer <-> SpacePacketDeframer
|
# TcDeframer <-> SpacePacketDeframer
|
||||||
@ -162,8 +168,25 @@ module ComCcsds {
|
|||||||
# Router buffer allocations
|
# Router buffer allocations
|
||||||
fprimeRouter.bufferAllocate -> commsBufferManager.bufferGetCallee
|
fprimeRouter.bufferAllocate -> commsBufferManager.bufferGetCallee
|
||||||
fprimeRouter.bufferDeallocate -> commsBufferManager.bufferSendIn
|
fprimeRouter.bufferDeallocate -> commsBufferManager.bufferSendIn
|
||||||
|
|
||||||
}
|
}
|
||||||
|
} # end FramingSubtopology
|
||||||
|
|
||||||
} # end topology
|
# This subtopology uses FramingSubtopology with a ComStub component for Com Interface
|
||||||
} # end ComCcsds Subtopology
|
topology Subtopology {
|
||||||
|
import FramingSubtopology
|
||||||
|
|
||||||
|
instance comStub
|
||||||
|
|
||||||
|
connections ComStub {
|
||||||
|
# Framer <-> ComStub (Downlink)
|
||||||
|
ComCcsds.framer.dataOut -> comStub.dataIn
|
||||||
|
comStub.dataReturnOut -> ComCcsds.framer.dataReturnIn
|
||||||
|
comStub.comStatusOut -> ComCcsds.framer.comStatusIn
|
||||||
|
|
||||||
|
# ComStub <-> FrameAccumulator (Uplink)
|
||||||
|
comStub.dataOut -> ComCcsds.frameAccumulator.dataIn
|
||||||
|
ComCcsds.frameAccumulator.dataReturnOut -> comStub.dataReturnIn
|
||||||
|
}
|
||||||
|
} # end Subtopology
|
||||||
|
|
||||||
|
} # end ComCcsds
|
||||||
|
|||||||
@ -86,15 +86,28 @@ module ComFprime {
|
|||||||
"""
|
"""
|
||||||
}
|
}
|
||||||
|
|
||||||
instance deframer: Svc.FprimeDeframer base id ComFprimeConfig.BASE_ID + 0x03000 \
|
instance deframer: Svc.FprimeDeframer base id ComFprimeConfig.BASE_ID + 0x03000
|
||||||
|
|
||||||
instance fprimeFramer: Svc.FprimeFramer base id ComFprimeConfig.BASE_ID + 0x04000 \
|
instance framer: Svc.FprimeFramer base id ComFprimeConfig.BASE_ID + 0x04000
|
||||||
|
|
||||||
instance fprimeRouter: Svc.FprimeRouter base id ComFprimeConfig.BASE_ID + 0x05000 \
|
instance fprimeRouter: Svc.FprimeRouter base id ComFprimeConfig.BASE_ID + 0x05000
|
||||||
|
|
||||||
instance comStub: Svc.ComStub base id ComFprimeConfig.BASE_ID + 0x06000 \
|
instance comStub: Svc.ComStub base id ComFprimeConfig.BASE_ID + 0x06000
|
||||||
|
|
||||||
|
topology FramingSubtopology {
|
||||||
|
# Usage Note:
|
||||||
|
#
|
||||||
|
# When importing this subtopology, users shall establish 5 port connections with a component implementing
|
||||||
|
# the Svc.Com (Svc/Interfaces/Com.fpp) interface. They are as follows:
|
||||||
|
#
|
||||||
|
# 1) Outputs:
|
||||||
|
# - ComFprime.framer.dataOut -> [Svc.Com].dataIn
|
||||||
|
# - ComFprime.frameAccumulator.dataReturnOut -> [Svc.Com].dataReturnIn
|
||||||
|
# 2) Inputs:
|
||||||
|
# - [Svc.Com].dataReturnOut -> ComFprime.framer.dataReturnIn
|
||||||
|
# - [Svc.Com].comStatusOut -> ComFprime.framer.comStatusIn
|
||||||
|
# - [Svc.Com].dataOut -> ComFprime.frameAccumulator.dataIn
|
||||||
|
|
||||||
topology Subtopology {
|
|
||||||
# Active Components
|
# Active Components
|
||||||
instance comQueue
|
instance comQueue
|
||||||
|
|
||||||
@ -102,31 +115,23 @@ module ComFprime {
|
|||||||
instance commsBufferManager
|
instance commsBufferManager
|
||||||
instance frameAccumulator
|
instance frameAccumulator
|
||||||
instance deframer
|
instance deframer
|
||||||
instance fprimeFramer
|
instance framer
|
||||||
instance fprimeRouter
|
instance fprimeRouter
|
||||||
instance comStub
|
|
||||||
|
|
||||||
|
|
||||||
connections Downlink {
|
connections Downlink {
|
||||||
# Inputs to ComQueue (events, telemetry)
|
|
||||||
# ComQueue <-> Framer
|
# ComQueue <-> Framer
|
||||||
comQueue.dataOut -> fprimeFramer.dataIn
|
comQueue.dataOut -> framer.dataIn
|
||||||
fprimeFramer.dataReturnOut -> comQueue.dataReturnIn
|
framer.dataReturnOut -> comQueue.dataReturnIn
|
||||||
# Buffer Management for Framer
|
# Buffer Management for Framer
|
||||||
fprimeFramer.bufferAllocate -> commsBufferManager.bufferGetCallee
|
framer.bufferAllocate -> commsBufferManager.bufferGetCallee
|
||||||
fprimeFramer.bufferDeallocate -> commsBufferManager.bufferSendIn
|
framer.bufferDeallocate -> commsBufferManager.bufferSendIn
|
||||||
# Framer <-> ComStub
|
# ComStatus passback
|
||||||
fprimeFramer.dataOut -> comStub.dataIn
|
framer.comStatusOut -> comQueue.comStatusIn
|
||||||
comStub.dataReturnOut -> fprimeFramer.dataReturnIn
|
# (Outgoing) Framer <-> ComInterface connections shall be established by the user
|
||||||
# ComStatus
|
|
||||||
comStub.comStatusOut -> fprimeFramer.comStatusIn
|
|
||||||
fprimeFramer.comStatusOut -> comQueue.comStatusIn
|
|
||||||
}
|
}
|
||||||
|
|
||||||
connections Uplink {
|
connections Uplink {
|
||||||
# ComStub <-> FrameAccumulator
|
# (Incoming) ComInterface <-> FrameAccumulator connections shall be established by the user
|
||||||
comStub.dataOut -> frameAccumulator.dataIn
|
|
||||||
frameAccumulator.dataReturnOut -> comStub.dataReturnIn
|
|
||||||
# FrameAccumulator buffer allocations
|
# FrameAccumulator buffer allocations
|
||||||
frameAccumulator.bufferDeallocate -> commsBufferManager.bufferSendIn
|
frameAccumulator.bufferDeallocate -> commsBufferManager.bufferSendIn
|
||||||
frameAccumulator.bufferAllocate -> commsBufferManager.bufferGetCallee
|
frameAccumulator.bufferAllocate -> commsBufferManager.bufferGetCallee
|
||||||
@ -140,7 +145,25 @@ module ComFprime {
|
|||||||
fprimeRouter.bufferAllocate -> commsBufferManager.bufferGetCallee
|
fprimeRouter.bufferAllocate -> commsBufferManager.bufferGetCallee
|
||||||
fprimeRouter.bufferDeallocate -> commsBufferManager.bufferSendIn
|
fprimeRouter.bufferDeallocate -> commsBufferManager.bufferSendIn
|
||||||
}
|
}
|
||||||
|
} # end FramingSubtopology
|
||||||
|
|
||||||
|
|
||||||
} # end topology
|
# This subtopology uses FramingSubtopology with a ComStub component for Com Interface
|
||||||
} # end ComFprime Subtopology
|
topology Subtopology {
|
||||||
|
import FramingSubtopology
|
||||||
|
|
||||||
|
instance comStub
|
||||||
|
|
||||||
|
connections ComStub {
|
||||||
|
# Framer <-> ComStub (Downlink)
|
||||||
|
ComFprime.framer.dataOut -> comStub.dataIn
|
||||||
|
comStub.dataReturnOut -> ComFprime.framer.dataReturnIn
|
||||||
|
comStub.comStatusOut -> ComFprime.framer.comStatusIn
|
||||||
|
|
||||||
|
# ComStub <-> FrameAccumulator (Uplink)
|
||||||
|
comStub.dataOut -> ComFprime.frameAccumulator.dataIn
|
||||||
|
ComFprime.frameAccumulator.dataReturnOut -> comStub.dataReturnIn
|
||||||
|
}
|
||||||
|
} # end Subtopology
|
||||||
|
|
||||||
|
} # end ComFprime
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user