|
TM STM32F4xx Libraries
v1.0.0
Libraries for STM32F4xx devices from Tilen Majerle
|
Client structure, passed as first parameter in all client based callback functions. More...
#include <tm_stm32f4_ethernet.h>
Data Fields | |
| char | name [ETHERNET_MAX_CONNECTION_NAME] |
| uint8_t | active |
| uint8_t | ip_addr [4] |
| uint16_t | port |
| uint8_t | headers_done |
| uint8_t * | active_connections_count |
| void * | user_parameters |
| struct tcp_pcb * | pcb |
| client_states | state |
| struct pbuf * | p_tx |
Client structure, passed as first parameter in all client based callback functions.
| uint8_t active |
Connection is active
| uint8_t* active_connections_count |
Pointer to number of active connections this time.
| uint8_t headers_done |
This is user defined option. When you connect to some website and receive data back, you will also get HTTP headers and your data. When receive data handler will be first called, this parameter will be set to 0. If you detect when headers are done ("\r\n\r\n" string) then you can set this parameter to 1, and it will stay 1 until connection is closed. This can be used, if you don't want to print headers to user.
| uint8_t ip_addr[4] |
IP address for our external connection
| char name[ETHERNET_MAX_CONNECTION_NAME] |
Connection name, we choose it when we call TM_ETHERNETCLIENT_Connect function
| struct pbuf* p_tx |
Pointer to current active buffer
| struct tcp_pcb* pcb |
Pointer to currently active PCB
| uint16_t port |
Port for our external connection
| client_states state |
client status
| void* user_parameters |
Pointer to user parameters for connection which are passed on "Connect" function This can be used to pass special data for your connection, which you can then easily be used in headers callback to format proper request string.