1 Reply Latest reply on Jun 6, 2016 3:11 AM by cjoachim_1597296

    CyBle_GattsReadAttributeValue question.

    sec.ken

      Hi 

         

      I'm using CyBle_GattsReadAttributeValue API to storage in GATT Database,I read data from Android APP, not successful, what happend?

         

              case CYBLE_EVT_GATT_CONNECT_IND:
                  
                  UART_UartPutString("\n\rConnection established");             

                  
                  bufferData[0] = 1; 
                  bufferData[1] = 0x41;
                  bufferData[2] = 0x42;
                  
                  handleValuePair.value.val = bufferData;
                  handleValuePair.value.len = bufferDataLength;
                  handleValuePair.attrHandle = CYBLE_CUSTOM_READ_DECL_HANDLE;

         

                  if( CYBLE_GATT_ERR_NONE == CyBle_GattsReadAttributeValue(&handleValuePair,&cyBle_connHandle,CYBLE_GATT_DB_LOCALLY_INITIATED) )
                  {
                      UART_UartPutString("\n\rStorage GATT DataBase Successful!");             
                  }
                  else
                      UART_UartPutString("\n\rStorage GATT DataBase Error!"); 
                  //CyBle_ProcessEvents();
                  
                  break;