Loading...
Searching...
No Matches
api_msg.h File Reference
`#include "lwip/opt.h"`
`#include "lwip/arch.h"`
`#include "lwip/ip_addr.h"`
`#include "lwip/err.h"`
`#include "lwip/sys.h"`
`#include "lwip/igmp.h"`
`#include "lwip/api.h"`
`#include "lwip/priv/tcpip_priv.h"`

## Data Structures

struct | api_msg
struct | dns_api_msg

## Functions

void | lwip_netconn_do_newconn (void *m)
void | lwip_netconn_do_delconn (void *m)
void | lwip_netconn_do_bind (void *m)
void | lwip_netconn_do_bind_if (void *m)
void | lwip_netconn_do_connect (void *m)
void | lwip_netconn_do_disconnect (void *m)
void | lwip_netconn_do_listen (void *m)
void | lwip_netconn_do_send (void *m)
void | lwip_netconn_do_recv (void *m)
void | lwip_netconn_do_accepted (void *m)
void | lwip_netconn_do_write (void *m)
void | lwip_netconn_do_getaddr (void *m)
void | lwip_netconn_do_close (void *m)
void | lwip_netconn_do_join_leave_group (void *m)
void | lwip_netconn_do_join_leave_group_netif (void *m)
void | lwip_netconn_do_gethostbyname (void *arg)
struct netconn * | netconn_alloc (enum netconn_type t, netconn_callback callback)
void | netconn_free (struct netconn *conn)

## Detailed Description

netconn API lwIP internal implementations (do not use in application code)

## Function Documentation

## lwip_netconn_do_accepted()

void lwip_netconn_do_accepted | ( | void * | m | ) |

Indicate that a TCP pcb has been accepted Called from netconn_accept

Parameters

  m | the api_msg pointing to the connection

## lwip_netconn_do_bind()

void lwip_netconn_do_bind | ( | void * | m | ) |

Bind a pcb contained in a netconn Called from netconn_bind.

Parameters

  m | the api_msg pointing to the connection and containing the IP address and port to bind to

## lwip_netconn_do_bind_if()

void lwip_netconn_do_bind_if | ( | void * | m | ) |

Bind a pcb contained in a netconn to an interface Called from netconn_bind_if.

Parameters

  m | the api_msg pointing to the connection and containing the IP address and port to bind to

## lwip_netconn_do_close()

void lwip_netconn_do_close | ( | void * | m | ) |

Close or half-shutdown a TCP pcb contained in a netconn Called from netconn_close In contrast to closing sockets, the netconn is not deallocated.

Parameters

  m | the api_msg pointing to the connection

## lwip_netconn_do_connect()

void lwip_netconn_do_connect | ( | void * | m | ) |

Connect a pcb contained inside a netconn Called from netconn_connect.

Parameters

  m | the api_msg pointing to the connection and containing the IP address and port to connect to

## lwip_netconn_do_delconn()

void lwip_netconn_do_delconn | ( | void * | m | ) |

Delete the pcb inside a netconn. Called from netconn_delete.

Parameters

  m | the api_msg pointing to the connection

## lwip_netconn_do_disconnect()

void lwip_netconn_do_disconnect | ( | void * | m | ) |

Disconnect a pcb contained inside a netconn Only used for UDP netconns. Called from netconn_disconnect.

Parameters

  m | the api_msg pointing to the connection to disconnect

## lwip_netconn_do_getaddr()

void lwip_netconn_do_getaddr | ( | void * | m | ) |

Return a connection's local or remote address Called from netconn_getaddr

Parameters

  m | the api_msg pointing to the connection

## lwip_netconn_do_gethostbyname()

void lwip_netconn_do_gethostbyname | ( | void * | arg | ) |

Execute a DNS query Called from netconn_gethostbyname

Parameters

  arg | the dns_api_msg pointing to the query

## lwip_netconn_do_join_leave_group()

void lwip_netconn_do_join_leave_group | ( | void * | m | ) |

Join multicast groups for UDP netconns. Called from netconn_join_leave_group

Parameters

  m | the api_msg pointing to the connection

## lwip_netconn_do_join_leave_group_netif()

void lwip_netconn_do_join_leave_group_netif | ( | void * | m | ) |

Join multicast groups for UDP netconns. Called from netconn_join_leave_group_netif

Parameters

  m | the api_msg pointing to the connection

## lwip_netconn_do_listen()

void lwip_netconn_do_listen | ( | void * | m | ) |

Set a TCP pcb contained in a netconn into listen mode Called from netconn_listen.

Parameters

  m | the api_msg pointing to the connection

## lwip_netconn_do_newconn()

void lwip_netconn_do_newconn | ( | void * | m | ) |

Create a new pcb of a specific type inside a netconn. Called from netconn_new_with_proto_and_callback.

Parameters

  m | the api_msg describing the connection type

## lwip_netconn_do_recv()

void lwip_netconn_do_recv | ( | void * | m | ) |

Indicate data has been received from a TCP pcb contained in a netconn Called from netconn_recv

Parameters

  m | the api_msg pointing to the connection

## lwip_netconn_do_send()

void lwip_netconn_do_send | ( | void * | m | ) |

Send some data on a RAW or UDP pcb contained in a netconn Called from netconn_send

Parameters

  m | the api_msg pointing to the connection

## lwip_netconn_do_write()

void lwip_netconn_do_write | ( | void * | m | ) |

Send some data on a TCP pcb contained in a netconn Called from netconn_write

Parameters

  m | the api_msg pointing to the connection

## netconn_alloc()

struct netconn * netconn_alloc | ( | enum netconn_type | t,
|  | netconn_callback | callback )

Create a new netconn (of a specific type) that has a callback function. The corresponding pcb is NOT created!

Parameters

  t | the type of 'connection' to create (

See also
  enum netconn_type)

Parameters

  callback | a function to call on status changes (RX available, TX'ed)

Returns
  a newly allocated struct netconn or NULL on memory error

## netconn_free()

void netconn_free | ( | struct netconn * | conn | ) |

Delete a netconn and all its resources. The pcb is NOT freed (since we might not be in the right thread context do this).

Parameters

  conn | the netconn to free