This function adds a MAC address to the accept filter.
Input:
MAC: STRING
The MAC address to add to the accept filter.
Returns: INT
1
|
-
|
_BLE_OK
|
|
Success
|
0
|
-
|
_BLE_ERR_NOT_SUPPORTED
|
|
The API is not supported.
|
-1
|
-
|
_BLE_ERR_NOT_OPEN
|
|
The interface is not powered(see blePower).
|
-8
|
-
|
_BLE_ERR_INVAL
|
|
Invalid MAC address.
|
-99
|
-
|
_BLE_ERR_GENERIC
|
|
Failed to add address.
|
Declaration:
FUNCTION bleAcceptFilterAdd : INT;
VAR_INPUT
MAC : STRING;
END_VAR;
Example:
...
rc := bleAcceptFilterAdd(mac:=bleMacCreate(mac:="E3:1C:E6:43:F5:2D", type:=1));
...
|