NetSim Source Code Help
Loading...
Searching...
No Matches
UDP.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  stru_UDP_Metrics
 
struct  stru_UserDatagram_Header
 

Macros

#define _CRT_SECURE_NO_DEPRECATE
 
#define _UDP_H_
 
#define TRANSPORT_UDP_OVERHEADS   8
 UDP Over heads in bytes. More...
 
#define isUDPConfigured(d)   (DEVICE_TRXLayer(d) && DEVICE_TRXLayer(d)->isUDP)
 

Typedefs

typedef struct stru_UserDatagram_Header DATAGRAM_HEADER_UDP
 
typedef struct stru_UDP_Metrics UDP_METRICS
 

Functions

int fn_NetSim_UDP_Create_ApplicationMetrics (NETSIM_ID, unsigned short, unsigned short, NETSIM_IPAddress, NETSIM_IPAddress, UDP_METRICS **)
 
int fn_NetSim_UDP_Check_ApplicationMetrics (NETSIM_ID, NETSIM_ID, NETSIM_ID, NETSIM_IPAddress, NETSIM_IPAddress, UDP_METRICS **)
 
int fn_NetSim_UDP_Configure (void **var)
 
int fn_NetSim_UDP_Configure_F (void **var)
 
int fn_NetSim_UDP_Init ()
 
int fn_NetSim_UDP_Init_F ()
 
int fn_NetSim_UDP_Run ()
 
int fn_NetSim_UDP_Finish ()
 Function to free the UDP protocol variable and Unload the primitives. More...
 
int fn_NetSim_UDP_Finish_F ()
 
char * fn_NetSim_UDP_Trace (int nSubEvent)
 Return the subevent name with respect to the subevent number for writting event trace. More...
 
char * fn_NetSim_UDP_Trace_F (int nSubEvent)
 
int fn_NetSim_UDP_FreePacket (NetSim_PACKET *)
 Function to free the allocated memory for the UDP packet. More...
 
int fn_NetSim_UDP_FreePacket_F (NetSim_PACKET *)
 
int fn_NetSim_UDP_CopyPacket (NetSim_PACKET *, NetSim_PACKET *)
 Function to copy the UDP packet from source to destination. More...
 
int fn_NetSim_UDP_CopyPacket_F (NetSim_PACKET *, NetSim_PACKET *)
 
int fn_NetSim_UDP_Metrics (PMETRICSWRITER metricsWriter)
 Function to write UDP Metrics into Metrics.txt. More...
 
int fn_NetSim_UDP_Metrics_F (PMETRICSWRITER metricsWriter)
 
int fn_NetSim_UDP_Send_User_Datagram ()
 
int fn_NetSim_UDP_Receive_User_Datagram ()
 

Macro Definition Documentation

◆ _CRT_SECURE_NO_DEPRECATE

#define _CRT_SECURE_NO_DEPRECATE

Definition at line 33 of file UDP.h.

◆ _UDP_H_

#define _UDP_H_

Definition at line 35 of file UDP.h.

◆ isUDPConfigured

#define isUDPConfigured (   d)    (DEVICE_TRXLayer(d) && DEVICE_TRXLayer(d)->isUDP)

Definition at line 38 of file UDP.h.

◆ TRANSPORT_UDP_OVERHEADS

#define TRANSPORT_UDP_OVERHEADS   8

UDP Over heads in bytes.

Definition at line 37 of file UDP.h.

Typedef Documentation

◆ DATAGRAM_HEADER_UDP

Typedef declaration of structures

Definition at line 41 of file UDP.h.

◆ UDP_METRICS

typedef struct stru_UDP_Metrics UDP_METRICS

Definition at line 42 of file UDP.h.

Function Documentation

◆ fn_NetSim_UDP_Check_ApplicationMetrics()

int fn_NetSim_UDP_Check_ApplicationMetrics ( NETSIM_ID  ,
NETSIM_ID  ,
NETSIM_ID  ,
NETSIM_IPAddress  ,
NETSIM_IPAddress  ,
UDP_METRICS **   
)
Here is the caller graph for this function:

◆ fn_NetSim_UDP_Configure()

int fn_NetSim_UDP_Configure ( void **  var)

Function for configuring UDP parameters

This function is called by NetworkStack.dll, while configuring the device TRANSPORT layer for UDP protocol.

