net.c
Go to the documentation of this file.
ARP (Address Resolution Protocol)
Helper functions for Auto-IP.
Debugging facilities.
Helper functions for DHCP client.
Helper functions for DHCP server.
Helper functions for DHCPv6 client.
DNS cache management.
DNS client (Domain Name System)
DNS-SD (DNS-Based Service Discovery)
error_t ethDropMacAddr(NetInterface *interface, const MacAddr *macAddr)
Remove a unicast/multicast address from the MAC filter table.
Definition: ethernet.c:664
void macAddrToEui64(const MacAddr *macAddr, Eui64 *interfaceId)
Map a MAC address to the IPv6 modified EUI-64 identifier.
Definition: ethernet.c:944
error_t ethAcceptMacAddr(NetInterface *interface, const MacAddr *macAddr)
Add a unicast/multicast address to the MAC filter table.
Definition: ethernet.c:594
Ethernet.
IGMP host.
IGMP router.
IGMP snooping switch.
IPv4 (Internet Protocol Version 4)
IPv4 routing.
error_t ipv4InitRouting(void)
error_t ipv6JoinMulticastGroup(NetInterface *interface, const Ipv6Addr *groupAddr)
Join an IPv6 multicast group.
Definition: ipv6.c:2035
IPv6 (Internet Protocol Version 6)
IPv6 routing.
error_t llmnrResponderInit(NetInterface *interface)
LLMNR responder initialization.
Definition: llmnr_responder.c:50
LLMNR responder (Link-Local Multicast Name Resolution)
mDNS client (Multicast DNS)
Definitions common to mDNS client and mDNS responder.
mDNS responder (Multicast DNS)
MLD (Multicast Listener Discovery for IPv6)
NBNS client (NetBIOS Name Service)
Definitions common to NBNS client and NBNS responder.
NBNS responder (NetBIOS Name Service)
NDP (Neighbor Discovery Protocol)
Router advertisement service.
void netGetDefaultSettings(NetSettings *settings)
Initialize settings with default values.
Definition: net.c:83
error_t netSetParentInterface(NetInterface *interface, NetInterface *physicalInterface)
Attach a virtual interface to a given physical interface.
Definition: net.c:765
error_t netSetDriver(NetInterface *interface, const NicDriver *driver)
Set Ethernet MAC driver.
Definition: net.c:797
error_t netSetSmiDriver(NetInterface *interface, const SmiDriver *driver)
Set SMI driver.
Definition: net.c:946
error_t netSeedRand(const uint8_t *seed, size_t length)
Seed the pseudo-random number generator.
Definition: net.c:338
error_t netInitEx(NetContext *context, const NetSettings *settings)
Initialize TCP/IP stack.
Definition: net.c:129
error_t netEnablePromiscuousMode(NetInterface *interface, bool_t enable)
Enable promiscuous mode.
Definition: net.c:1177
error_t netSetInterfaceName(NetInterface *interface, const char_t *name)
Set interface name.
Definition: net.c:638
error_t netSetExtIntDriver(NetInterface *interface, const ExtIntDriver *driver)
Set external interrupt line driver.
Definition: net.c:1026
error_t netSetVlanId(NetInterface *interface, uint16_t vlanId)
Specify VLAN identifier (802.1Q)
Definition: net.c:696
error_t netSetSpiDriver(NetInterface *interface, const SpiDriver *driver)
Set SPI driver.
Definition: net.c:976
error_t netGetEui64(NetInterface *interface, Eui64 *eui64)
Retrieve EUI-64 interface identifier.
Definition: net.c:581
error_t netSetSwitchDriver(NetInterface *interface, const SwitchDriver *driver)
Set Ethernet switch driver.
Definition: net.c:886
error_t netSetPhyDriver(NetInterface *interface, const PhyDriver *driver)
Set Ethernet PHY driver.
Definition: net.c:822
error_t netConfigInterface(NetInterface *interface)
Configure network interface.
Definition: net.c:1203
error_t netSetMacAddr(NetInterface *interface, const MacAddr *macAddr)
Set MAC address.
Definition: net.c:484
error_t netSetHostname(NetInterface *interface, const char_t *name)
Set host name.
Definition: net.c:667
error_t netSetPhyAddr(NetInterface *interface, uint8_t phyAddr)
Specify Ethernet PHY address.
Definition: net.c:852
error_t netSetUartDriver(NetInterface *interface, const UartDriver *driver)
Set UART driver.
Definition: net.c:1001
error_t netSetSwitchPort(NetInterface *interface, uint8_t port)
Specify switch port.
Definition: net.c:916
error_t netSetLinkState(NetInterface *interface, NicLinkState linkState)
Set administrative link state.
Definition: net.c:1051
error_t netSetEui64(NetInterface *interface, const Eui64 *eui64)
Set EUI-64 interface identifier.
Definition: net.c:556
error_t netSetVmanId(NetInterface *interface, uint16_t vmanId)
Specify VMAN identifier (802.1ad)
Definition: net.c:730
error_t netGetMacAddr(NetInterface *interface, MacAddr *macAddr)
Retrieve MAC address.
Definition: net.c:519
error_t netSetInterfaceId(NetInterface *interface, uint32_t id)
Set interface identifier.
Definition: net.c:613
uint32_t netGetRandRange(uint32_t min, uint32_t max)
Generate a random value in the specified range.
Definition: net.c:416
TCP/IP stack core.
void netProcessLinkChange(NetInterface *interface)
Process link state change event.
Definition: net_misc.c:198
void netGenerateRandData(uint8_t *data, size_t length)
Get a string of random data.
Definition: net_misc.c:941
uint32_t netGenerateRandRange(uint32_t min, uint32_t max)
Generate a random value in the specified range.
Definition: net_misc.c:914
NetInterface * nicGetLogicalInterface(NetInterface *interface)
Retrieve logical interface.
Definition: nic.c:52
error_t nicUpdateMacAddrFilter(NetInterface *interface)
Configure MAC address filtering.
Definition: nic.c:352
NetInterface * nicGetPhysicalInterface(NetInterface *interface)
Retrieve physical interface.
Definition: nic.c:84
bool_t osWaitForEvent(OsEvent *event, systime_t timeout)
Wait until the specified event is in the signaled state.
Definition: os_port_chibios.c:229
void osAcquireMutex(OsMutex *mutex)
Acquire ownership of the specified mutex object.
Definition: os_port_chibios.c:388
OsTaskId osCreateTask(const char_t *name, OsTaskCode taskCode, void *arg, const OsTaskParameters *params)
Create a task.
Definition: os_port_chibios.c:80
void osReleaseMutex(OsMutex *mutex)
Release ownership of the specified mutex object.
Definition: os_port_chibios.c:400
TCP/IP raw sockets.
Socket API.
String manipulation helper functions.
Helper functions for TCP.
TCP timer management.
WebSocket API (client and server)