Documentation
Includes
lwip/opt.h
#include "lwip/opt.h"
lwip/pbuf.h
#include "lwip/pbuf.h"
lwip/netif.h
#include "lwip/netif.h"
lwip/ip_addr.h
#include "lwip/ip_addr.h"
lwip/ip.h
#include "lwip/ip.h"
lwip/ip6_addr.h
#include "lwip/ip6_addr.h"
lwip/prot/udp.h
#include "lwip/prot/udp.h"
Macros
Marco LWIP_HDR_UDP_H
#define LWIP_HDR_UDP_H
Marco UDP_FLAGS_NOCHKSUM
#define UDP_FLAGS_NOCHKSUM 0x01U
Marco UDP_FLAGS_UDPLITE
#define UDP_FLAGS_UDPLITE 0x02U
Marco UDP_FLAGS_CONNECTED
#define UDP_FLAGS_CONNECTED 0x04U
Marco UDP_FLAGS_MULTICAST_LOOP
#define UDP_FLAGS_MULTICAST_LOOP 0x08U
Marco udp_flags(pcb)
#define udp_flags(pcb) ((pcb)->flags)
Marco udp_setflags(pcb, f)
#define udp_setflags(pcb, f) ((pcb)->flags = (f))
Marco udp_set_flags(pcb, set_flags)
#define udp_set_flags(pcb, set_flags) do { (pcb)->flags = (u8_t)((pcb)->flags | (set_flags)); } while(0)
Marco udp_clear_flags(pcb, clr_flags)
#define udp_clear_flags(pcb, clr_flags) do { (pcb)->flags = (u8_t)((pcb)->flags & (u8_t)(~(clr_flags) & 255)); } while(0)
Marco udp_is_flag_set(pcb, flag)
#define udp_is_flag_set(pcb, flag) (((pcb)->flags & (flag)) != 0)
Marco udp_new_ip6()
#define udp_new_ip6() udp_new_ip_type(IPADDR_TYPE_V6)
Marco udp_set_multicast_netif_addr(pcb, ip4addr)
#define udp_set_multicast_netif_addr(pcb, ip4addr) ip4_addr_copy((pcb)->mcast_ip4, *(ip4addr))
Marco udp_get_multicast_netif_addr(pcb)
#define udp_get_multicast_netif_addr(pcb) (&(pcb)->mcast_ip4)
Marco udp_set_multicast_netif_index(pcb, idx)
#define udp_set_multicast_netif_index(pcb, idx) ((pcb)->mcast_ifindex = (idx))
Marco udp_get_multicast_netif_index(pcb)
#define udp_get_multicast_netif_index(pcb) ((pcb)->mcast_ifindex)
Marco udp_set_multicast_ttl(pcb, value)
#define udp_set_multicast_ttl(pcb, value) ((pcb)->mcast_ttl = (value))
Marco udp_get_multicast_ttl(pcb)
#define udp_get_multicast_ttl(pcb) ((pcb)->mcast_ttl)
Marco udp_debug_print
#define udp_debug_print(udphdr)
Functions
Func udp_bind_netif
void udp_bind_netif (struct udp_pcb *pcb, const struct netif* netif);
Func udp_disconnect
void udp_disconnect (struct udp_pcb *pcb);
Func udp_sendto_if
err_t udp_sendto_if (struct udp_pcb *pcb, struct pbuf *p,
const ip_addr_t *dst_ip, u16_t dst_port,
struct netif *netif);
Func udp_sendto_if_src
err_t udp_sendto_if_src(struct udp_pcb *pcb, struct pbuf *p,
const ip_addr_t *dst_ip, u16_t dst_port,
struct netif *netif, const ip_addr_t *src_ip);
Func udp_sendto_if_chksum
err_t udp_sendto_if_chksum(struct udp_pcb *pcb, struct pbuf *p,
const ip_addr_t *dst_ip, u16_t dst_port,
struct netif *netif, u8_t have_chksum,
u16_t chksum);
Func udp_sendto_chksum
err_t udp_sendto_chksum(struct udp_pcb *pcb, struct pbuf *p,
const ip_addr_t *dst_ip, u16_t dst_port,
u8_t have_chksum, u16_t chksum);
Func udp_send_chksum
err_t udp_send_chksum(struct udp_pcb *pcb, struct pbuf *p,
u8_t have_chksum, u16_t chksum);
Func udp_sendto_if_src_chksum
err_t udp_sendto_if_src_chksum(struct udp_pcb *pcb, struct pbuf *p,
const ip_addr_t *dst_ip, u16_t dst_port, struct netif *netif,
u8_t have_chksum, u16_t chksum, const ip_addr_t *src_ip);
Func udp_debug_print
void udp_debug_print(struct udp_hdr *udphdr);
Func udp_netif_ip_addr_changed
void udp_netif_ip_addr_changed(const ip_addr_t* old_addr, const ip_addr_t* new_addr);
Vars
Variable udp_pcb
struct udp_pcb;
Variable udp_pcb
struct udp_pcb * udp_new (void);
Variable udp_pcb
struct udp_pcb * udp_new_ip_type(u8_t type);
Variable udp_remove
void udp_remove (struct udp_pcb *pcb);
Variable udp_bind
err_t udp_bind (struct udp_pcb *pcb, const ip_addr_t *ipaddr,
u16_t port);
Variable udp_connect
err_t udp_connect (struct udp_pcb *pcb, const ip_addr_t *ipaddr,
u16_t port);
Variable udp_recv
void udp_recv (struct udp_pcb *pcb, udp_recv_fn recv,
void *recv_arg);
Variable udp_sendto
err_t udp_sendto (struct udp_pcb *pcb, struct pbuf *p,
const ip_addr_t *dst_ip, u16_t dst_port);
Variable udp_send
err_t udp_send (struct udp_pcb *pcb, struct pbuf *p);
void udp_input (struct pbuf *p, struct netif *inp);
Variable udp_init
void udp_init (void);
Consts
Types
Typedefs
Typedef udp_recv_fn
typedef void (*udp_recv_fn)(void *arg, struct udp_pcb *pcb, struct pbuf *p,
const ip_addr_t *addr, u16_t port);