DESERT 3.5.1
Loading...
Searching...
No Matches
MS2C_Evo_lowlev Class Reference

#include <mS2C_Evo_lowlev.h>

Inheritance diagram for MS2C_Evo_lowlev:
Collaboration diagram for MS2C_Evo_lowlev:

Public Member Functions

 MS2C_Evo_lowlev (std::string)
 
virtual int recvSyncClMsg (ClMessage *m)
 
virtual modem_state_t check_modem ()
 
 ~MS2C_Evo_lowlev ()
 
- Public Member Functions inherited from UWMPhy_modem
 UWMPhy_modem (std::string)
 
 ~UWMPhy_modem ()
 
virtual void recv (Packet *)
 
virtual int command (int, const char *const *)
 
int getID ()
 
double getPeriod ()
 
std::string getPathToDevice ()
 
uint getQueueLength ()
 
int getDebug ()
 
std::string getLogFile ()
 
log_level_t getLogLevel ()
 
unsigned long int getEpoch ()
 
void updatePktRx (Packet *)
 
 UWMPhy_modem (std::string)
 
 ~UWMPhy_modem ()
 
virtual void recv (Packet *)
 
virtual int command (int, const char *const *)
 
int getID ()
 
double getPeriod ()
 
std::string getPathToDevice ()
 
uint getQueueLength ()
 
int getDebug ()
 
std::string getLogFile ()
 
log_level_t getLogLevel ()
 
unsigned long int getEpoch ()
 
void updatePktRx (Packet *)
 

Private Attributes

CheckTimer checkTmr
 
DropTimer dropTmr
 
MdriverS2C_Evo_lowlev mDriver
 
int bitrate_i
 
int SL
 
int msg_bitlen
 

Additional Inherited Members

- Protected Member Functions inherited from UWMPhy_modem
void setConnections (CheckTimer *, UWMdriver *, DropTimer *)
 
virtual void start ()
 
virtual void stop ()
 
virtual void startTx (Packet *)
 
virtual void endTx (Packet *)
 
virtual void startRx (Packet *)
 
virtual void endRx (Packet *)
 
Packet * popTxBuff ()
 
virtual double getTxDuration (Packet *p)
 
virtual int getModulationType (Packet *p)
 
void setConnections (CheckTimer *, UWMdriver *, DropTimer *)
 
virtual void start ()
 
virtual void stop ()
 
virtual void startTx (Packet *)
 
virtual void endTx (Packet *)
 
virtual void startRx (Packet *)
 
virtual void endRx (Packet *)
 
Packet * popTxBuff ()
 
virtual double getTxDuration (Packet *p)
 
virtual int getModulationType (Packet *p)
 
- Protected Attributes inherited from UWMPhy_modem
CheckTimerpcheckTmr
 
UWMdriverpmDriver
 
DropTimerpDropTimer
 
int ID
 
double period
 
Packet * modemTxBuff [_MTBL]
 
int t
 
Packet * PktRx
 
std::string pToDevice
 
int debug_
 
std::ofstream outLog
 
std::string logFile
 
char * log_suffix
 
int loglevel_
 
int SetModemID
 
uint queue_length
 

Detailed Description

Class that implements the interface between ns2/NS-Miracle and the S2C EvoLogics modem using low level firmware (it derives UWMPhy_modem).

NOTE: For tcl-user: set node($id) [new "UW/MPhy_modem/S2CLowLevel" "path to the device"] Example: in case of a modem to be connected via TCP/IP socket "path to the device" would be the application port opened via ssh, 9200

Definition at line 56 of file mS2C_Evo_lowlev.h.

Constructor & Destructor Documentation

◆ MS2C_Evo_lowlev()

MS2C_Evo_lowlev::MS2C_Evo_lowlev ( std::string  pToDevice_)

Class constructor.

Parameters
pToDevice_the path to the device that must be connected with NS-Miracle (e.g., /dev/ttyUSB0 for a serial connection)

Definition at line 62 of file mS2C_Evo_lowlev.cpp.

◆ ~MS2C_Evo_lowlev()

MS2C_Evo_lowlev::~MS2C_Evo_lowlev ( )

Class destructor.

Definition at line 79 of file mS2C_Evo_lowlev.cpp.

Member Function Documentation

◆ check_modem()

modem_state_t MS2C_Evo_lowlev::check_modem ( )
virtual

Check the state of the modem and update its status.

NOTE: Not implemented on this interface with lowlevel firmware of the modem

Returns
modem_state_t status of the modem

Implements UWMPhy_modem.

Definition at line 90 of file mS2C_Evo_lowlev.cpp.

◆ recvSyncClMsg()

int MS2C_Evo_lowlev::recvSyncClMsg ( ClMessage *  m)
virtual

Receive Sync CrossLayer Messages.

If the current type of the message is not handled by this module, will be propagated to the father class

Parameters
mpointer to the ClMessage just received
Returns
0 upon success

Implements UWMPhy_modem.

Definition at line 84 of file mS2C_Evo_lowlev.cpp.

Member Data Documentation

◆ bitrate_i

int MS2C_Evo_lowlev::bitrate_i
private

Definition at line 67 of file mS2C_Evo_lowlev.h.

◆ checkTmr

CheckTimer MS2C_Evo_lowlev::checkTmr
private

Object which schedules the check-modem events.

Definition at line 59 of file mS2C_Evo_lowlev.h.

◆ dropTmr

DropTimer MS2C_Evo_lowlev::dropTmr
private

Object which sets the modem queue to reset status.

Definition at line 61 of file mS2C_Evo_lowlev.h.

◆ mDriver

MdriverS2C_Evo_lowlev MS2C_Evo_lowlev::mDriver
private

Object which drives the modem operations.

Definition at line 64 of file mS2C_Evo_lowlev.h.

◆ msg_bitlen

int MS2C_Evo_lowlev::msg_bitlen
private

Definition at line 69 of file mS2C_Evo_lowlev.h.

◆ SL

int MS2C_Evo_lowlev::SL
private

Definition at line 68 of file mS2C_Evo_lowlev.h.


The documentation for this class was generated from the following files: