What is the issue if the aci_gap_set_discoverable is failed.
I am reading the "dm00294449-bluenrg-1-bluenrg-2-ble-stack-v2-x-programming-guidelines-stmicroelectronics.pdf " and created the coding accordingly. The recommended coding
void bluenrg_process(void)
{
tBleStatus ret;
//uint8_t local_name[] = {AD_TYPE_COMPLETE_LOCAL_NAME,'B','L','E','-','G','U','P'};
//const char local_name[] = {AD_TYPE_COMPLETE_LOCAL_NAME,'B','L','E','-','G','-','U','P'};
const char local_name[]=
{AD_TYPE_COMPLETE_LOCAL_NAME,'B','l','u','e','N','R','G','1','T','e','s',' t'};
/* Set device in General discovereable mode */
/*
* tBleStatus aci_gap_set_discoverable(uint8_t Advertising_Type,
uint16_t Advertising_Interval_Min,
uint16_t Advertising_Interval_Max,
uint8_t Own_Address_Type,
uint8_t Advertising_Filter_Policy,
uint8_t Local_Name_Length,
uint8_t Local_Name[],
uint8_t Service_Uuid_length,
uint8_t Service_Uuid_List[],
uint16_t Slave_Conn_Interval_Min,
uint16_t Slave_Conn_Interval_Max)
*
*/
//ret = aci_gap_set_discoverable(ADV_IND, 0, 0,
// PUBLIC_ADDR,
// NO_WHITE_LIST_USE,
// sizeof(local_name),local_name, 0, NULL, 0, 0);
ret = aci_gap_set_discoverable(ADV_IND, 100, 100, PUBLIC_ADDR,
NO_WHITE_LIST_USE, sizeof(local_name),
local_name, 0, NULL, 0, 0);
if (ret != BLE_STATUS_SUCCESS)
{
prnt("aci_gap_set_discoverable: FAILED !! [%x]\r\n");
}else {
prnt("aci_gap_set_discoverable OK\r\n");
} /* end GAP_Peripheral_Make_Discoverable() */
}
