OpENer - Open Source EtherNet/IP(TM) I/O Target Stack  2.1
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
networkhandler.c File Reference
#include <string.h>
#include <stdlib.h>
#include <winsock2.h>
#include <windows.h>
#include <Ws2tcpip.h>
#include "networkhandler.h"
#include "generic_networkhandler.h"
Include dependency graph for networkhandler.c:

Go to the source code of this file.

Functions

void CloseSocketPlatform (int socket_handle)
 Platform dependent code to close a socket. More...
 
MicroSeconds getMicroSeconds ()
 
MilliSeconds GetMilliSeconds (void)
 This function shall return the current time in milliseconds relative to epoch, and shall be implemented in a port specific networkhandler. More...
 
EipStatus NetworkHandlerInitializePlatform (void)
 Executes platform dependent network handler initialization code. More...
 
int SetQosOnSocket (const int socket, CipUsint qos_value)
 
int SetSocketToNonBlocking (int socket_handle)
 

Function Documentation

void CloseSocketPlatform ( int  socket_handle)

Platform dependent code to close a socket.

Parameters
socket_handleThe socket handle to be closed

Definition at line 39 of file networkhandler.c.

MicroSeconds getMicroSeconds ( )

Definition at line 16 of file networkhandler.c.

MilliSeconds GetMilliSeconds ( void  )

This function shall return the current time in milliseconds relative to epoch, and shall be implemented in a port specific networkhandler.

Returns
Current time relative to epoch as MilliSeconds

Definition at line 27 of file networkhandler.c.

References getMicroSeconds().

Here is the call graph for this function:

EipStatus NetworkHandlerInitializePlatform ( void  )

Executes platform dependent network handler initialization code.

Returns
EipStatusOk if initialization was successful, otherwise EipStatusError

Definition at line 31 of file networkhandler.c.

References kEipStatusOk.

int SetQosOnSocket ( const int  socket,
CipUsint  qos_value 
)

Definition at line 48 of file networkhandler.c.

int SetSocketToNonBlocking ( int  socket_handle)

Definition at line 43 of file networkhandler.c.