Datasheet

Flyport Wi-Fi and Ethernet Programmer's guide framework 2.3 (rev 1.0) www.openpicus.com
Network Functions and Variables
There are more functions and system variables to control the Wi-Fi state and use the Hibernation
mode:
AppConfig is a variable which contains many network parameters. It is an APP_CONFIG struct type.
The majority of parameters are found in ETH_DEFAULT/WF_DEFAULT and in
ETH_DEFAULT/WF_CUSTOM, but the IP address of Flyport can change from its default value if DHCP
is enabled.
To access to this specific parameter, the notation AppConfig.MyIPAddr is used. This will return the
IP_ADDR variable that stores the effective value of Flyport's IP address, even if it was changed by
other devices.
To use the AppConfig.MyIPAddr values as four different bytes:
AppConfig.MyIPAddr.byte.LB
AppConfig.MyIPAddr.byte.HB
AppConfig.MyIPAddr.byte.UB
AppConfig.MyIPAddr.byte.MB
In “Helpers.c” there is also a function to convert a generic string to IP_ADDR variable.
Its statement is:
BOOL StringToIPAddress( BYTE* str, IP_ADDR* IPAddress);
This function returns TRUE if the string provided were converted to IP Address, or FALSE if the
process was concluded unsuccessfully.
To use the AppConfig.MyIPAddr byte values as a single string format, them can be converted using
the helper function
void IPAddressToString(IP_ADDR* IPAddress, char* ipString);
Flyport Wi-Fi
tWFNetwork is a structure that contains all the network parameters:
BYTE bssid [WF_BSSID_LENGTH]
CHAR ssid [WF_MAX_SSID_LENGTH+1]
UINT8 channel
UINT8 signal
BYTE security
BYTE type
UINT8 beacon
UINT8 preamble
37