Skip to content

Commit 20a2010

Browse files
committedDec 10, 2024
Update documentation
1 parent 5fb1ea3 commit 20a2010

File tree

1 file changed

+47
-916
lines changed

1 file changed

+47
-916
lines changed
 

‎libraries/WiFiS3/docs/api.md

Lines changed: 47 additions & 916 deletions
Original file line numberDiff line numberDiff line change
@@ -2,881 +2,12 @@
22

33
Members | Descriptions
44
--------------------------------|---------------------------------------------
5-
`class ` [`CAccessPoint`](#class_c_access_point) |
6-
`class ` [`CWifi`](#class_c_wifi) | Class to manage Wi-Fi connectivity and operations.
7-
`class ` [`ModemClass`](#class_modem_class) | A class that provides methods to interact with a modem.
85
`class ` [`WiFiClient`](#class_wi_fi_client) | Represents a Wi-Fi client that connects to a remote server over a Wi-Fi network.
96
`class ` [`WiFiFileSystem`](#class_wi_fi_file_system) | Class that handles the WiFi file system operations.
107
`class ` [`WiFiServer`](#class_wi_fi_server) | A class that provides server functionality for WiFi-based communication.
118
`class ` [`WiFiSSLClient`](#class_wi_fi_s_s_l_client) | A specialized client class for secure SSL/TLS connections.
129
`class ` [`WiFiUDP`](#class_wi_fi_u_d_p) | A class for handling UDP communication over a Wi-Fi network.
1310

14-
# class `CAccessPoint` <a id="class_c_access_point" class="anchor"></a>
15-
16-
## Summary
17-
18-
Members | Descriptions
19-
--------------------------------|---------------------------------------------
20-
| [`ssid`](#class_c_access_point_1ac0161f0bae3c82f5caed8b05898fc49e) | |
21-
| [`bssid`](#class_c_access_point_1ad1bc1d6e1bee842a46ffdc408fa59947) | |
22-
| [`uint_bssid`](#class_c_access_point_1a5cf478e57a7138a1490b231b2aeb9c3e) | |
23-
| [`rssi`](#class_c_access_point_1a7b5640ed8c2ed9f62e38051ffe8fe6a0) | |
24-
| [`channel`](#class_c_access_point_1aa95219f17673f68cf3b1c6e17345b0e4) | |
25-
| [`encryption_mode`](#class_c_access_point_1ac293ee77db560b0cda65d91374249412) | |
26-
27-
## Members
28-
29-
### `ssid` <a id="class_c_access_point_1ac0161f0bae3c82f5caed8b05898fc49e" class="anchor"></a>
30-
31-
```cpp
32-
std::string ssid
33-
```
34-
35-
<hr />
36-
37-
### `bssid` <a id="class_c_access_point_1ad1bc1d6e1bee842a46ffdc408fa59947" class="anchor"></a>
38-
39-
```cpp
40-
std::string bssid
41-
```
42-
43-
<hr />
44-
45-
### `uint_bssid` <a id="class_c_access_point_1a5cf478e57a7138a1490b231b2aeb9c3e" class="anchor"></a>
46-
47-
```cpp
48-
uint8_t uint_bssid
49-
```
50-
51-
<hr />
52-
53-
### `rssi` <a id="class_c_access_point_1a7b5640ed8c2ed9f62e38051ffe8fe6a0" class="anchor"></a>
54-
55-
```cpp
56-
std::string rssi
57-
```
58-
59-
<hr />
60-
61-
### `channel` <a id="class_c_access_point_1aa95219f17673f68cf3b1c6e17345b0e4" class="anchor"></a>
62-
63-
```cpp
64-
std::string channel
65-
```
66-
67-
<hr />
68-
69-
### `encryption_mode` <a id="class_c_access_point_1ac293ee77db560b0cda65d91374249412" class="anchor"></a>
70-
71-
```cpp
72-
std::string encryption_mode
73-
```
74-
75-
<hr />
76-
77-
# class `CWifi` <a id="class_c_wifi" class="anchor"></a>
78-
79-
Class to manage Wi-Fi connectivity and operations.
80-
81-
The [CWifi](#class_c_wifi) class provides an interface to manage Wi-Fi operations such as connecting to networks, setting up an access point, retrieving network information, and more. It interfaces with a modem to execute commands related to Wi-Fi functionality and manages connection settings such as IP address, DNS, and other network configurations.
82-
83-
## Summary
84-
85-
Members | Descriptions
86-
--------------------------------|---------------------------------------------
87-
| [`CWifi`](#class_c_wifi_1a64b74dbe44a73d1b7fd4618b5b606c02) | Default constructor for the [CWifi](#class_c_wifi) class. |
88-
| [`begin`](#class_c_wifi_1a9c4fc0f23a197e9dc5ddf02bc1793c35) | Start WiFi connection for OPEN networks. |
89-
| [`begin`](#class_c_wifi_1a4a2bf8820b00494648188c7c06871a26) | start WiFi connection with passphrase the most secure supported mode will be automatically selected. |
90-
| [`beginAP`](#class_c_wifi_1adeaffb4fe03faf22e7f69697d5e83492) | |
91-
| [`beginAP`](#class_c_wifi_1ae9059d5f875a96b5cdf19d2cf87e9848) | Starts a Wi-Fi Access Point (AP) with the specified SSID and channel. |
92-
| [`beginAP`](#class_c_wifi_1aee76c2fbb9f83a3f085b034e80c1025c) | Starts a Wi-Fi Access Point (AP) with the specified SSID and passphrase. |
93-
| [`beginAP`](#class_c_wifi_1a9e1257e9b28cd3489209d7c7d5ea8845) | Initializes a Wi-Fi Access Point (AP) with the specified SSID, passphrase, and channel. |
94-
| [`config`](#class_c_wifi_1a75742aab24859611b36e74e08602dc47) | Change IP configuration settings disabling the DHCP client. |
95-
| [`config`](#class_c_wifi_1ac799224e1f9c65e4808e2c8deb802ead) | Configures the network settings for the Wi-Fi connection with a specified DNS server. |
96-
| [`config`](#class_c_wifi_1acd5a6e9bb901fb4dbaec311378f99eb6) | Configures the network settings for the Wi-Fi connection with a specified gateway and DNS server. |
97-
| [`config`](#class_c_wifi_1afc80a6fd238b6d0e59aebb2d27ec8e9e) | Configures the network settings for the Wi-Fi connection with a specified subnet mask, gateway, and DNS server. |
98-
| [`setDNS`](#class_c_wifi_1a4043b10b6a83cb3add95e127c79056a0) | Sets the primary DNS server for the Wi-Fi connection. |
99-
| [`setDNS`](#class_c_wifi_1adaa95a2dd3a8bab54080669e612f9d37) | Sets the primary and secondary DNS servers for the Wi-Fi connection. |
100-
| [`setHostname`](#class_c_wifi_1aece8d82cb1f1a55c0c22a606d66f8ea7) | Sets the hostname for for DHCP requests. |
101-
| [`disconnect`](#class_c_wifi_1a59591cd8450c695f3588df818fb58d34) | Disconnects from the current Wi-Fi network. |
102-
| [`end`](#class_c_wifi_1a50a8e7ca94f40d31ea5c9b2def045575) | Resets and disables the Wi-Fi module. |
103-
| [`macAddress`](#class_c_wifi_1a58ebcdba481cc413f32f06226dba8481) | Retrieves the MAC address of the device. |
104-
| [`localIP`](#class_c_wifi_1ae6885ef712d13bfcfe54a23f28b2aecb) | Retrieves the local IP address of the device. |
105-
| [`subnetMask`](#class_c_wifi_1afcdd6b286e90258b5296c8f30f4e7c81) | Retrieves the subnet mask of the device. |
106-
| [`gatewayIP`](#class_c_wifi_1a775e014fc255686df09b1f40f6cb9453) | Retrieves the gateway IP address of the device. |
107-
| [`dnsIP`](#class_c_wifi_1a3ee65c20906927f5772b96386d6b5700) | Retrieves the DNS IP address. |
108-
| [`softAPIP`](#class_c_wifi_1a6e64918a2784cb53588f1553c97dc333) | Retrieves the IP address of the soft access point (AP). |
109-
| [`SSID`](#class_c_wifi_1a46c576561933d9f067121b81ab8b3806) | Retrieves the SSID of the current Wi-Fi connection or SoftAP. |
110-
| [`BSSID`](#class_c_wifi_1a9b153ec8de3bd6e95255e94140314ad2) | Retrieves the BSSID (MAC address) of the currently connected Wi-Fi network. |
111-
| [`RSSI`](#class_c_wifi_1a39a8f1b67aee1a1f52d8c0f2085ebb52) | Retrieves the RSSI (Received Signal Strength Indicator) of the currently connected Wi-Fi network. |
112-
| [`softAPSSID`](#class_c_wifi_1accf0212b364b4686a4d47f7e6f58485b) | Retrieves the SSID (Service Set Identifier) of the SoftAP (Software Access Point) mode. |
113-
| [`scanNetworks`](#class_c_wifi_1af31d8a0baaa568178e2091b7a9e830a1) | Scans for available Wi-Fi networks and stores the information in the `access_points` list. |
114-
| [`SSID`](#class_c_wifi_1a452fefff75ab36097d6f4b6ad401ffcb) | Retrieves the SSID of a specific Wi-Fi network from the scan results. |
115-
| [`encryptionType`](#class_c_wifi_1ab434b47d2935bf6d0b58ec50d78c3799) | Returns the encryption type for a specified network. |
116-
| [`encryptionType`](#class_c_wifi_1a8da9fb03f5349f7887d3cdda3268ed8c) | Returns the encryption type of the currently connected Wi-Fi network. |
117-
| [`BSSID`](#class_c_wifi_1a10793238a64c312f2652b710c693022e) | Retrieves the BSSID of a specific Wi-Fi network. |
118-
| [`channel`](#class_c_wifi_1a871866aab35d3c10b98e27e51b37d8b6) | Retrieves the channel number of a specific Wi-Fi network. |
119-
| [`RSSI`](#class_c_wifi_1a86ecf1c49591c18296a6d1b1400954e5) | Retrieves the RSSI (Received Signal Strength Indicator) of the networks discovered during the scanNetworks. |
120-
| [`status`](#class_c_wifi_1aeeddb0fe0a897d043415a97d363f68e0) | Retrieves the current connection status of the Wi-Fi connection. |
121-
| [`reasonCode`](#class_c_wifi_1a453afce0d716bb1b92c3d73ba4f621e4) | Retrieves The deauthentication reason code. |
122-
| [`hostByName`](#class_c_wifi_1a97ef95bf4e58c3c11a88ab03a4702425) | Resolves a hostname to an IP address. |
123-
| [`getTime`](#class_c_wifi_1a9c3f3a794a063c20b9ef81851226a625) | Retrieves the current time from the modem. |
124-
| [`setTimeout`](#class_c_wifi_1a53250475083a7537de61d2fc14217345) | Sets the timeout value for the WiFi connection. |
125-
| [`firmwareVersion`](#class_c_wifi_1a4b2746f36f799c1e075d8f083b8bd6ee) | Get firmware version. |
126-
127-
## Members
128-
129-
### `CWifi` <a id="class_c_wifi_1a64b74dbe44a73d1b7fd4618b5b606c02" class="anchor"></a>
130-
131-
```cpp
132-
CWifi()
133-
```
134-
135-
Default constructor for the [CWifi](#class_c_wifi) class.
136-
137-
<hr />
138-
139-
### `begin` <a id="class_c_wifi_1a9c4fc0f23a197e9dc5ddf02bc1793c35" class="anchor"></a>
140-
141-
```cpp
142-
int begin(const char * ssid)
143-
```
144-
145-
Start WiFi connection for OPEN networks.
146-
147-
#### Parameters
148-
* `ssid` a pointer to the SSID string.
149-
<hr />
150-
151-
### `begin` <a id="class_c_wifi_1a4a2bf8820b00494648188c7c06871a26" class="anchor"></a>
152-
153-
```cpp
154-
int begin(const char * ssid, const char * passphrase)
155-
```
156-
157-
start WiFi connection with passphrase the most secure supported mode will be automatically selected.
158-
159-
#### Parameters
160-
* `ssid` Pointer to the SSID string.
161-
162-
* `passphrase` Passphrase. Valid characters in a passphrase must be between ASCII 32-126 (decimal).
163-
<hr />
164-
165-
### `beginAP` <a id="class_c_wifi_1adeaffb4fe03faf22e7f69697d5e83492" class="anchor"></a>
166-
167-
```cpp
168-
uint8_t beginAP(const char * ssid)
169-
```
170-
171-
<hr />
172-
173-
### `beginAP` <a id="class_c_wifi_1ae9059d5f875a96b5cdf19d2cf87e9848" class="anchor"></a>
174-
175-
```cpp
176-
uint8_t beginAP(const char * ssid, uint8_t channel)
177-
```
178-
179-
Starts a Wi-Fi Access Point (AP) with the specified SSID and channel.
180-
181-
This function initializes a Wi-Fi Access Point (AP) with the provided SSID and channel. It defaults to using no password (open network).
182-
183-
#### Parameters
184-
* `ssid` The SSID (name) of the Wi-Fi Access Point.
185-
186-
* `channel` The channel on which the Access Point will operate.
187-
188-
#### Returns
189-
`1` if the Access Point is successfully started. `0` if the Access Point failed to start.
190-
<hr />
191-
192-
### `beginAP` <a id="class_c_wifi_1aee76c2fbb9f83a3f085b034e80c1025c" class="anchor"></a>
193-
194-
```cpp
195-
uint8_t beginAP(const char * ssid, const char * passphrase)
196-
```
197-
198-
Starts a Wi-Fi Access Point (AP) with the specified SSID and passphrase.
199-
200-
This function initializes a Wi-Fi Access Point (AP) using the provided SSID and passphrase, defaulting to channel 1.
201-
202-
#### Parameters
203-
* `ssid` The SSID (name) of the Wi-Fi Access Point.
204-
205-
* `passphrase` The passphrase for securing the Access Point. If empty, the network will be open (no password).
206-
207-
#### Returns
208-
`1` if the Access Point is successfully started. `0` if the Access Point failed to start.
209-
<hr />
210-
211-
### `beginAP` <a id="class_c_wifi_1a9e1257e9b28cd3489209d7c7d5ea8845" class="anchor"></a>
212-
213-
```cpp
214-
uint8_t beginAP(const char * ssid, const char * passphrase, uint8_t channel)
215-
```
216-
217-
Initializes a Wi-Fi Access Point (AP) with the specified SSID, passphrase, and channel.
218-
219-
This function configures the device as a Wi-Fi Access Point (AP) with the provided parameters. It sets the mode to AP and attempts to start the network.
220-
221-
#### Parameters
222-
* `ssid` The SSID (name) of the Wi-Fi Access Point.
223-
224-
* `passphrase` The passphrase for securing the Access Point. If empty, the network will be open.
225-
226-
* `channel` The Wi-Fi channel on which the Access Point will operate (1-14, depending on region).
227-
228-
#### Returns
229-
`WL_AP_LISTENING` if the Access Point is successfully started. `WL_AP_FAILED` if the Access Point failed to start.
230-
<hr />
231-
232-
### `config` <a id="class_c_wifi_1a75742aab24859611b36e74e08602dc47" class="anchor"></a>
233-
234-
```cpp
235-
void config(IPAddress local_ip)
236-
```
237-
238-
Change IP configuration settings disabling the DHCP client.
239-
240-
#### Parameters
241-
* `local_ip` The static IP address to assign to the device.
242-
<hr />
243-
244-
### `config` <a id="class_c_wifi_1ac799224e1f9c65e4808e2c8deb802ead" class="anchor"></a>
245-
246-
```cpp
247-
void config(IPAddress local_ip, IPAddress dns_server)
248-
```
249-
250-
Configures the network settings for the Wi-Fi connection with a specified DNS server.
251-
252-
Sets the device's IP configuration using the specified local IP address and DNS server. The gateway and subnet mask are set to default values based on the provided local IP.
253-
254-
#### Parameters
255-
* `local_ip` The static IP address to assign to the device.
256-
257-
* `dns_server` The primary DNS server to use for domain name resolution.
258-
<hr />
259-
260-
### `config` <a id="class_c_wifi_1acd5a6e9bb901fb4dbaec311378f99eb6" class="anchor"></a>
261-
262-
```cpp
263-
void config(IPAddress local_ip, IPAddress dns_server, IPAddress gateway)
264-
```
265-
266-
Configures the network settings for the Wi-Fi connection with a specified gateway and DNS server.
267-
268-
#### Parameters
269-
* `local_ip` The static IP address to assign to the device.
270-
271-
* `dns_server` The primary DNS server to use for domain name resolution.
272-
273-
* `gateway` The Static gateway used for configuration.
274-
<hr />
275-
276-
### `config` <a id="class_c_wifi_1afc80a6fd238b6d0e59aebb2d27ec8e9e" class="anchor"></a>
277-
278-
```cpp
279-
void config(IPAddress local_ip, IPAddress dns_server, IPAddress gateway, IPAddress subnet)
280-
```
281-
282-
Configures the network settings for the Wi-Fi connection with a specified subnet mask, gateway, and DNS server.
283-
284-
#### Parameters
285-
* `local_ip` The static IP address to assign to the device.
286-
287-
* `dns_server` The primary DNS server to use for domain name resolution.
288-
289-
* `gateway` The static gateway used for configuration.
290-
291-
* `subnet` The static subnet mask to use for the network.
292-
<hr />
293-
294-
### `setDNS` <a id="class_c_wifi_1a4043b10b6a83cb3add95e127c79056a0" class="anchor"></a>
295-
296-
```cpp
297-
void setDNS(IPAddress dns_server1)
298-
```
299-
300-
Sets the primary DNS server for the Wi-Fi connection.
301-
302-
#### Parameters
303-
* `dns_server1` The primary DNS server to use for domain name resolution.
304-
<hr />
305-
306-
### `setDNS` <a id="class_c_wifi_1adaa95a2dd3a8bab54080669e612f9d37" class="anchor"></a>
307-
308-
```cpp
309-
void setDNS(IPAddress dns_server1, IPAddress dns_server2)
310-
```
311-
312-
Sets the primary and secondary DNS servers for the Wi-Fi connection.
313-
314-
#### Parameters
315-
* `dns_server1` sets the IP configuration for DNS server 1
316-
317-
* `dns_server2` sets the IP configuration for DNS server 2
318-
<hr />
319-
320-
### `setHostname` <a id="class_c_wifi_1aece8d82cb1f1a55c0c22a606d66f8ea7" class="anchor"></a>
321-
322-
```cpp
323-
void setHostname(const char * name)
324-
```
325-
326-
Sets the hostname for for DHCP requests.
327-
328-
#### Parameters
329-
* `name` sets the hostname.
330-
<hr />
331-
332-
### `disconnect` <a id="class_c_wifi_1a59591cd8450c695f3588df818fb58d34" class="anchor"></a>
333-
334-
```cpp
335-
int disconnect(void)
336-
```
337-
338-
Disconnects from the current Wi-Fi network.
339-
340-
#### Returns
341-
`1` if the disconnection was successful, `0` otherwise.
342-
<hr />
343-
344-
### `end` <a id="class_c_wifi_1a50a8e7ca94f40d31ea5c9b2def045575" class="anchor"></a>
345-
346-
```cpp
347-
void end(void)
348-
```
349-
350-
Resets and disables the Wi-Fi module.
351-
352-
<hr />
353-
354-
### `macAddress` <a id="class_c_wifi_1a58ebcdba481cc413f32f06226dba8481" class="anchor"></a>
355-
356-
```cpp
357-
uint8_t * macAddress(uint8_t * mac)
358-
```
359-
360-
Retrieves the MAC address of the device.
361-
362-
This function retrieves the MAC address of the device based on its current operating mode. The value returned by this function is meaningfull only if called afert a begin (both begin or beginAP) or a ScanNetwork function otherwise an empty mac address is returned.
363-
364-
#### Parameters
365-
* `_mac` A pointer to a uint8_t array where the MAC address will be stored.
366-
367-
#### Returns
368-
uint8_t* The pointer to the array containing the MAC address.
369-
<hr />
370-
371-
### `localIP` <a id="class_c_wifi_1ae6885ef712d13bfcfe54a23f28b2aecb" class="anchor"></a>
372-
373-
```cpp
374-
IPAddress localIP()
375-
```
376-
377-
Retrieves the local IP address of the device.
378-
379-
This function retrieves the local IP address of the device. It checks the current mode (station or soft AP) and retrieves the appropriate IP address based on the mode.
380-
381-
#### Returns
382-
`IPAddress` The local IP address of the device.
383-
<hr />
384-
385-
### `subnetMask` <a id="class_c_wifi_1afcdd6b286e90258b5296c8f30f4e7c81" class="anchor"></a>
386-
387-
```cpp
388-
IPAddress subnetMask()
389-
```
390-
391-
Retrieves the subnet mask of the device.
392-
393-
This function retrieves the subnet mask of the device by querying the modem for the subnet information. It sends a command to the modem to fetch the subnet mask and returns it as an `IPAddress` object.
394-
395-
#### Returns
396-
`IPAddress` The subnet mask address value of the device.
397-
<hr />
398-
399-
### `gatewayIP` <a id="class_c_wifi_1a775e014fc255686df09b1f40f6cb9453" class="anchor"></a>
400-
401-
```cpp
402-
IPAddress gatewayIP()
403-
```
404-
405-
Retrieves the gateway IP address of the device.
406-
407-
This function retrieves the gateway IP address of the device by querying the modem for the gateway information. It sends a command to the modem to fetch the gateway IP address and returns it as an `IPAddress` object.
408-
409-
#### Returns
410-
`IPAddress` The gateway IP address value of the device.
411-
<hr />
412-
413-
### `dnsIP` <a id="class_c_wifi_1a3ee65c20906927f5772b96386d6b5700" class="anchor"></a>
414-
415-
```cpp
416-
IPAddress dnsIP(int n)
417-
```
418-
419-
Retrieves the DNS IP address.
420-
421-
#### Parameters
422-
* `n` The index of the DNS server to retrieve, `0` for the primary DNS server and `1` for the secondary DNS server.
423-
424-
#### Returns
425-
`IPAddress` The DNS IP address as an `IPAddress` object, or `0.0.0.0` if not found.
426-
<hr />
427-
428-
### `softAPIP` <a id="class_c_wifi_1a6e64918a2784cb53588f1553c97dc333" class="anchor"></a>
429-
430-
```cpp
431-
IPAddress softAPIP()
432-
```
433-
434-
Retrieves the IP address of the soft access point (AP).
435-
436-
#### Returns
437-
`IPAddress` The IP address of the soft AP as an `IPAddress` object, or `0.0.0.0` if not found.
438-
<hr />
439-
440-
### `SSID` <a id="class_c_wifi_1a46c576561933d9f067121b81ab8b3806" class="anchor"></a>
441-
442-
```cpp
443-
const char * SSID()
444-
```
445-
446-
Retrieves the SSID of the current Wi-Fi connection or SoftAP.
447-
448-
#### Returns
449-
The SSID of the current Wi-Fi connection or SoftAP as a string. If unable to retrieve the SSID, returns an empty string.
450-
<hr />
451-
452-
### `BSSID` <a id="class_c_wifi_1a9b153ec8de3bd6e95255e94140314ad2" class="anchor"></a>
453-
454-
```cpp
455-
uint8_t * BSSID(uint8_t * bssid)
456-
```
457-
458-
Retrieves the BSSID (MAC address) of the currently connected Wi-Fi network.
459-
460-
#### Parameters
461-
* `bssid` A pointer to an array where the BSSID will be stored. The array must be large enough to hold the MAC address.
462-
463-
#### Returns
464-
A pointer to the `bssid` array containing the retrieved BSSID. If the BSSID cannot be retrieved, returns `nullptr`.
465-
<hr />
466-
467-
### `RSSI` <a id="class_c_wifi_1a39a8f1b67aee1a1f52d8c0f2085ebb52" class="anchor"></a>
468-
469-
```cpp
470-
int32_t RSSI()
471-
```
472-
473-
Retrieves the RSSI (Received Signal Strength Indicator) of the currently connected Wi-Fi network.
474-
475-
#### Returns
476-
The RSSI value representing the signal strength. A higher (less negative) value indicates a stronger signal. If the RSSI cannot be retrieved, returns 0.
477-
<hr />
478-
479-
### `softAPSSID` <a id="class_c_wifi_1accf0212b364b4686a4d47f7e6f58485b" class="anchor"></a>
480-
481-
```cpp
482-
const char * softAPSSID()
483-
```
484-
485-
Retrieves the SSID (Service Set Identifier) of the SoftAP (Software Access Point) mode.
486-
487-
#### Returns
488-
The SSID of the SoftAP. If the SSID cannot be retrieved, an empty string is returned.
489-
<hr />
490-
491-
### `scanNetworks` <a id="class_c_wifi_1af31d8a0baaa568178e2091b7a9e830a1" class="anchor"></a>
492-
493-
```cpp
494-
int8_t scanNetworks()
495-
```
496-
497-
Scans for available Wi-Fi networks and stores the information in the `access_points` list.
498-
499-
This function initiates a scan for nearby Wi-Fi networks and retrieves details such as SSID, BSSID, RSSI (signal strength), channel, and encryption mode for each detected access point.
500-
501-
#### Returns
502-
The number of networks found during the scan. Returns a negative value in case of an error.
503-
<hr />
504-
505-
### `SSID` <a id="class_c_wifi_1a452fefff75ab36097d6f4b6ad401ffcb" class="anchor"></a>
506-
507-
```cpp
508-
const char * SSID(uint8_t networkItem)
509-
```
510-
511-
Retrieves the SSID of a specific Wi-Fi network from the scan results.
512-
513-
#### Parameters
514-
* `networkItem` The index of the network in the list of scanned access points.
515-
516-
#### Returns
517-
The SSID of the specified network, or `nullptr` if the index is out of bounds.
518-
<hr />
519-
520-
### `encryptionType` <a id="class_c_wifi_1ab434b47d2935bf6d0b58ec50d78c3799" class="anchor"></a>
521-
522-
```cpp
523-
uint8_t encryptionType(uint8_t networkItem)
524-
```
525-
526-
Returns the encryption type for a specified network.
527-
528-
This function retrieves the encryption type of a specific Wi-Fi access point based on its index in the list of scanned networks.
529-
530-
#### Parameters
531-
* `networkItem` The index of the network in the list of available access points.
532-
533-
#### Returns
534-
The encryption type in numeric form (e.g., 0 for no encryption, 1 for WEP, 2 for WPA, etc.). Returns 0 if the network item index is invalid.
535-
<hr />
536-
537-
### `encryptionType` <a id="class_c_wifi_1a8da9fb03f5349f7887d3cdda3268ed8c" class="anchor"></a>
538-
539-
```cpp
540-
uint8_t encryptionType()
541-
```
542-
543-
Returns the encryption type of the currently connected Wi-Fi network.
544-
545-
#### Returns
546-
The encryption type in numeric form (e.g., 0 for no encryption, 1 for WEP, 2 for WPA, etc.). Returns `ENC_TYPE_UNKNOWN` if the encryption type cannot be determined.
547-
<hr />
548-
549-
### `BSSID` <a id="class_c_wifi_1a10793238a64c312f2652b710c693022e" class="anchor"></a>
550-
551-
```cpp
552-
uint8_t * BSSID(uint8_t networkItem, uint8_t * bssid)
553-
```
554-
555-
Retrieves the BSSID of a specific Wi-Fi network.
556-
557-
This function retrieves the BSSID (MAC address) of the Wi-Fi network at the specified index from the list of available networks. The BSSID is stored in the provided array of 6 bytes.
558-
559-
#### Parameters
560-
* `networkItem` The index of the Wi-Fi network in the list of available networks.
561-
562-
* `bssid` A pointer to a byte array (of size 6) where the BSSID will be stored.
563-
564-
#### Returns
565-
A pointer to the `bssid` array if the BSSID is successfully retrieved, or `nullptr` if the network index is out of range.
566-
<hr />
567-
568-
### `channel` <a id="class_c_wifi_1a871866aab35d3c10b98e27e51b37d8b6" class="anchor"></a>
569-
570-
```cpp
571-
uint8_t channel(uint8_t networkItem)
572-
```
573-
574-
Retrieves the channel number of a specific Wi-Fi network.
575-
576-
#### Parameters
577-
* `networkItem` The index of the Wi-Fi network in the list of available networks.
578-
579-
#### Returns
580-
The channel number of the specified network, or `0` if the network index is out of range.
581-
<hr />
582-
583-
### `RSSI` <a id="class_c_wifi_1a86ecf1c49591c18296a6d1b1400954e5" class="anchor"></a>
584-
585-
```cpp
586-
int32_t RSSI(uint8_t networkItem)
587-
```
588-
589-
Retrieves the RSSI (Received Signal Strength Indicator) of the networks discovered during the scanNetworks.
590-
591-
#### Parameters
592-
* `networkItem` The index of the Wi-Fi network in the list of available networks.
593-
594-
#### Returns
595-
The RSSI value of the specified network in dBm, or `-1000` if the network index is out of range.
596-
<hr />
597-
598-
### `status` <a id="class_c_wifi_1aeeddb0fe0a897d043415a97d363f68e0" class="anchor"></a>
599-
600-
```cpp
601-
uint8_t status()
602-
```
603-
604-
Retrieves the current connection status of the Wi-Fi connection.
605-
606-
#### Returns
607-
One of the values defined in wl_status_t
608-
<hr />
609-
610-
### `reasonCode` <a id="class_c_wifi_1a453afce0d716bb1b92c3d73ba4f621e4" class="anchor"></a>
611-
612-
```cpp
613-
uint8_t reasonCode()
614-
```
615-
616-
Retrieves The deauthentication reason code.
617-
618-
#### Returns
619-
The deauthentication reason code.
620-
<hr />
621-
622-
### `hostByName` <a id="class_c_wifi_1a97ef95bf4e58c3c11a88ab03a4702425" class="anchor"></a>
623-
624-
```cpp
625-
int hostByName(const char * aHostname, IPAddress & aResult)
626-
```
627-
628-
Resolves a hostname to an IP address.
629-
630-
#### Parameters
631-
* `aHostname` The hostname to resolve (e.g., "www.example.com").
632-
633-
* `aResult` IPAddress structure to store the returned IP address result: 1 if aIPAddrString was successfully converted to an IP address, else error code
634-
635-
#### Returns
636-
Returns `1` if the hostname was successfully resolved, `0` otherwise.
637-
<hr />
638-
639-
### `getTime` <a id="class_c_wifi_1a9c3f3a794a063c20b9ef81851226a625" class="anchor"></a>
640-
641-
```cpp
642-
unsigned long getTime()
643-
```
644-
645-
Retrieves the current time from the modem.
646-
647-
#### Returns
648-
The current time value in seconds, or `0` if the time could not be retrieved.
649-
<hr />
650-
651-
### `setTimeout` <a id="class_c_wifi_1a53250475083a7537de61d2fc14217345" class="anchor"></a>
652-
653-
```cpp
654-
void setTimeout(unsigned long timeout)
655-
```
656-
657-
Sets the timeout value for the WiFi connection.
658-
659-
#### Parameters
660-
* `timeout` The timeout value in milliseconds.
661-
<hr />
662-
663-
### `firmwareVersion` <a id="class_c_wifi_1a4b2746f36f799c1e075d8f083b8bd6ee" class="anchor"></a>
664-
665-
```cpp
666-
static const char * firmwareVersion()
667-
```
668-
669-
Get firmware version.
670-
671-
<hr />
672-
673-
# class `ModemClass` <a id="class_modem_class" class="anchor"></a>
674-
675-
A class that provides methods to interact with a modem.
676-
677-
This class is responsible for providing an interface to communicate with a modem through serial communication. It includes methods for initialization, sending and receiving data, and handling modem configurations.
678-
679-
## Summary
680-
681-
Members | Descriptions
682-
--------------------------------|---------------------------------------------
683-
| [`beginned`](#class_modem_class_1ad21db7f5eb0b759c9b6c02af03b8f964) | Flag indicating whether the system has been initialized. |
684-
| [`enable_dbg`](#class_modem_class_1a77cc6948341d08f0285233c67ef1e928) | |
685-
| [`ModemClass`](#class_modem_class_1acce8d910277f180f32607ed8e84f090b) | Constructor for the [ModemClass](#class_modem_class), which initializes the modem with the specified transmit (TX) and receive (RX) pins. |
686-
| [`ModemClass`](#class_modem_class_1af222286fa398b86d02bd6230e0c42039) | Constructor for the [ModemClass](#class_modem_class), which initializes the modem with the specified UART interface. |
687-
| [`~ModemClass`](#class_modem_class_1a458f1f4e43e27fdc522caaf4c40d9579) | Destructor for [ModemClass](#class_modem_class). |
688-
| [`begin`](#class_modem_class_1a36c32d41d4111e5fc63d8bf1a017368f) | Initializes the modem communication with a specified baud rate. |
689-
| [`end`](#class_modem_class_1a434e5c4b8c67d90c10eff5e20da56556) | Ends the modem communication. |
690-
| [`write`](#class_modem_class_1acd102543a8544be0686128fea53c9a11) | Sends a formatted command string to a device and stores the response. |
691-
| [`write_nowait`](#class_modem_class_1aa9923ac664a16c2aaf5024de9de1ef03) | Used to send a command to the modem without waiting for a response. |
692-
| [`passthrough`](#class_modem_class_1aa8750f17b14472819ffb8016118f869b) | Sends binary data directly to the modem without any processing or interpretation. |
693-
| [`avoid_trim_results`](#class_modem_class_1ac7aff51f7bb09bbfd7190af1715274f8) | Disables automatic trimming of results for one operation. |
694-
| [`read_using_size`](#class_modem_class_1a83d1105d39191e2c902331b3f0c4c8f5) | Enables a specific mode of reading where the size of the data to be read is considered for processing. |
695-
| [`debug`](#class_modem_class_1a6e6c472f405698e25db0d90a1de359f4) | |
696-
| [`noDebug`](#class_modem_class_1a0b73ad5e52ad405a3be764d948cd8522) | Used to disable debugging output for the modem communication. |
697-
| [`debug`](#class_modem_class_1a0d2808ffeccd83db3e26cc3568e33eeb) | |
698-
| [`timeout`](#class_modem_class_1a240fc0451c5152615f192b675beabadc) | Sets the timeout value for communication operations. |
699-
700-
## Members
701-
702-
### `beginned` <a id="class_modem_class_1ad21db7f5eb0b759c9b6c02af03b8f964" class="anchor"></a>
703-
704-
```cpp
705-
bool beginned
706-
```
707-
708-
Flag indicating whether the system has been initialized.
709-
710-
<hr />
711-
712-
### `enable_dbg` <a id="class_modem_class_1a77cc6948341d08f0285233c67ef1e928" class="anchor"></a>
713-
714-
```cpp
715-
bool enable_dbg
716-
```
717-
718-
<hr />
719-
720-
### `ModemClass` <a id="class_modem_class_1acce8d910277f180f32607ed8e84f090b" class="anchor"></a>
721-
722-
```cpp
723-
ModemClass(int tx, int rx)
724-
```
725-
726-
Constructor for the [ModemClass](#class_modem_class), which initializes the modem with the specified transmit (TX) and receive (RX) pins.
727-
728-
#### Parameters
729-
* `Initializes` an instance of the [ModemClass](#class_modem_class) class with specific transmit `tx` and receive `rx` pins for communication.
730-
<hr />
731-
732-
### `ModemClass` <a id="class_modem_class_1af222286fa398b86d02bd6230e0c42039" class="anchor"></a>
733-
734-
```cpp
735-
ModemClass(UART * _serial)
736-
```
737-
738-
Constructor for the [ModemClass](#class_modem_class), which initializes the modem with the specified UART interface.
739-
740-
#### Parameters
741-
* `_serial` is a pointer to the UART object that will be used for communication with the modem.
742-
<hr />
743-
744-
### `~ModemClass` <a id="class_modem_class_1a458f1f4e43e27fdc522caaf4c40d9579" class="anchor"></a>
745-
746-
```cpp
747-
~ModemClass()
748-
```
749-
750-
Destructor for [ModemClass](#class_modem_class).
751-
752-
<hr />
753-
754-
### `begin` <a id="class_modem_class_1a36c32d41d4111e5fc63d8bf1a017368f" class="anchor"></a>
755-
756-
```cpp
757-
void begin(int badurate)
758-
```
759-
760-
Initializes the modem communication with a specified baud rate.
761-
762-
#### Parameters
763-
* `badurate` sets the baud rate for the serial connection.
764-
<hr />
765-
766-
### `end` <a id="class_modem_class_1a434e5c4b8c67d90c10eff5e20da56556" class="anchor"></a>
767-
768-
```cpp
769-
void end()
770-
```
771-
772-
Ends the modem communication.
773-
774-
<hr />
775-
776-
### `write` <a id="class_modem_class_1acd102543a8544be0686128fea53c9a11" class="anchor"></a>
777-
778-
```cpp
779-
bool write(const std::string & cmd, std::string & str, const char * fmt, ...)
780-
```
781-
782-
Sends a formatted command string to a device and stores the response.
783-
784-
This function formats a command string using the provided format and arguments, sends it to a device, and waits for a response, which is stored in the `str` string.
785-
786-
#### Parameters
787-
* `cmd` A string representing the command to be sent to the device.
788-
789-
* `str` A reference to a string that will hold the device's response.
790-
791-
* `fmt` A format string for constructing the command.
792-
793-
#### Returns
794-
`true` if the command was successfully sent and a response was received, `false` otherwise.
795-
<hr />
796-
797-
### `write_nowait` <a id="class_modem_class_1aa9923ac664a16c2aaf5024de9de1ef03" class="anchor"></a>
798-
799-
```cpp
800-
void write_nowait(const std::string & cmd, std::string & str, const char * fmt, ...)
801-
```
802-
803-
Used to send a command to the modem without waiting for a response.
804-
805-
#### Parameters
806-
* `It` takes a command string `cmd`, a string `str` where the response will be stored, and a format string `fmt` along with additional arguments.
807-
<hr />
808-
809-
### `passthrough` <a id="class_modem_class_1aa8750f17b14472819ffb8016118f869b" class="anchor"></a>
810-
811-
```cpp
812-
bool passthrough(const uint8_t * data, size_t size)
813-
```
814-
815-
Sends binary data directly to the modem without any processing or interpretation.
816-
817-
#### Parameters
818-
* `It` takes a pointer to the binary `data` and the `size` of the data as arguments. Used for sending raw binary commands or data to the modem for operations that require direct communication without any additional formatting or parsing.
819-
<hr />
820-
821-
### `avoid_trim_results` <a id="class_modem_class_1ac7aff51f7bb09bbfd7190af1715274f8" class="anchor"></a>
822-
823-
```cpp
824-
inline void avoid_trim_results()
825-
```
826-
827-
Disables automatic trimming of results for one operation.
828-
829-
This function disables the automatic trimming of results for one operation. After it is called, the results will not be trimmed automatically until the function is called again.
830-
<hr />
831-
832-
### `read_using_size` <a id="class_modem_class_1a83d1105d39191e2c902331b3f0c4c8f5" class="anchor"></a>
833-
834-
```cpp
835-
inline void read_using_size()
836-
```
837-
838-
Enables a specific mode of reading where the size of the data to be read is considered for processing.
839-
840-
<hr />
841-
842-
### `debug` <a id="class_modem_class_1a6e6c472f405698e25db0d90a1de359f4" class="anchor"></a>
843-
844-
```cpp
845-
inline void debug(Stream & u, uint8_t level)
846-
```
847-
848-
<hr />
849-
850-
### `noDebug` <a id="class_modem_class_1a0b73ad5e52ad405a3be764d948cd8522" class="anchor"></a>
851-
852-
```cpp
853-
inline void noDebug()
854-
```
855-
856-
Used to disable debugging output for the modem communication.
857-
858-
<hr />
859-
860-
### `debug` <a id="class_modem_class_1a0d2808ffeccd83db3e26cc3568e33eeb" class="anchor"></a>
861-
862-
```cpp
863-
inline void debug(bool e)
864-
```
865-
866-
<hr />
867-
868-
### `timeout` <a id="class_modem_class_1a240fc0451c5152615f192b675beabadc" class="anchor"></a>
869-
870-
```cpp
871-
inline void timeout(size_t timeout_ms)
872-
```
873-
874-
Sets the timeout value for communication operations.
875-
876-
#### Parameters
877-
* `Can` be called with a specified timeout value in milliseconds.
878-
<hr />
879-
88011
# class `WiFiClient` <a id="class_wi_fi_client" class="anchor"></a>
88112

88213
```cpp
@@ -937,7 +68,7 @@ WiFiClient(int s)
93768
Constructor to initialize a [WiFiClient](#class_wi_fi_client) object with a specific socket.
93869
93970
#### Parameters
940-
* `s` is the socket descriptor to associate with this client.
71+
* `<tt>s</tt>` is the socket descriptor to associate with this client.
94172
<hr />
94273
94374
### `WiFiClient` <a id="class_wi_fi_client_1a1b176d034c1239bdcffa6db13ef5e485" class="anchor"></a>
@@ -949,7 +80,7 @@ WiFiClient(const WiFiClient & c)
94980
Copy constructor for the [WiFiClient](#class_wi_fi_client) class.
95081

95182
#### Parameters
952-
* `c` is the `[WiFiClient](#class_wi_fi_client)` object to copy.
83+
* `<tt>c</tt>` is the `[WiFiClient](#class_wi_fi_client)` object to copy.
95384
<hr />
95485

95586
### `~WiFiClient` <a id="class_wi_fi_client_1a6410fb12d526d541c436136b18faa0db" class="anchor"></a>
@@ -971,9 +102,9 @@ virtual int connect(IPAddress ip, uint16_t port)
971102
Establishes a connection to a server using an IP address and port.
972103
973104
#### Parameters
974-
* `ip` as the IP address of the server to connect to.
105+
* `<tt>ip</tt>` as the IP address of the server to connect to.
975106
976-
* `port` as the port number on the server to connect to.
107+
* `<tt>port</tt>` as the port number on the server to connect to.
977108
978109
#### Returns
979110
`1` on a successful connection, `0` on failure.
@@ -988,9 +119,9 @@ virtual int connect(const char * host, uint16_t port)
988119
Establishes a connection to a server using a hostname and port.
989120

990121
#### Parameters
991-
* `host` is a pointer to a null-terminated string containing the hostname of the server.
122+
* `<tt>host</tt>` is a pointer to a null-terminated string containing the hostname of the server.
992123

993-
* `port` is the port number on the server to connect to.
124+
* `<tt>port</tt>` is the port number on the server to connect to.
994125

995126
#### Returns
996127
`1` if the connection was successful, `0` otherwise.
@@ -1005,7 +136,7 @@ virtual size_t write(uint8_t)
1005136
Sends a single byte of data to the connected server.
1006137
1007138
#### Parameters
1008-
* `b` being the byte of data to send.
139+
* `<tt>b</tt>` being the byte of data to send.
1009140
1010141
#### Returns
1011142
The number of bytes successfully written, which is `1` on success or `0` on failure.
@@ -1061,9 +192,9 @@ Reads multiple bytes of data from the server into a buffer.
1061192
This function retrieves data from the server's receive buffer and stores it into the provided array. It attempts to read up to the specified number of bytes (`size`).
1062193
1063194
#### Parameters
1064-
* `buf` is a pointer to the buffer where the data will be stored.
195+
* `<tt>buf</tt>` is a pointer to the buffer where the data will be stored.
1065196
1066-
* `size` is the maximum number of bytes to read.
197+
* `<tt>size</tt>` is the maximum number of bytes to read.
1067198
1068199
#### Returns
1069200
The number of bytes successfully read into the buffer. Returns `0` if no data is available or if the socket is invalid.
@@ -1156,7 +287,7 @@ Inequality operator for comparing two `[WiFiClient](#class_wi_fi_client)` object
1156287
Compares the current `[WiFiClient](#class_wi_fi_client)` object with another `[WiFiClient](#class_wi_fi_client)` object to determine if they represent different socket connections.
1157288

1158289
#### Parameters
1159-
* `whs` is the `[WiFiClient](#class_wi_fi_client)` object to compare with.
290+
* `<tt>whs</tt>` is the `[WiFiClient](#class_wi_fi_client)` object to compare with.
1160291

1161292
#### Returns
1162293
`true` if both [WiFiClient](#class_wi_fi_client) objects represent different sockets, `false` if they represent the same socket.
@@ -1195,7 +326,7 @@ inline void setConnectionTimeout(int timeout)
1195326
Sets the connection timeout for the client.
1196327
1197328
#### Parameters
1198-
* `timeout` is the timeout value in milliseconds.
329+
* `<tt>timeout</tt>` is the timeout value in milliseconds.
1199330
<hr />
1200331
1201332
# class `WiFiFileSystem` <a id="class_wi_fi_file_system" class="anchor"></a>
@@ -1246,7 +377,7 @@ size_t writefile(const char * name, const char * data, size_t size, int operatio
1246377
Writes data to a file in the file system.
1247378

1248379
#### Parameters
1249-
* `name` is the name of the file to which the data will be written. A pointer `data` to the data that will be written to the file. `size` is the number of bytes to write from the provided data buffer. `operation` determines the type of file operation to perform (e.g., create, overwrite).
380+
* `<tt>name</tt>` is the name of the file to which the data will be written. A pointer `data` to the data that will be written to the file. `size` is the number of bytes to write from the provided data buffer. `operation` determines the type of file operation to perform (e.g., create, overwrite).
1250381

1251382
#### Returns
1252383
Returns the number of bytes successfully written. Returns 0 if the operation fails.
@@ -1263,7 +394,7 @@ Reads a file from the file system and prints its content.
1263394
It sends the read request to the modem, which fetches the data. The content is printed to the serial output in chunks, with each chunk being processed until the entire file is read.
1264395
1265396
#### Parameters
1266-
* `name` is the name of the file to be read from the file system.
397+
* `<tt>name</tt>` is the name of the file to be read from the file system.
1267398
<hr />
1268399
1269400
# class `WiFiServer` <a id="class_wi_fi_server" class="anchor"></a>
@@ -1315,7 +446,7 @@ WiFiServer(int p)
1315446
Constructs a [WiFiServer](#class_wi_fi_server) object with the specified port.
1316447
1317448
#### Parameters
1318-
* `p` The port number on which the server will listen for incoming connections.
449+
* `<tt>p</tt>` The port number on which the server will listen for incoming connections.
1319450
<hr />
1320451
1321452
### `available` <a id="class_wi_fi_server_1abfd839b75fa3c40bd5e22c4a122ed800" class="anchor"></a>
@@ -1353,7 +484,7 @@ void begin(int port)
1353484
Starts the Wi-Fi server and binds it to the specified port.
1354485
1355486
#### Parameters
1356-
* `port` is the port number which the server will listen to for incoming connections.
487+
* `<tt>port</tt>` is the port number which the server will listen to for incoming connections.
1357488
<hr />
1358489
1359490
### `begin` <a id="class_wi_fi_server_1a953b3d2a3ea0b0582be9535b6aa908d9" class="anchor"></a>
@@ -1376,7 +507,7 @@ virtual size_t write(uint8_t)
1376507
Writes a single byte to all connected clients.
1377508
1378509
#### Parameters
1379-
* `b` is the byte to be sent to the clients.
510+
* `<tt>b</tt>` is the byte to be sent to the clients.
1380511
<hr />
1381512
1382513
### `write` <a id="class_wi_fi_server_1a6bef9499519bcedd59379024c4e7b360" class="anchor"></a>
@@ -1390,7 +521,7 @@ Writes data to all connected clients.
1390521
This function sends a buffer of data to all clients connected to the server. It writes the specified number of bytes to the server socket and returns the count of successfully written bytes.
1391522

1392523
#### Parameters
1393-
* `buf` is a pointer to the buffer containing the data to be sent. `size` is the number of bytes to write from the buffer.
524+
* `<tt>buf</tt>` is a pointer to the buffer containing the data to be sent. `size` is the number of bytes to write from the buffer.
1394525

1395526
#### Returns
1396527
The number of bytes successfully written. Returns 0 if the data could not be sent.
@@ -1449,7 +580,7 @@ Compares two [WiFiServer](#class_wi_fi_server) objects for inequality.
1449580
This virtual operator compares the underlying socket (`_sock`) of two [WiFiServer](#class_wi_fi_server) objects. It returns `true` if the objects do not refer to the same server connection (i.e., they have different socket values), and `false` otherwise.
1450581

1451582
#### Parameters
1452-
* `whs` The [WiFiServer](#class_wi_fi_server) object to compare against.
583+
* `<tt>whs</tt>` The [WiFiServer](#class_wi_fi_server) object to compare against.
1453584

1454585
#### Returns
1455586
`true` if the [WiFiServer](#class_wi_fi_server) objects have different sockets; `false` otherwise.
@@ -1535,7 +666,7 @@ virtual int connect(const char * host, uint16_t port)
1535666
Establishes a secure SSL connection to a specified host and port.
1536667

1537668
#### Parameters
1538-
* `host` is the hostname or IP address of the server to connect to. `port` is the port number to connect to.
669+
* `<tt>host</tt>` is the hostname or IP address of the server to connect to. `port` is the port number to connect to.
1539670

1540671
#### Returns
1541672
Returns `1` if the connection is successfully established, `0` otherwise.
@@ -1550,7 +681,7 @@ void setCACert(const char * root_ca)
1550681
Sets the Certificate Authority (CA) for SSL/TLS verification.
1551682
1552683
#### Parameters
1553-
* `root_ca` is a pointer to a null-terminated string containing the root CA certificate in PEM format. If set to `nullptr`, the default root CA bundle will be used.
684+
* `<tt>root_ca</tt>` is a pointer to a null-terminated string containing the root CA certificate in PEM format. If set to `nullptr`, the default root CA bundle will be used.
1554685
<hr />
1555686
1556687
### `setEccSlot` <a id="class_wi_fi_s_s_l_client_1a9720117b29a35bc2a43c133f76fd8f8e" class="anchor"></a>
@@ -1562,11 +693,11 @@ void setEccSlot(int ecc508KeySlot, const byte cert, int certLength)
1562693
Sets the ECC (Elliptic Curve Cryptography) key slot and certificate for establishing secure SSL connections.
1563694

1564695
#### Parameters
1565-
* `int` ecc508KeySlot specifies the ECC key slot to be used for the SSL connection.
696+
* `<tt>int` ecc508KeySlot specifies the ECC key slot to be used for the SSL connection.
1566697

1567-
* `const` byte cert[] is a pointer to the certificate data in the form of an array of bytes.
698+
* `<tt>const` byte cert[] is a pointer to the certificate data in the form of an array of bytes.
1568699

1569-
* `int` certLength specifies the length of the certificate data array.
700+
* `<tt>int` certLength specifies the length of the certificate data array.
1570701
<hr />
1571702

1572703
### `write` <a id="class_wi_fi_s_s_l_client_1aa998458d525200ce36277d637008f87c" class="anchor"></a>
@@ -1578,7 +709,7 @@ virtual size_t write(uint8_t)
1578709
Writes a single byte of data to the SSL connection.
1579710
1580711
#### Parameters
1581-
* `b` is the byte to be sent.
712+
* `<tt>b</tt>` is the byte to be sent.
1582713
1583714
#### Returns
1584715
The number of bytes successfully written. Returns `1` if the byte was sent successfully, or `0` if an error occurred.
@@ -1593,9 +724,9 @@ virtual size_t write(const uint8_t * buf, size_t size)
1593724
Writes a buffer of data to the SSL connection.
1594725

1595726
#### Parameters
1596-
* `buf` is a pointer to the buffer containing the data to be sent.
727+
* `<tt>buf</tt>` is a pointer to the buffer containing the data to be sent.
1597728

1598-
* `size` is the number of bytes to send from the buffer.
729+
* `<tt>size</tt>` is the number of bytes to send from the buffer.
1599730

1600731
#### Returns
1601732
Returns `size` if the data is successfully sent, or `0` if the transmission fails or the socket is invalid.
@@ -1634,7 +765,7 @@ virtual int read(uint8_t * buf, size_t size)
1634765
Reads a specified number of bytes from the SSL connection into a buffer.
1635766
1636767
#### Parameters
1637-
* `buf` is a pointer to the buffer where the read data will be stored. `size` is the maximum number of bytes to read into the buffer.
768+
* `<tt>buf</tt>` is a pointer to the buffer where the read data will be stored. `size` is the maximum number of bytes to read into the buffer.
1638769
1639770
#### Returns
1640771
The number of bytes successfully read. Returns `0` if no data is available or an error occurs.
@@ -1710,7 +841,7 @@ virtual bool operator==(const WiFiSSLClient &)
1710841
Comparison operator to check equality between two `[WiFiSSLClient](#class_wi_fi_s_s_l_client)` objects.
1711842

1712843
#### Parameters
1713-
* `WiFiSSLClient` object to compare.
844+
* `<tt>WiFiSSLClient</tt>` object to compare.
1714845

1715846
#### Returns
1716847
`true` if both [WiFiSSLClient](#class_wi_fi_s_s_l_client) objects are equivalent (i.e., they have the same socket), `false` otherwise.
@@ -1727,7 +858,7 @@ Inequality operator to compare two `[WiFiSSLClient](#class_wi_fi_s_s_l_client)`
1727858
This operator compares the current `[WiFiSSLClient](#class_wi_fi_s_s_l_client)` object with another `[WiFiSSLClient](#class_wi_fi_s_s_l_client)` object to determine if they are not equal, based on their underlying socket or connection.
1728859

1729860
#### Parameters
1730-
* `whs` The [WiFiSSLClient](#class_wi_fi_s_s_l_client) object to compare with.
861+
* `<tt>whs</tt>` The [WiFiSSLClient](#class_wi_fi_s_s_l_client) object to compare with.
1731862

1732863
#### Returns
1733864
`true` if the two [WiFiSSLClient](#class_wi_fi_s_s_l_client) objects do not represent the same connection (i.e., have different sockets), `false` otherwise.
@@ -1820,7 +951,7 @@ virtual uint8_t begin(uint16_t)
1820951
Starts a UDP socket on the specified local port.
1821952
1822953
#### Parameters
1823-
* `uint16_t` The local port number to bind the UDP socket to.
954+
* `<tt>uint16_t</tt>` The local port number to bind the UDP socket to.
1824955
1825956
#### Returns
1826957
Returns `1` if the socket is successfully opened, or `0` if the socket is already in use or could not be opened.
@@ -1835,9 +966,9 @@ virtual uint8_t begin(IPAddress a, uint16_t p)
1835966
Starts a UDP socket bound to a specific IP address and port.
1836967

1837968
#### Parameters
1838-
* `a` The local IP address to bind the UDP socket to.
969+
* `<tt>a</tt>` The local IP address to bind the UDP socket to.
1839970

1840-
* `p` The local port number to bind the UDP socket to.
971+
* `<tt>p</tt>` The local port number to bind the UDP socket to.
1841972

1842973
#### Returns
1843974
Returns `1` if the socket is successfully opened, or `0` if the socket is already in use or could not be opened.
@@ -1852,9 +983,9 @@ virtual uint8_t beginMulticast(IPAddress, uint16_t)
1852983
Starts a UDP multicast socket bound to a specific IP address and port.
1853984
1854985
#### Parameters
1855-
* `IPAddress` The multicast IP address to bind the UDP socket to.
986+
* `<tt>IPAddress</tt>` The multicast IP address to bind the UDP socket to.
1856987
1857-
* `uint16_t` The port number to bind the UDP socket to.
988+
* `<tt>uint16_t</tt>` The port number to bind the UDP socket to.
1858989
1859990
#### Returns
1860991
Returns `1` if the socket is successfully opened, or `0` if the socket is already in use or could not be opened.
@@ -1891,9 +1022,9 @@ virtual int beginPacket(IPAddress ip, uint16_t port)
18911022
Begins constructing a UDP packet for sending to a specific IP address and port.
18921023
18931024
#### Parameters
1894-
* `ip` The destination IP address as an `IPAddress` object.
1025+
* `<tt>ip</tt>` The destination IP address as an `IPAddress` object.
18951026
1896-
* `port` The destination port number.
1027+
* `<tt>port</tt>` The destination port number.
18971028
18981029
#### Returns
18991030
Returns `1` if the packet preparation is successful. Or `0` if there is an error or the socket is not initialized.
@@ -1908,9 +1039,9 @@ virtual int beginPacket(const char * host, uint16_t port)
19081039
Begins constructing a UDP packet for sending to a specific hostname and port.
19091040

19101041
#### Parameters
1911-
* `host` The destination hostname as a null-terminated string.
1042+
* `<tt>host</tt>` The destination hostname as a null-terminated string.
19121043

1913-
* `port` The destination port number.
1044+
* `<tt>port</tt>` The destination port number.
19141045

19151046
#### Returns
19161047
Returns `1` if the packet preparation is successful. Or `0` if there is an error or the socket is not initialized.
@@ -1937,7 +1068,7 @@ virtual size_t write(uint8_t)
19371068
Sends a single byte of data to the currently opened UDP packet.
19381069
19391070
#### Parameters
1940-
* `b` The byte of data to send.
1071+
* `<tt>b</tt>` The byte of data to send.
19411072
19421073
#### Returns
19431074
Returns `1` if the byte was successfully written. Or `0` if there was an error or the packet was not properly initialized.
@@ -1952,9 +1083,9 @@ virtual size_t write(const uint8_t * buffer, size_t size)
19521083
Sends a buffer of data to the currently opened UDP packet.
19531084

19541085
#### Parameters
1955-
* `buffer` A pointer to the buffer containing the data to send.
1086+
* `<tt>buffer</tt>` A pointer to the buffer containing the data to send.
19561087

1957-
* `size` The number of bytes from the buffer to write.
1088+
* `<tt>size</tt>` The number of bytes from the buffer to write.
19581089

19591090
#### Returns
19601091
Returns the number of bytes successfully written if the operation is successful. Or `0` if the data was not successfully written, or if the packet was not properly initialized.
@@ -2005,9 +1136,9 @@ virtual int read(unsigned char * buffer, size_t len)
20051136
Reads data from the UDP receive buffer into a provided buffer.
20061137
20071138
#### Parameters
2008-
* `buffer` A pointer to the buffer where the received data will be stored.
1139+
* `<tt>buffer</tt>` A pointer to the buffer where the received data will be stored.
20091140
2010-
* `size` The number of bytes to read from the UDP buffer.
1141+
* `<tt>size</tt>` The number of bytes to read from the UDP buffer.
20111142
20121143
#### Returns
20131144
The number of bytes successfully read into the buffer. If less than `size` bytes are read, it indicates that the buffer was exhausted early.
@@ -2022,9 +1153,9 @@ inline virtual int read(char * buffer, size_t len)
20221153
Reads data from the UDP receive buffer into a character buffer.
20231154

20241155
#### Parameters
2025-
* `buffer` A pointer to the character buffer where the received data will be stored.
1156+
* `<tt>buffer</tt>` A pointer to the character buffer where the received data will be stored.
20261157

2027-
* `len` The number of bytes to read from the UDP buffer.
1158+
* `<tt>len</tt>` The number of bytes to read from the UDP buffer.
20281159

20291160
#### Returns
20301161
The number of bytes successfully read into the buffer. If less than `len` bytes are read, it indicates that the buffer was exhausted early.
@@ -2063,7 +1194,7 @@ Compares two [WiFiUDP](#class_wi_fi_u_d_p) objects for equality.
20631194
This function compares two `[WiFiUDP](#class_wi_fi_u_d_p)` objects by checking if their associated socket values (`_sock`) are the same.
20641195

20651196
#### Parameters
2066-
* `WiFiUDP&` The [WiFiUDP](#class_wi_fi_u_d_p) object to compare with the current object.
1197+
* `<tt>WiFiUDP&</tt>` The [WiFiUDP](#class_wi_fi_u_d_p) object to compare with the current object.
20671198

20681199
#### Returns
20691200
`true` if the socket values are equal, `false` otherwise.
@@ -2080,7 +1211,7 @@ Compares two [WiFiUDP](#class_wi_fi_u_d_p) objects for inequality.
20801211
This function compares two `[WiFiUDP](#class_wi_fi_u_d_p)` objects by checking if their associated socket values (`_sock`) are different.
20811212

20821213
#### Parameters
2083-
* `whs` The [WiFiUDP](#class_wi_fi_u_d_p) object to compare with the current object.
1214+
* `<tt>whs</tt>` The [WiFiUDP](#class_wi_fi_u_d_p) object to compare with the current object.
20841215

20851216
#### Returns
20861217
`true` if the socket values are different, `false` otherwise.

0 commit comments

Comments
 (0)
Please sign in to comment.