NetSim Source Code Help
Loading...
Searching...
No Matches
IEEE802_11_Phy.c File Reference
#include "main.h"
#include "IEEE802_11.h"
#include "IEEE802_11_Phy.h"
#include "IEEE802_11_MAC_Frame.h"
#include "IEEE802_11_PhyFrame.h"
#include "NetSim_utility.h"
#include "Medium.h"
Include dependency graph for IEEE802_11_Phy.c:

Go to the source code of this file.

Macros

#define SPEED_OF_LIGHT   299.792458
 

Functions

double DSSSPhy_get_min_rxSensitivity ()
 
double ofdmphy_get_min_rxSensitivity (double bandwidth)
 
double HTPhy_get_min_rxSensitivity (double bandwidth, UINT NSS)
 
double fn_NetSim_IEEE802_11_GetMinRxSensitivity (NETSIM_ID txId, NETSIM_ID txIf)
 
static double calculate_propagation_delay (NetSim_PACKET *packet)
 
int fn_NetSim_IEEE802_11_PHY_Init (NETSIM_ID nDeviceId, NETSIM_ID nInterfaceId)
 
bool isMediumIdle (NETSIM_ID d, NETSIM_ID in)
 
double get_preamble_time (PIEEE802_11_PHY_VAR phy)
 
int fn_NetSim_IEEE802_11_PhyOut ()
 
int fn_NetSim_IEEE802_11_PhyIn ()
 
static void wlanphy_update_medium_param (NETSIM_ID d, NETSIM_ID in)
 
double fn_NetSim_IEEE802_11_CalculateTransmissionTime (double size, NETSIM_ID nDevId, NETSIM_ID nInterfaceId)
 
bool CheckFrequencyInterfrence (double dFrequency1, double dFrequency2, double bandwidth)
 
bool fn_NetSim_IEEE802_11_TransmitFrame (NetSim_PACKET *pstruPacket, NETSIM_ID nDevId, NETSIM_ID nInterfaceId)
 
bool fn_NetSim_IEEE802_11_TransmitBroadcastFrame (NetSim_PACKET *pstruPacket, NETSIM_ID nDevId, NETSIM_ID nInterfaceId)
 
int fn_NetSim_IEEE802_11_SetDataRate (NETSIM_ID txId, NETSIM_ID txIf, NETSIM_ID rxId, NETSIM_ID rxIf, NetSim_PACKET *packet, double time)
 

Macro Definition Documentation

◆ SPEED_OF_LIGHT

#define SPEED_OF_LIGHT   299.792458

Definition at line 37 of file IEEE802_11_Phy.c.

Function Documentation

◆ calculate_propagation_delay()

static double calculate_propagation_delay ( NetSim_PACKET packet)
static

Definition at line 38 of file IEEE802_11_Phy.c.

Here is the call graph for this function:

◆ CheckFrequencyInterfrence()

bool CheckFrequencyInterfrence ( double  dFrequency1,
double  dFrequency2,
double  bandwidth 
)

Definition at line 490 of file IEEE802_11_Phy.c.

◆ DSSSPhy_get_min_rxSensitivity()

double DSSSPhy_get_min_rxSensitivity ( )

Definition at line 215 of file IEEE802_11_DSSSPhy.c.

Here is the caller graph for this function:

◆ fn_NetSim_IEEE802_11_CalculateTransmissionTime()

double fn_NetSim_IEEE802_11_CalculateTransmissionTime ( double  size,
NETSIM_ID  nDevId,
NETSIM_ID  nInterfaceId 
)

Calculate and return Transmission time for one packet.

Definition at line 465 of file IEEE802_11_Phy.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ fn_NetSim_IEEE802_11_GetMinRxSensitivity()

double fn_NetSim_IEEE802_11_GetMinRxSensitivity ( NETSIM_ID  txId,
NETSIM_ID  txIf 
)

Definition at line 698 of file IEEE802_11_Phy.c.

Here is the call graph for this function:

◆ fn_NetSim_IEEE802_11_PHY_Init()

int fn_NetSim_IEEE802_11_PHY_Init ( NETSIM_ID  nDeviceId,
NETSIM_ID  nInterfaceId 
)
This function is used to configure the PhySical Layer parameters of device.
Configure the Preamble and PLCP header length.
Configure Control and broadcast frame data rate.
Calculate DIFS, EIFS and RIFS values.
Assign CS Threshold Value.

Definition at line 55 of file IEEE802_11_Phy.c.

Here is the call graph for this function:

◆ fn_NetSim_IEEE802_11_PhyIn()

int fn_NetSim_IEEE802_11_PhyIn ( )

Definition at line 288 of file IEEE802_11_Phy.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ fn_NetSim_IEEE802_11_PhyOut()

int fn_NetSim_IEEE802_11_PhyOut ( )

Definition at line 189 of file IEEE802_11_Phy.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ fn_NetSim_IEEE802_11_SetDataRate()

int fn_NetSim_IEEE802_11_SetDataRate ( NETSIM_ID  txId,
NETSIM_ID  txIf,
NETSIM_ID  rxId,
NETSIM_ID  rxIf,
NetSim_PACKET packet,
double  time 
)

This function used to compute the data rate with respect to the total received power set the received power value using received power range table for modulation(dbm)

Definition at line 670 of file IEEE802_11_Phy.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ fn_NetSim_IEEE802_11_TransmitBroadcastFrame()

bool fn_NetSim_IEEE802_11_TransmitBroadcastFrame ( NetSim_PACKET pstruPacket,
NETSIM_ID  nDevId,
NETSIM_ID  nInterfaceId 
)

Definition at line 591 of file IEEE802_11_Phy.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ fn_NetSim_IEEE802_11_TransmitFrame()

bool fn_NetSim_IEEE802_11_TransmitFrame ( NetSim_PACKET pstruPacket,
NETSIM_ID  nDevId,
NETSIM_ID  nInterfaceId 
)

Transmit the packet in the Medium, i.e from Physical out to Physical In. While transmitting check whether the Receiver radio state is CHANNEL_IDLE and also is the receiver is reachable, that is not an out off reach. If both condition satisfied then add the PHY IN EVENT, else drop the frame.

Definition at line 514 of file IEEE802_11_Phy.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ get_preamble_time()

double get_preamble_time ( PIEEE802_11_PHY_VAR  phy)

Definition at line 166 of file IEEE802_11_Phy.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ HTPhy_get_min_rxSensitivity()

double HTPhy_get_min_rxSensitivity ( double  bandwidth,
UINT  NSS 
)

Definition at line 1257 of file IEEE802_11_HTPhy.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ isMediumIdle()

bool isMediumIdle ( NETSIM_ID  d,
NETSIM_ID  in 
)

Definition at line 160 of file IEEE802_11_Phy.c.

Here is the call graph for this function:

◆ ofdmphy_get_min_rxSensitivity()

double ofdmphy_get_min_rxSensitivity ( double  bandwidth)

Definition at line 296 of file IEEE802.11_OFDMPhy.c.

Here is the caller graph for this function:

◆ wlanphy_update_medium_param()

static void wlanphy_update_medium_param ( NETSIM_ID  d,
NETSIM_ID  in 
)
static

Definition at line 435 of file IEEE802_11_Phy.c.

Here is the call graph for this function:
Here is the caller graph for this function: