Fonctions membres publiques | Fonctions membres publiques statiques | Attributs publics statiques | Amis | Liste de tous les membres
Référence de la classe WiFiEspClass

#include <WiFiEsp.h>

Fonctions membres publiques

 WiFiEspClass ()
 
int begin (const char *ssid, const char *passphrase)
 
void config (IPAddress local_ip)
 
int disconnect (void)
 
uint8_t * macAddress (uint8_t *mac)
 
void setMacAddress (uint8_t *mac)
 
IPAddress localIP ()
 
IPAddress subnetMask ()
 
IPAddress gatewayIP ()
 
char * SSID ()
 
uint8_t * BSSID (uint8_t *bssid)
 
int32_t RSSI ()
 
uint8_t status ()
 
int8_t scanNetworks ()
 
char * SSID (uint8_t networkItem)
 
uint8_t encryptionType (uint8_t networkItem)
 
int32_t RSSI (uint8_t networkItem)
 
int beginAP (const char *ssid, uint8_t channel, const char *pwd, uint8_t enc, bool apOnly=true)
 
int beginAP (const char *ssid)
 
int beginAP (const char *ssid, uint8_t channel)
 
void configAP (IPAddress ip)
 
void reset ()
 
bool ping (const char *host)
 

Fonctions membres publiques statiques

static bool init (Stream *espSerial)
 
static bool initSerial (Stream *espSerial)
 
static char * firmwareVersion ()
 

Attributs publics statiques

static int16_t _state [MAX_SOCK_NUM] = { NA_STATE, NA_STATE, NA_STATE, NA_STATE }
 
static uint16_t _server_port [MAX_SOCK_NUM] = { 0, 0, 0, 0 }
 

Amis

class WiFiEspClient
 
class WiFiEspServer
 
class WiFiEspUDP
 

Documentation des constructeurs et destructeur

◆ WiFiEspClass()

WiFiEspClass::WiFiEspClass ( )

Documentation des fonctions membres

◆ begin()

int WiFiEspClass::begin ( const char *  ssid,
const char *  passphrase 
)

Start Wifi connection with passphrase the most secure supported mode will be automatically selected

param ssid: Pointer to the SSID string. param passphrase: Passphrase. Valid characters in a passphrase must be between ASCII 32-126 (decimal).

◆ beginAP() [1/3]

int WiFiEspClass::beginAP ( const char *  ssid,
uint8_t  channel,
const char *  pwd,
uint8_t  enc,
bool  apOnly = true 
)

Start the ESP access point.

param ssid: Pointer to the SSID string. param channel: WiFi channel (1-14) param pwd: Passphrase. Valid characters in a passphrase must be between ASCII 32-126 (decimal). param enc: encryption type (enum wl_enc_type) param apOnly: Set to false if you want to run AP and Station modes simultaneously

◆ beginAP() [2/3]

int WiFiEspClass::beginAP ( const char *  ssid)

◆ beginAP() [3/3]

int WiFiEspClass::beginAP ( const char *  ssid,
uint8_t  channel 
)

◆ BSSID()

uint8_t * WiFiEspClass::BSSID ( uint8_t *  bssid)

Return the current BSSID associated with the network. It is the MAC address of the Access Point

return: pointer to uint8_t array with length WL_MAC_ADDR_LENGTH

◆ config()

void WiFiEspClass::config ( IPAddress  local_ip)

Change Ip configuration settings disabling the DHCP client

param local_ip: Static ip configuration

◆ configAP()

void WiFiEspClass::configAP ( IPAddress  ip)

Change IP address of the AP

param ip: Static ip configuration

◆ disconnect()

int WiFiEspClass::disconnect ( void  )

Disconnect from the network

return: one value of wl_status_t enum

◆ encryptionType()

uint8_t WiFiEspClass::encryptionType ( uint8_t  networkItem)

◆ firmwareVersion()

char * WiFiEspClass::firmwareVersion ( )
static

Get firmware version

◆ gatewayIP()

IPAddress WiFiEspClass::gatewayIP ( )

Get the gateway ip address.

return: gateway ip address value

◆ init()

bool WiFiEspClass::init ( Stream espSerial)
static

Initialize the ESP module.

param espSerial: the serial interface (HW or SW) used to communicate with the ESP module

◆ initSerial()

bool WiFiEspClass::initSerial ( Stream espSerial)
static

◆ localIP()

IPAddress WiFiEspClass::localIP ( )

Get the interface IP address.

return: Ip address value

◆ macAddress()

uint8_t * WiFiEspClass::macAddress ( uint8_t *  mac)

Get the interface MAC address.

return: pointer to uint8_t array with length WL_MAC_ADDR_LENGTH

◆ ping()

bool WiFiEspClass::ping ( const char *  host)

Ping a host.

◆ reset()

void WiFiEspClass::reset ( void  )

Restart the ESP module.

◆ RSSI() [1/2]

int32_t WiFiEspClass::RSSI ( )

Return the current RSSI /Received Signal Strength in dBm) associated with the network

return: signed value

◆ RSSI() [2/2]

int32_t WiFiEspClass::RSSI ( uint8_t  networkItem)

◆ scanNetworks()

int8_t WiFiEspClass::scanNetworks ( )

◆ setMacAddress()

void WiFiEspClass::setMacAddress ( uint8_t *  mac)

◆ SSID() [1/2]

char * WiFiEspClass::SSID ( )

Return the current SSID associated with the network

return: ssid string

◆ SSID() [2/2]

char * WiFiEspClass::SSID ( uint8_t  networkItem)

◆ status()

uint8_t WiFiEspClass::status ( )

Return Connection status.

return: one of the value defined in wl_status_t see https://www.arduino.cc/en/Reference/WiFiStatus

◆ subnetMask()

IPAddress WiFiEspClass::subnetMask ( )

Get the interface subnet mask address.

return: subnet mask address value

Documentation des fonctions amies et associées

◆ WiFiEspClient

friend class WiFiEspClient
friend

◆ WiFiEspServer

friend class WiFiEspServer
friend

◆ WiFiEspUDP

friend class WiFiEspUDP
friend

Documentation des données membres

◆ _server_port

uint16_t WiFiEspClass::_server_port = { 0, 0, 0, 0 }
static

◆ _state

int16_t WiFiEspClass::_state = { NA_STATE, NA_STATE, NA_STATE, NA_STATE }
static