This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Number of Completed packets event

Other Parts Discussed in Thread: CC2540

I am trying to limit the number of queued up notification packets so I am trying to use the Number of Completed packets event. I call:

HCI_EXT_NumComplPktsLimitCmd(2, LL_EXT_ENABLE_NUM_COMPL_PKTS_ON_EVENT);

and I assume I should be receiving HCI_NUM_OF_COMPLETED_PACKETS_EVENT_CODE events but I'm not getting any HCI events at all. Can someone please tell me how to receive these events or if there is a better way to limit the queued packets.

  • Hi,

    HCI events are sometimes swallowed by the Host layer when operating on the BLE SDK, because HCI (Host Controller Interface) is meant for messages from the host (could be a PC, in this case it's the host part of the stack) to the controller and vice versa.

    In any case, the command you mention is to my understanding meant for credit based flow control between host and controller. If you want to limit the number of queued up packets, you can instead modify the #define MAX_NUM_PDU in bleUserConfig.h.

    When you reduce this number, you will get a return value != success sooner than usual when you call for example GATT_Notification(...) because there are fewer buffers.

    Best regards,
    Aslak
  • Hi, Aslak N

    as for your mention above that "If you want to limit the number of queued up packets, you can instead modify the #define MAX_NUM_PDU in bleUserConfig.h." what about cc2540,using BLE stack 1.4.0. i also want to limit the number of queued up packets, how can i achieve that?
    i need your help,thanks a lot.
  • Hi,

    There is no facility for this on the CC254x controller stack, unfortunately.

    BR,
    Aslak

  • Thanks. this confused me last a week.i also post this to ask for help.following is my post link: https://e2e.ti.com/support/wireless_connectivity/f/538/t/441594. there are some question not answer.any suggestion will be appreciated.