Definition at line 63 of file UDP.c.

Here is the call graph for this function:

◆ fn_NetSim_UDP_Configure_F()

int fn_NetSim_UDP_Configure_F ( void **  var)
Here is the caller graph for this function:

◆ fn_NetSim_UDP_CopyPacket()

int fn_NetSim_UDP_CopyPacket ( NetSim_PACKET pstruDestPacket,
NetSim_PACKET pstruSrcPacket 
)

Function to copy the UDP packet from source to destination.

This function is called by NetworkStack.dll, to free the packet of UDP protocol

Definition at line 121 of file UDP.c.

Here is the call graph for this function:

◆ fn_NetSim_UDP_CopyPacket_F()

int fn_NetSim_UDP_CopyPacket_F ( NetSim_PACKET ,
NetSim_PACKET  
)
Here is the caller graph for this function:

◆ fn_NetSim_UDP_Create_ApplicationMetrics()

int fn_NetSim_UDP_Create_ApplicationMetrics ( NETSIM_ID  ,
unsigned short  ,
unsigned short  ,
NETSIM_IPAddress  ,
NETSIM_IPAddress  ,
UDP_METRICS **   
)
Here is the caller graph for this function:

◆ fn_NetSim_UDP_Finish()

int fn_NetSim_UDP_Finish ( )

Function to free the UDP protocol variable and Unload the primitives.

This function is called by NetworkStack.dll, once simulation end to free the allocated memory for the network.

Definition at line 79 of file UDP.c.

Here is the call graph for this function:

◆ fn_NetSim_UDP_Finish_F()

int fn_NetSim_UDP_Finish_F ( )
Here is the caller graph for this function:

◆ fn_NetSim_UDP_FreePacket()

int fn_NetSim_UDP_FreePacket ( NetSim_PACKET pstruPacket)

Function to free the allocated memory for the UDP packet.

Definition at line 114 of file UDP.c.

Here is the call graph for this function:

◆ fn_NetSim_UDP_FreePacket_F()

int fn_NetSim_UDP_FreePacket_F ( NetSim_PACKET )
Here is the caller graph for this function:

◆ fn_NetSim_UDP_Init()

int fn_NetSim_UDP_Init ( )

Function for Intializing UDP protocol

This functon initializes the UDP parameters.

Definition at line 71 of file UDP.c.

Here is the call graph for this function:

◆ fn_NetSim_UDP_Init_F()

int fn_NetSim_UDP_Init_F ( )
Here is the caller graph for this function:

◆ fn_NetSim_UDP_Metrics()

int fn_NetSim_UDP_Metrics ( PMETRICSWRITER  metricsWriter)

Function to write UDP Metrics into Metrics.txt.

This function write the Metrics in Metrics.txt

Definition at line 126 of file UDP.c.

Here is the call graph for this function:

◆ fn_NetSim_UDP_Metrics_F()

int fn_NetSim_UDP_Metrics_F ( PMETRICSWRITER  metricsWriter)
Here is the caller graph for this function:

◆ fn_NetSim_UDP_Receive_User_Datagram()

int fn_NetSim_UDP_Receive_User_Datagram ( )

This function is used to receive the user datagram

Definition at line 29 of file Receive_User_Datagram.c.

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

◆ fn_NetSim_UDP_Run()

int fn_NetSim_UDP_Run ( )

Function to run UDP protocol

This function is called by NetworkStack.dll, whenever the event gets triggered
inside the NetworkStack.dll for the Transport layer UDP protocol

Definition at line 32 of file UDP.c.

Here is the call graph for this function:

◆ fn_NetSim_UDP_Send_User_Datagram()

int fn_NetSim_UDP_Send_User_Datagram ( )

This function is used to send the user datagram

Definition at line 29 of file Send_User_Datagram.c.

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

◆ fn_NetSim_UDP_Trace()

char * fn_NetSim_UDP_Trace ( int  nSubEvent)

Return the subevent name with respect to the subevent number for writting event trace.

This function is called by NetworkStack.dll, while writing the evnt trace to get the sub event as a string.

Definition at line 109 of file UDP.c.

Here is the call graph for this function:

◆ fn_NetSim_UDP_Trace_F()

char * fn_NetSim_UDP_Trace_F ( int  nSubEvent)
Here is the caller graph for this function: