3 Replies Latest reply on Mar 10, 2016 9:38 PM by gdebree1_1567901

    Sending multiple notification with ble

    user_396075877

      I continuous send 256Bytes to the phone in the notification mode.A packet is 20bytes and last packet is 16bytes.But the test failed,Only we can get three packets on the phone.The code stopped in this line: 

         

          while(CyBle_GattGetBusyStatus() == CYBLE_STACK_STATE_BUSY); 

         

      On the other hand,What is the maximum number of packets that CYBLE could process per connection event in  notification mode?

         

      thanks.

        • 1. Re: Sending multiple notification with ble
          Madhu Lakshmipathy

          Hi,

             

          If you add some delay betweene each packets, are you able to send the notifcaitons properly? Can you reduce the connection interval and see if it is working?

             

          Also, the max. MTU Size is 512 Bytes,

             

          Regards,

             

          -Madhu Sudhan

          • 2. Re: Sending multiple notification with ble
            rohit.kumar

            Hi,

               

            You need to take care of two things (in case you are not):

               

            1) Check if the stack memory is free to queue the notification data you send from application

               

            Before sending notifications, check if (CyBle_GattGetBusyStatus() == CYBLE_STACK_STATE_FREE). If yes, then send the notification, else wait for the memory to be cleared.

               

             

               

            2) You should call CyBle_ProcesEvents() atleast once, after calling the GattsNotification API. Calling multiple GattsNotification API before calling CyBle_ProcessEvents does not process the notification and only queues it, which overflows the internal memory.

               

             

               

            Additionally, you can set a higher MTU for the notification characteristic and let client request to update the MTU size.

            • 3. Re: Sending multiple notification with ble
              gdebree1_1567901

              If you are doing an Android app make sure you have the connection priority set to low latency if you don't already. You can set it back to balanced or low power after the transfer is done.