What parameter allows for the automatic connection of the central and peripheral device?
Solved! Go to Solution.
Hi Jim,
Do you mean how the auto connection happening in GitHub project UART to BLE (https://github.com/cypresssemiconductorco/PSoC-4-BLE/tree/master/100_Projects_in_100_Days/Day020_BLE...) ?
If then, its upon checking the adv data. Please check in the CYBLE_EVT_GAPC_SCAN_PROGRESS_RESULT of Central project.
if((advReport->eventType == CYBLE_GAPC_SCAN_RSP) && (advReport->dataLen == 0x06) \
&& (advReport->data[1] == 0xff) && (advReport->data[2] == 0x31) \
&& (advReport->data[3] == 0x01) && (advReport->data[4] == 0x3b) \
&& (advReport->data[5] == 0x04))
{
peerDeviceFound = true;
:
:
Thus the peripheral BLE component the adv data is set the same.
As soon as Central receives adv packet , it will check the adv data , and if same as expected it will send connection request.
Thanks,
Anjana
Hi Jim,
Do you mean how the auto connection happening in GitHub project UART to BLE (https://github.com/cypresssemiconductorco/PSoC-4-BLE/tree/master/100_Projects_in_100_Days/Day020_BLE...) ?
If then, its upon checking the adv data. Please check in the CYBLE_EVT_GAPC_SCAN_PROGRESS_RESULT of Central project.
if((advReport->eventType == CYBLE_GAPC_SCAN_RSP) && (advReport->dataLen == 0x06) \
&& (advReport->data[1] == 0xff) && (advReport->data[2] == 0x31) \
&& (advReport->data[3] == 0x01) && (advReport->data[4] == 0x3b) \
&& (advReport->data[5] == 0x04))
{
peerDeviceFound = true;
:
:
Thus the peripheral BLE component the adv data is set the same.
As soon as Central receives adv packet , it will check the adv data , and if same as expected it will send connection request.
Thanks,
Anjana