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.

CC3000 - Minimum buffer size, maximum number of buffers

Hi all,

We have a real-time data acquisition system that needs to send 80 bytes every 140 usec (~7000 Hz). Thus we'd like the CC3000 to run with small buffer sizes, but many buffers. The reason we think we need more buffers is that our present protoype system (based on the MSP430 FRAM TiWi Eval board, and the Basic WiFi App) periodically stalls waiting for more free buffers (when it "unstalls" the free buffers alternates between 1 and 3).

What is the minimum buffer size, and the maximum number of buffers? Also, what is the total size of the CC3000's buffer memory?

Thanks!

Leo

 

  • Hi Leo,


    The current driver supports a minimum buffer size of 119 bytes for Rx and 119 bytes for Tx. The number of buffers is dependent on the MCU used and the specific application that is running.
    Basically it would be deducted from the available RAM size that the application leaves free for the usage of the driver (removing global variable and stuck size).
    In addition, in MCUs from the FRAM family, it is possible to move the data buffers to the Flash memory, which in most cases will increase the possibility to use more buffers.

    Thanks,
    Alon.S

  • Thanks Alon,

    Does this mean that the CC3000 has no internal buffering?

    Where are the Rx and Tx buffers declared in the C source code? That is, what are their names?

    Also, in HostFlowControlConsumeBuff() below (copied from socket.c), what is the function of the variable tSLInformation.usNumberOfFreeBuffers?

    int HostFlowControlConsumeBuff(int sd)
    {
    /* wait in busy loop */
    do
    {
    //
    // In case last transmission failed then we will return the last failure reason here
    // Note that the buffer will not be allocated in this case
    //
    if (tSLInformation.slTransmitDataError != 0)
    {
    errno = tSLInformation.slTransmitDataError;
    tSLInformation.slTransmitDataError = 0;
    return errno;
    }
    if(SOCKET_STATUS_ACTIVE != get_socket_active_status(sd))
     return -1;
    } while(0 == tSLInformation.usNumberOfFreeBuffers);
    tSLInformation.usNumberOfFreeBuffers--;

    return
    0;
  • Hi Leo,

    The CC3000 has internal buffers in addition to the ones in the MCU side.

    The "HostFlowControlConsumeBuff()" function is used to keep track on the available buffers in the CC3000 and make sure that we don't send data if there are no free buffers in the CC3000.

    After each packet sent, the CC3000 will raise an unsolicited event, stating the current number of available buffers.

    Please refer to the our wiki for more information on this feature: http://processors.wiki.ti.com/index.php/CC3000_Host_Programming_Guide#Data_Transmission_Overview

    Thanks,
    Alon.S