NetSim Source Code Help
Loading...
Searching...
No Matches
GSM_Channel.c File Reference
#include "main.h"
#include "GSM.h"
#include "Cellular.h"
Include dependency graph for GSM_Channel.c:

Go to the source code of this file.

Functions

int fn_NetSim_FormGSMChannel (DEVVAR_MSC *mscVar)
 
int isCellularChannelAllocated (NETSIM_ID nMSId, NETSIM_ID nInterfaceId, NETSIM_ID nApplicationId)
 

Function Documentation

◆ fn_NetSim_FormGSMChannel()

int fn_NetSim_FormGSMChannel ( DEVVAR_MSC mscVar)
This function is called from init block for allocating the channel to each BTS if the
user choice is FCA (Fixed Carreir allocation).
This function first calculate the bandwidth allocated for the GSM
Bandwidth = Maximum frequency - Minimum frequency;
After that, calculate the total no of the channel.
Total no of channel = Bandwidth * 8 * (1000/200); // KHz to MHz.
Calculate no of channel per BTS.
no of channel per BTS = (Total no of channel/no of BTS).
Initiallize the channel list.
Allocate channel to the BTS.
Set, no of busy channel = 0;
set, no of free channel = No of channel per BTS.
set, Total no of channel = No of channel per BTS.
NOTE: In netSim we have only two type of channel:
1. Random Access Channel (RACH) First channel of each BTS.
2. Traffic Channel.
------------------------------ Input parameters -----------------------------------------------
This function takes three parameters as input,
1. Minimum value of down link frequency
2. Maximum value of up link frequency.
3. No of BTS.
All these parameters are user input.
------------------------------ Output Parameters ----------------------------------------------
This function return 1 on successfull completion
#define free(p)
Definition: Memory.h:31

Definition at line 53 of file GSM_Channel.c.

◆ isCellularChannelAllocated()

int isCellularChannelAllocated ( NETSIM_ID  nMSId,
NETSIM_ID  nInterfaceId,
NETSIM_ID  nApplicationId 
)

This function is used to check whether cellular channel is allocated or not

Definition at line 129 of file GSM_Channel.c.

Here is the caller graph for this function: