Hi,
im trying to send a indication from a CC2540, BLE Stack 1.3 to iOS. the indication gets there (didUpdateValue gets called), but i never get the confirmation. here is how i send the indication:
attHandleValueInd_t indi;
gattAttribute_t *pAttr = GATTServApp_FindAttr(oadAttrTbl, GATT_NUM_ATTRS(oadAttrTbl), oadCharVals+OAD_CHAR_PERIPHERAL_TX_HEADER);
indi.handle = pAttr->handle;
indi.len = 1;
indi.value[0] = length;
GATT_Indication(activeConnHandle, &indi, FALSE, simpleBLEPeripheral_TaskID);
void processGattMsg(gattMsgEvent_t *pMsg)
{
// is this a indicate confirm?
if(pMsg->method == ATT_HANDLE_VALUE_CFM)
{
gattAttribute_t *pAttr = GATTServApp_FindAttr(oadAttrTbl, GATT_NUM_ATTRS(oadAttrTbl), oadCharVals+OAD_CHAR_PERIPHERAL_TX_HEADER);
// tx header handle?
if(pAttr && pAttr->handle == pMsg->msg.handleValueInd.handle)
{
dumpUsartToBLE();
}
}
}
unfortunately i never get that confirmation.
the part I'm a bit confised about is that in iOS, there is no setIndicationValue, there is only setNotifyValue. so how does one, from iOS enable indications on the peripheral?
i have declared my characteristic as such:
static uint8 oadCharProps = GATT_PROP_WRITE_NO_RSP | GATT_PROP_WRITE | GATT_PROP_NOTIFY | GATT_PROP_INDICATE;
but because from iOS, i can only call setNotifyValue, i always end up with
uint16 oadTXHeaderConfigState = GATTServApp_ReadCharCfg(activeConnHandle, oadTXHeaderConfig);
returning 1 (aka notify) instead of 2 (aka indicate).
anyone got indication confirmations working with a BLE Stack peripheral and iOS?
thanks