91 const char *netmask,
const char *gw,
92 nsapi_ip_stack_t stack = DEFAULT_STACK,
93 bool blocking =
true) = 0;
180 virtual nsapi_error_t add_l3ip_interface(
L3IP &l3ip,
bool default_if, Interface **interface_out)
185 virtual nsapi_error_t add_ppp_interface(
PPP &ppp,
bool default_if, Interface **interface_out)
190 virtual nsapi_error_t remove_ethernet_interface(Interface **interface_out)
195 virtual nsapi_error_t remove_l3ip_interface(Interface **interface_out)
200 virtual nsapi_error_t remove_ppp_interface(Interface **interface_out)
This interface should be used to abstract low level access to networking hardware All operations rece...
This interface should be used to abstract low level access to networking hardware All operations rece...
Common interface that is shared between network devices.
Representation of a stack's view of an interface.
virtual nsapi_error_t bringup(bool dhcp, const char *ip, const char *netmask, const char *gw, nsapi_ip_stack_t stack=DEFAULT_STACK, bool blocking=true)=0
Connect the interface to the network.
virtual nsapi_error_t get_ip_address(SocketAddress *address)=0
Get the local IP address.
virtual nsapi_error_t set_ip_address(const char *ip, const char *netmask, const char *gw, uint8_t ipv6_flag)
Set IP address.
virtual nsapi_connection_status_t get_connection_status() const =0
Get the connection status.
virtual nsapi_error_t get_gateway(SocketAddress *address)=0
Writes the gateway address of the network interface into a user-supplied SocketAddress.
virtual nsapi_error_t get_ipv6_link_local_address(SocketAddress *address)
Get the IPv6 link local address.
virtual char * get_interface_name(char *buf)
Returns interface name.
virtual void attach(mbed::Callback< void(nsapi_event_t, intptr_t)> status_cb)=0
Register callback for status reporting.
virtual nsapi_error_t get_netmask(SocketAddress *address)=0
Writes the netmask of the network interface into a user-supplied SocketAddress.
virtual nsapi_error_t bringdown()=0
Disconnect interface from the network.
virtual char * get_mac_address(char *buf, nsapi_size_t buflen)=0
Return MAC address of the network interface.
mbed OS API for onboard IP stack abstraction
OnboardNetworkStack * onboardNetworkStack() final
Dynamic downcast to a OnboardNetworkStack.
static OnboardNetworkStack & get_default_instance()
Return the default on-board network stack.
virtual nsapi_error_t add_ethernet_interface(EMAC &emac, bool default_if, Interface **interface_out, NetworkInterface *user_network_interface=NULL)=0
Register a network interface with the IP stack.
Callback class based on template specialization.
signed int nsapi_error_t
Type used to represent error codes.
unsigned int nsapi_size_t
Type used to represent the size of data passed through sockets.
@ NSAPI_ERROR_UNSUPPORTED