Embedded TCP/IP stack  4.7.0
PING service API

Detailed Description

The PING service is used to test if a system can communicate over the network with another device or computer.
It operates by sending Internet Control Message Protocol (ICMPv4/v6) Echo Request messages to the destination device and waiting for a response.
After the PING service is initialized the fnet_ping_init() function, the user application should call the main service-polling function fnet_service_poll() periodically in background.
When correct echo response is received, the PING service passes an echo-reply socket address to the fnet_ping_callback_t callback function.
For the PING service usage example, refer to the FNET Shell demo source code.

Note
The PING service uses the RAW sockets.

Configuration parameters:

Data Structures

struct  fnet_ping_params_t
 Initialization parameters for the fnet_ping_init() function. More...
 

Typedefs

typedef void(* fnet_ping_callback_t) (fnet_error_t result, fnet_size_t packet_count, struct fnet_sockaddr *target_addr, void *cookie)
 Prototype of the PING-service callback function that is called when the PING-service has completed the requesting. More...
 

Functions

fnet_return_t fnet_ping_init (fnet_ping_params_t *params)
 Initializes PING service. More...
 
void fnet_ping_release (void)
 Releases the PING service. More...
 

© 2005-2020 by Andrej Butok. http://fnet.sourceforge.net