Quantcast
Channel: Forums - Recent Threads
Viewing all articles
Browse latest Browse all 262198

LAUNCHXL-CC2640R2: How to make Simple_Peripheral on the Launchpad CC2640R2 to continue advertising even after it is connected

$
0
0

Part Number:LAUNCHXL-CC2640R2

I tried adding the compiler define, and turn on advertising in the connect event of the application.  It hangs.  Is there a better suggestion.

case GAPROLE_CONNECTED:
{
// Get the active connection handle
/*-------------------------------------------------------------------------------
* Make advertisements non-connectable turn advertising back on.
*--------------------------------------------------------------------------------*/
uint8_t advType = GAP_ADTYPE_ADV_NONCONN_IND; // use non-connectable adv
GAPRole_SetParameter(GAPROLE_ADV_EVENT_TYPE, sizeof(uint8_t), &advType);

uint8_t nonconn_enable = TRUE;
GAPRole_SetParameter(GAPROLE_ADVERT_ENABLED, sizeof(uint8_t), &nonconn_enable);

uint16_t connHandle = 0;
Display_print0(dispHandle, 2, 0, "Connected");
GAPRole_GetParameter(GAPROLE_CONNHANDLE, &connHandle);

}


Viewing all articles
Browse latest Browse all 262198

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>