21 #ifndef SATELLITE_GENERIC_STREAM_ENCAPSULATOR
22 #define SATELLITE_GENERIC_STREAM_ENCAPSULATOR
26 #include <ns3/event-id.h>
27 #include <ns3/mac48-address.h>
67 Mac48Address decapAddress,
68 Mac48Address sourceE2EAddress,
69 Mac48Address destE2EAddress,
71 uint32_t additionalHeaderSize = 0);
94 virtual void EnquePdu(Ptr<Packet> p, Mac48Address dest);
105 uint32_t& nextMinTxO);
130 uint32_t maxGsePduSize,
131 uint32_t additionalHeaderSize = 0);
A base encapsulator implementation which does not support encapsulation, fragmentation or packing.
SatGenericStreamEncapsulator class is used in the FWD link for GSE encapsulation and fragmentation of...
uint32_t m_txFragmentId
Fragment id used in the packet transmissions.
static const uint32_t MAX_FRAGMENT_ID
The fragment is described with 8 bits, thus the maximum fragment id is 256.
uint32_t m_currRxPacketFragmentBytes
Currently received bytes of the fragmented packet.
virtual void DoDispose()
Dispose of this class instance.
virtual void EnquePdu(Ptr< Packet > p, Mac48Address dest)
Enqueue a Higher Layer packet to txBuffer.
void Reset()
Reset defragmentation variables.
SatGenericStreamEncapsulator()
Default constructor, not used.
static const uint32_t MAX_HL_PACKET_SIZE
The maximum packet size is described with 16 bits, thus, the maximum HL packet size is 65536 bytes.
uint32_t m_currRxFragmentId
Current fragment id in the reassembly process.
Ptr< Packet > GetNewGsePdu(uint32_t txOpportunityBytes, uint32_t maxGsePduSize, uint32_t additionalHeaderSize=0)
Get new packet performs the GSE fragmentation and encapsulation for a one single packet.
uint32_t m_currRxPacketSize
The total size of the ALPDU size reassembly process.
virtual ~SatGenericStreamEncapsulator()
Destructor for SatGenericStreamEncapsulator.
virtual Ptr< Packet > NotifyTxOpportunity(uint32_t bytes, uint32_t &bytesLeft, uint32_t &nextMinTxO)
Notify a Tx opportunity to this encapsulator.
static TypeId GetTypeId(void)
Get the type ID.
virtual void ReceivePdu(Ptr< Packet > p)
Receive a packet, thus decapsulate and defragment/deconcatenate if needed.
uint32_t m_maxGsePduSize
Maximum GSE PDU size.
virtual void ProcessPdu(Ptr< Packet > p)
Process the reception of individual GSE PDUs.
Ptr< Packet > m_currRxPacketFragment
Current packet in the reassembly process.
void IncreaseFragmentId()
Method increases the fragment id by one.
uint32_t m_minGseTxOpportunity
If the GSE opportunity is smaller than this, a NULL packet is returned.
virtual uint32_t GetMinTxOpportunityInBytes() const
Get minimum Tx opportunity in bytes, which takes the assumed header sizes into account.
SatArqSequenceNumber is handling the sequence numbers for the ARQ process.