Update Reference.md
This commit is contained in:
parent
48b21df329
commit
07eaef9523
|
|
@ -106,11 +106,17 @@ The following **optional** `homeSpan` methods enable additional features and pro
|
||||||
* *ssid* and *pwd* are automatically saved in HomeSpan's non-volatile storage (NVS) for retrieval when the device restarts
|
* *ssid* and *pwd* are automatically saved in HomeSpan's non-volatile storage (NVS) for retrieval when the device restarts
|
||||||
* note that the saved values are truncated if they exceed the maximum allowable characters (ssid=32; pwd=64)
|
* note that the saved values are truncated if they exceed the maximum allowable characters (ssid=32; pwd=64)
|
||||||
|
|
||||||
> :warning: SECURITY WARNING: The purpose of this function is to allow advanced users to *dynamically* set the device's WiFi Credentials using a customized Access Point function specified by `setApFunction(func)`. It it NOT recommended to use this function to hardcode your WiFi SSID and password directly into your sketch. Instead, use one of the more secure methods provided by HomeSpan, such as typing 'W' from the CLI, or launching HomeSpan's Access Point by typing 'A' from the CLI, to set your WiFi credentials without hardcoding them into your sketch.
|
> :warning: SECURITY WARNING: The purpose of this function is to allow advanced users to *dynamically* set the device's WiFi Credentials using a customized Access Point function specified by `setApFunction(func)`. It it NOT recommended to use this function to hardcode your WiFi SSID and password directly into your sketch. Instead, use one of the more secure methods provided by HomeSpan, such as typing 'W' from the CLI, or launching HomeSpan's Access Point, to set your WiFi credentials without hardcoding them into your sketch
|
||||||
|
|
||||||
* `void setWifiCallback(void (*func)())`
|
* `void setWifiCallback(void (*func)())`
|
||||||
* Sets an optional user-defined callback function, *func*, to be called by HomeSpan upon start-up just after WiFi connectivity has been established. This one-time call to *func* is provided for users that are implementing other network-related services as part of their sketch, but that cannot be started until WiFi connectivity is established. The function *func* must be of type *void* and have no arguments
|
* Sets an optional user-defined callback function, *func*, to be called by HomeSpan upon start-up just after WiFi connectivity has been established. This one-time call to *func* is provided for users that are implementing other network-related services as part of their sketch, but that cannot be started until WiFi connectivity is established. The function *func* must be of type *void* and have no arguments
|
||||||
|
|
||||||
|
* `void setPairingCode(const char *s)`
|
||||||
|
* sets the Setup Pairing Code to *s*, which **must** be exactly eight numerical digits (no dashes)
|
||||||
|
* a hashed version of the Pairing Code will be saved to the device's non-volatile storage, overwriting any currently-stored Pairing Code
|
||||||
|
* if *s* contains an invalid code, an error will be reported and the code will *not* be saved. Instead, the currently-stored Pairing Code (or the HomeSpan default Pairing Code if no code has been stored) will be used
|
||||||
|
* :exclamation: SECURTY WARNING: Hardcoding a device's Pairing Code into your sketch is considered a security risk and is **not** recommended. Instead, use one of the more secure methods provided by HomeSpan, such as typing 'S \<code\>' from the CLI, or launching HomeSpan's Access Point, to set your Pairing Code without hardcoding it into your sketch
|
||||||
|
|
||||||
* `void setSketchVersion(const char *sVer)`
|
* `void setSketchVersion(const char *sVer)`
|
||||||
* sets the version of a HomeSpan sketch to *sVer*, which can be any arbitrary character string
|
* sets the version of a HomeSpan sketch to *sVer*, which can be any arbitrary character string
|
||||||
* if unspecified, HomeSpan uses "n/a" as the default version text
|
* if unspecified, HomeSpan uses "n/a" as the default version text
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue