#include <uw-csma-aloha-trigger-sink.h>
|
| enum | UW_CS_ALOHA_TRIG_SINK_STATUS {
UW_CS_ALOHA_TRIG_SINK_STATE_IDLE = 1
, UW_CS_ALOHA_TRIG_SINK_STATE_NOT_SET
, UW_CS_ALOHA_TRIG_SINK_STATE_TX_TRIGGER
, UW_CS_ALOHA_TRIG_SINK_STATE_ENABLE_RX
,
UW_CS_ALOHA_TRIG_SINK_STATE_DISABLE_RX
, UW_CS_ALOHA_TRIG_SINK_STATE_DATA_RX
} |
| |
| enum | UW_CS_ALOHA_TRIG_SINK_REASON_STATUS {
UW_CS_ALOHA_TRIG_SINK_REASON_DATA_RX = 1
, UW_CS_ALOHA_TRIG_SINK_REASON_NOT_SET
, UW_CS_ALOHA_TRIG_SINK_REASON_START_RX
, UW_CS_ALOHA_TRIG_SINK_REASON_PKT_NOT_FOR_ME
,
UW_CS_ALOHA_TRIG_SINK_REASON_PKT_ERROR
, UW_CS_ALOHA_TRIG_SINK_REASON_TX_TRIGGER
} |
| |
| enum | UW_CS_ALOHA_TRIG_SINK_TIMER_STATUS { UW_CS_ALOHA_TRIG_SINK_IDLE = 1
, UW_CS_ALOHA_TRIG_SINK_RUNNING
, UW_CS_ALOHA_TRIG_SINK_FROZEN
, UW_CS_ALOHA_TRIG_SINK_EXPIRED
} |
| |
Class that describes a UwCsmaAloha_Trigger_SINK module
◆ UW_CS_ALOHA_TRIG_SINK_REASON_STATUS
| Enumerator |
|---|
| UW_CS_ALOHA_TRIG_SINK_REASON_DATA_RX | |
| UW_CS_ALOHA_TRIG_SINK_REASON_NOT_SET | |
| UW_CS_ALOHA_TRIG_SINK_REASON_START_RX | |
| UW_CS_ALOHA_TRIG_SINK_REASON_PKT_NOT_FOR_ME | |
| UW_CS_ALOHA_TRIG_SINK_REASON_PKT_ERROR | |
| UW_CS_ALOHA_TRIG_SINK_REASON_TX_TRIGGER | |
◆ UW_CS_ALOHA_TRIG_SINK_STATUS
< Variable that rapresent the status of the protocol machine state
| Enumerator |
|---|
| UW_CS_ALOHA_TRIG_SINK_STATE_IDLE | |
| UW_CS_ALOHA_TRIG_SINK_STATE_NOT_SET | |
| UW_CS_ALOHA_TRIG_SINK_STATE_TX_TRIGGER | |
| UW_CS_ALOHA_TRIG_SINK_STATE_ENABLE_RX | |
| UW_CS_ALOHA_TRIG_SINK_STATE_DISABLE_RX | |
| UW_CS_ALOHA_TRIG_SINK_STATE_DATA_RX | |
◆ UW_CS_ALOHA_TRIG_SINK_TIMER_STATUS
| Enumerator |
|---|
| UW_CS_ALOHA_TRIG_SINK_IDLE | |
| UW_CS_ALOHA_TRIG_SINK_RUNNING | |
| UW_CS_ALOHA_TRIG_SINK_FROZEN | |
| UW_CS_ALOHA_TRIG_SINK_EXPIRED | |
◆ UwCsmaAloha_Trigger_SINK()
| UwCsmaAloha_Trigger_SINK::UwCsmaAloha_Trigger_SINK |
( |
| ) |
|
◆ ~UwCsmaAloha_Trigger_SINK()
| UwCsmaAloha_Trigger_SINK::~UwCsmaAloha_Trigger_SINK |
( |
| ) |
|
|
virtual |
◆ command()
| int UwCsmaAloha_Trigger_SINK::command |
( |
int |
argc, |
|
|
const char *const * |
argv |
|
) |
| |
|
virtual |
TCL command interpreter. It implements the following OTcl methods:
- Parameters
-
| argc | Number of arguments in argv. |
| argv | Array of strings which are the command parameters (Note that argv[0] is the name of the object). |
- Returns
- TCL_OK or TCL_ERROR whether the command has been dispatched successfully or not.
References getTriggerMsgSent(), and stateIdle().
◆ crLayCommand()
| int UwCsmaAloha_Trigger_SINK::crLayCommand |
( |
ClMessage * |
m | ) |
|
|
virtual |
Cross-Layer messages interpreter
- Parameters
-
| ClMessage* | an instance of ClMessage that represent the message received |
- Returns
- 0 if successful.
◆ getTriggerMsgSent()
| int UwCsmaAloha_Trigger_SINK::getTriggerMsgSent |
( |
| ) |
|
|
inlineprotected |
Return the number of TRIGGER packets sent over the simulation
- Returns
- number of trigger packets over the simulation
References trigger_pkts_tx.
Referenced by command().
◆ incrTRIGGERPacketTx()
| void UwCsmaAloha_Trigger_SINK::incrTRIGGERPacketTx |
( |
| ) |
|
|
inlineprotected |
◆ incrUpperDataRx()
| virtual void UwCsmaAloha_Trigger_SINK::incrUpperDataRx |
( |
| ) |
|
|
inlineprotectedvirtual |
Increment the number of Data received from upper layers
◆ initPkt()
| void UwCsmaAloha_Trigger_SINK::initPkt |
( |
Packet * |
p, |
|
|
int |
dest_addr = 0 |
|
) |
| |
|
protectedvirtual |
◆ Mac2PhyStartTx()
| void UwCsmaAloha_Trigger_SINK::Mac2PhyStartTx |
( |
Packet * |
p | ) |
|
|
protectedvirtual |
Pass the packet to the PHY layer
- Parameters
-
| Packet* | pointer to the packet received |
Referenced by txTRIGGER().
◆ Phy2MacEndRx()
| void UwCsmaAloha_Trigger_SINK::Phy2MacEndRx |
( |
Packet * |
p | ) |
|
|
protectedvirtual |
◆ Phy2MacEndTx()
| void UwCsmaAloha_Trigger_SINK::Phy2MacEndTx |
( |
const Packet * |
p | ) |
|
|
protectedvirtual |
◆ Phy2MacStartRx()
| void UwCsmaAloha_Trigger_SINK::Phy2MacStartRx |
( |
const Packet * |
p | ) |
|
|
protectedvirtual |
◆ recvFromUpperLayers()
| void UwCsmaAloha_Trigger_SINK::recvFromUpperLayers |
( |
Packet * |
p | ) |
|
|
protectedvirtual |
Receives the packet from the upper layer (e.g. IP)
- Parameters
-
| Packet* | pointer to the packet received |
◆ refreshReason()
◆ refreshState()
◆ stateDisableRx()
| void UwCsmaAloha_Trigger_SINK::stateDisableRx |
( |
| ) |
|
|
protectedvirtual |
◆ stateEnableRx()
| void UwCsmaAloha_Trigger_SINK::stateEnableRx |
( |
| ) |
|
|
protectedvirtual |
◆ stateIdle()
| void UwCsmaAloha_Trigger_SINK::stateIdle |
( |
| ) |
|
|
protectedvirtual |
◆ stateRxData()
| void UwCsmaAloha_Trigger_SINK::stateRxData |
( |
Packet * |
p | ) |
|
|
protectedvirtual |
◆ stateRxPacketNotForMe()
| void UwCsmaAloha_Trigger_SINK::stateRxPacketNotForMe |
( |
Packet * |
p | ) |
|
|
protectedvirtual |
The destination address of the packet is not equal to the sink's address
Referenced by Phy2MacEndRx().
◆ stateTxTRIGGER()
| void UwCsmaAloha_Trigger_SINK::stateTxTRIGGER |
( |
| ) |
|
|
protectedvirtual |
◆ txTRIGGER()
| void UwCsmaAloha_Trigger_SINK::txTRIGGER |
( |
Packet * |
p | ) |
|
|
protectedvirtual |
◆ waitForUser()
| void UwCsmaAloha_Trigger_SINK::waitForUser |
( |
| ) |
|
|
protectedvirtual |
Used for debug purposes. Wait until the user press a key
◆ buffer_pkts
| int UwCsmaAloha_Trigger_SINK::buffer_pkts |
|
protected |
Length of data packet queue
◆ curr_state
◆ last_reason
Last reason of the state change of the protocol
Referenced by refreshReason().
◆ prev_state
Previous state of the protocol
◆ receive_timer
◆ receiving_state_active
| bool UwCsmaAloha_Trigger_SINK::receiving_state_active |
|
protected |
◆ trigger_pkts_tx
| int UwCsmaAloha_Trigger_SINK::trigger_pkts_tx |
|
protected |
◆ TRIGGER_size
| int UwCsmaAloha_Trigger_SINK::TRIGGER_size |
|
protected |
◆ tx_timer_duration
| double UwCsmaAloha_Trigger_SINK::tx_timer_duration |
|
protected |
The documentation for this class was generated from the following files: