Embedded TCP/IP stack
4.1.0
|
fnet_netif.h
246 void fnet_netif_get_name( fnet_netif_desc_t netif_desc, fnet_char_t *name, fnet_size_t name_size );
304 void fnet_netif_set_ip4_addr( fnet_netif_desc_t netif_desc, fnet_ip4_addr_t ipaddr, fnet_ip4_addr_t subnet_mask);
339 void fnet_netif_set_ip4_subnet_mask( fnet_netif_desc_t netif_desc, fnet_ip4_addr_t subnet_mask );
466 fnet_return_t fnet_netif_set_hw_addr( fnet_netif_desc_t netif_desc, fnet_uint8_t *hw_addr, fnet_size_t hw_addr_size );
496 fnet_return_t fnet_netif_get_hw_addr( fnet_netif_desc_t netif_desc, fnet_uint8_t *hw_addr, fnet_size_t hw_addr_size );
556 void fnet_netif_set_ip4_addr_type( fnet_netif_desc_t netif_desc, fnet_netif_ip_addr_type_t ipaddr_type );
598 fnet_return_t fnet_netif_get_statistics( fnet_netif_desc_t netif_desc, struct fnet_netif_statistics *statistics );
629 void fnet_netif_set_callback_on_ip4_addr_conflict (fnet_netif_callback_ip4_addr_conflict_t callback);
696 void fnet_netif_join_ip4_multicast ( fnet_netif_desc_t netif_desc, fnet_ip4_addr_t multicast_addr );
717 void fnet_netif_leave_ip4_multicast ( fnet_netif_desc_t netif_desc, fnet_ip4_addr_t multicast_addr );
744 void fnet_netif_join_ip6_multicast ( fnet_netif_desc_t netif_desc, const fnet_ip6_addr_t *multicast_addr );
764 void fnet_netif_leave_ip6_multicast ( fnet_netif_desc_t netif_desc, fnet_ip6_addr_t *multicast_addr );
786 fnet_bool_t fnet_netif_get_ip6_addr ( fnet_netif_desc_t netif_desc, fnet_index_t n, fnet_netif_ip6_addr_info_t *addr_info );
811 fnet_bool_t fnet_netif_get_ip6_dns( fnet_netif_desc_t netif_desc, fnet_index_t n, fnet_ip6_addr_t *addr_dns );
846 fnet_return_t fnet_netif_bind_ip6_addr(fnet_netif_desc_t netif_desc, const fnet_ip6_addr_t *addr, fnet_netif_ip_addr_type_t addr_type);
867 fnet_return_t fnet_netif_unbind_ip6_addr(fnet_netif_desc_t netif_desc, const fnet_ip6_addr_t *addr);
890 fnet_bool_t fnet_netif_get_ip6_prefix( fnet_netif_desc_t netif_desc, fnet_index_t n, fnet_netif_ip6_prefix_t *ip6_prefix);
913 fnet_bool_t fnet_netif_get_ip6_neighbor_cache(fnet_netif_desc_t netif_desc, fnet_index_t n, fnet_netif_ip6_neighbor_cache_t *ip6_neighbor_cache );
1017 fnet_return_t fnet_netif_init(fnet_netif_desc_t netif_desc, fnet_uint8_t *hw_addr, fnet_size_t hw_addr_size );
fnet_netif_desc_t fnet_netif_get_by_name(const fnet_char_t *name)
Looks for a network interface according to the specified name.
struct fnet_netif_ip6_addr_info fnet_netif_ip6_addr_info_t
Interface IPv6 address information structure.
struct fnet_netif_ip6_prefix fnet_netif_ip6_prefix_t
Interface IPv6 Prefix structure.
fnet_scope_id_t fnet_netif_get_scope_id(fnet_netif_desc_t netif_desc)
Retrieves an Scope ID of the specified network interface.
struct fnet_netif_ip6_neighbor_cache fnet_netif_ip6_neighbor_cache_t
Interface IPv6 Neighbor Cache structure.
fnet_netif_ip_addr_type_t fnet_netif_get_ip4_addr_type(fnet_netif_desc_t netif_desc)
Determines the way IPv4 address parameters were obtained.
fnet_netif_desc_t fnet_netif_get_default(void)
Retrieves the default network interface.
fnet_ip4_addr_t fnet_netif_get_ip4_dns(fnet_netif_desc_t netif_desc)
Retrieves the DNS server IP address of the specified network interface.
fnet_uint32_t fnet_scope_id_t
cope zone index type, defining network interface.
Definition: fnet_socket.h:144
fnet_ip4_addr_t fnet_netif_get_ip4_subnet_mask(fnet_netif_desc_t netif_desc)
Retrieves a subnet mask of the specified network interface.
fnet_bool_t fnet_netif_is_initialized(fnet_netif_desc_t netif_desc)
Determines if the network interface is initialized.
fnet_return_t fnet_netif_bind_ip6_addr(fnet_netif_desc_t netif_desc, const fnet_ip6_addr_t *addr, fnet_netif_ip_addr_type_t addr_type)
Binds the IPv6 address to the specified network interface.
fnet_netif_ll_addr_t ll_addr
Its link-layer address. Actual size is defiined by ll_addr_size.
Definition: fnet_netif.h:153
fnet_size_t prefix_length
Prefix length (in bits). The number of leading bits in the Prefix that are valid. ...
Definition: fnet_netif.h:142
fnet_netif_type_t fnet_netif_get_type(fnet_netif_desc_t netif_desc)
Retrieves the type of the specified network interface.
fnet_return_t fnet_netif_unbind_ip6_addr(fnet_netif_desc_t netif_desc, const fnet_ip6_addr_t *addr)
Unbinds the IPv6 address from the specified network interface.
void fnet_netif_leave_ip6_multicast(fnet_netif_desc_t netif_desc, fnet_ip6_addr_t *multicast_addr)
Leaves the specified network interface from IPv6 multicast group.
Preferred address - (RFC4862) an address assigned to an interface whose use by upper-layer protocols ...
Definition: fnet_netif.h:106
The address is set using "Auto-IP" link-local autoconfiguration.
Definition: fnet_netif.h:120
fnet_bool_t fnet_netif_get_ip6_neighbor_cache(fnet_netif_desc_t netif_desc, fnet_index_t n, fnet_netif_ip6_neighbor_cache_t *ip6_neighbor_cache)
Retrieves the n-th IPv6 neighbor cache entry of the specified network interface.
void fnet_netif_set_ip4_addr(fnet_netif_desc_t netif_desc, fnet_ip4_addr_t ipaddr, fnet_ip4_addr_t subnet_mask)
Sets the IPv4 address of the specified network interface.
unsigned long fnet_size_t
Unsigned integer type representing the size in bytes.
Definition: fnet_stdlib.h:56
fnet_return_t fnet_netif_set_hw_addr(fnet_netif_desc_t netif_desc, fnet_uint8_t *hw_addr, fnet_size_t hw_addr_size)
Sets the hardware address of the specified network interface.
void fnet_netif_set_default(fnet_netif_desc_t netif_desc)
Assigns the default network interface.
fnet_bool_t fnet_netif_get_ip6_addr(fnet_netif_desc_t netif_desc, fnet_index_t n, fnet_netif_ip6_addr_info_t *addr_info)
Retrieves an IPv6 address of the specified network interface.
void fnet_netif_get_name(fnet_netif_desc_t netif_desc, fnet_char_t *name, fnet_size_t name_size)
Retrieves a name of the specified network interface.
fnet_ip4_addr_t fnet_netif_get_ip4_addr(fnet_netif_desc_t netif_desc)
Retrieves an IPv4 address of the specified network interface.
fnet_return_t fnet_netif_init(fnet_netif_desc_t netif_desc, fnet_uint8_t *hw_addr, fnet_size_t hw_addr_size)
Initializes network interface and adds it to FNET stack.
void fnet_netif_join_ip4_multicast(fnet_netif_desc_t netif_desc, fnet_ip4_addr_t multicast_addr)
Joins the specified network interface to IPv4 multicast group.
void fnet_netif_join_ip6_multicast(fnet_netif_desc_t netif_desc, const fnet_ip6_addr_t *multicast_addr)
Joins the specified network interface to IPv6 multicast group.
void fnet_netif_set_ip4_subnet_mask(fnet_netif_desc_t netif_desc, fnet_ip4_addr_t subnet_mask)
Sets the subnet mask of the specified network interface.
fnet_netif_desc_t fnet_netif_get_by_scope_id(fnet_scope_id_t scope_id)
Looks for a network interface according to the specified Scope ID.
void fnet_netif_clear_ip4_addr_conflict(fnet_netif_desc_t netif_desc)
Clears IPv4 address conflict flag.
Network interface statistics, used by the fnet_netif_get_statistics().
Definition: fnet_netif.h:57
fnet_return_t fnet_netif_get_hw_addr(fnet_netif_desc_t netif_desc, fnet_uint8_t *hw_addr, fnet_size_t hw_addr_size)
Retrieves a hardware address of the specified network interface.
Tentative address - (RFC4862) an address whose uniqueness on a link is being verified, prior to its assignment to an interface. A tentative address is not considered assigned to an interface in the usual sense. An interface discards received packets addressed to a tentative address, but accepts Neighbor Discovery packets related to Duplicate Address Detection for the tentative address.
Definition: fnet_netif.h:99
fnet_uint8_t fnet_netif_ll_addr_t[FNET_NETIF_LL_ADDR_MAX]
Link-layer address. For example, Ethernet interafce uses the address with size set to 6...
Definition: fnet_netif.h:78
void fnet_netif_leave_ip4_multicast(fnet_netif_desc_t netif_desc, fnet_ip4_addr_t multicast_addr)
Leaves the specified network interface from IPv4 multicast group.
void fnet_netif_set_ip4_gateway(fnet_netif_desc_t netif_desc, fnet_ip4_addr_t gw)
Sets the gateway IP address of the specified network interface.
void fnet_netif_set_ip4_dns(fnet_netif_desc_t netif_desc, fnet_ip4_addr_t dns)
Sets the DNS server IPv4 address of the specified network interface.
fnet_bool_t fnet_netif_get_ip6_dns(fnet_netif_desc_t netif_desc, fnet_index_t n, fnet_ip6_addr_t *addr_dns)
Retrieves the n-th DNS IPv6 address of the specified network interface.
fnet_netif_desc_t fnet_netif_get_by_sockaddr(const struct fnet_sockaddr *addr)
Looks for a network interface according to the specified socket address.
fnet_ip4_addr_t fnet_netif_get_ip4_gateway(fnet_netif_desc_t netif_desc)
Retrieves a gateway IPv4 address of the specified network interface.
fnet_bool_t is_router
A flag indicating whether the neighbor is a router (FNET_TRUE) or a host (FNET_FALSE).
Definition: fnet_netif.h:155
fnet_bool_t fnet_netif_get_ip6_prefix(fnet_netif_desc_t netif_desc, fnet_index_t n, fnet_netif_ip6_prefix_t *ip6_prefix)
Retrieves the n-th IPv6 prefix of the specified network interface.
void fnet_netif_release(fnet_netif_desc_t netif_desc)
Releases network interface and removes it from FNET stack.
fnet_bool_t fnet_netif_is_connected(fnet_netif_desc_t netif_desc)
Determines the link status of the network interface.
fnet_return_t fnet_netif_get_statistics(fnet_netif_desc_t netif_desc, struct fnet_netif_statistics *statistics)
Retrieves the network interface statistics.
fnet_size_t fnet_netif_get_mtu(fnet_netif_desc_t netif_desc)
Retrieves a Maximum Transmission Unit (MTU) of the specified network interface.
fnet_netif_desc_t fnet_netif_get_by_number(fnet_index_t n)
Looks for a network interface according to its number.
void fnet_netif_set_ip4_addr_type(fnet_netif_desc_t netif_desc, fnet_netif_ip_addr_type_t ipaddr_type)
Sets the way IPv4 address parameters were obtained.
fnet_bool_t fnet_netif_is_ip4_addr_conflict(fnet_netif_desc_t netif_desc)
Determines if there is IPv4 address conflict.
fnet_netif_desc_t fnet_netif_get_by_ip4_addr(fnet_ip4_addr_t addr)
Looks for a network interface according to the specified IPv4 address.
void fnet_netif_set_callback_on_ip4_addr_conflict(fnet_netif_callback_ip4_addr_conflict_t callback)
Registers the "IPv4 address conflict" event handler.
void(* fnet_netif_callback_ip4_addr_conflict_t)(fnet_netif_desc_t netif)
Event handler callback function prototype, that is called when there is an IP address conflict with a...
Definition: fnet_netif.h:610
© 2005-2018 by Andrey Butok. http://fnet.sourceforge.net