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.

BSC_Initialize returns BTPS_ERROR_HCI_INITIALIZATION_ERROR

I am working with a Stellaris LM3S9D96 and PAN1325 in our project, and Bluetooth refuses to initialize.

Stepping through InitializeBluetooth, the failure happens in BSC_Initialize(), for which I have no source code, and

it returns a value of -4, which looks to be BTPS_ERROR_HCI_INITIALIZATION_ERROR.

I'm using code derived from the standard DK-LM3S9D96 eval software.

I noticed that the eval kit we have uses a PAN1323, and the unmodified eval software for Bluetopia works just fine with that module.

Are there known compatibility issues between the two modules (1325 and 1323), or their components?  If so, is there anything like a patch for software to take care of the issue?

Thanks,

Ron Sturtevant

  • Hi Ron,

    This indicates that there is something wrong with the HCI UART interface between the two devices, most likely during loading of the service patch. For the PAN1325, you will have to make sure __SUPPORT_PAN1315_PATCH__ is defined in BTPSVEND.c to include "Patch_PAN1315.h" instead of #include "Patch_PAN1316.h"

  • Hi Zahid,

    based on what you've written here, I'm not sure of the code we have in Stellarisware.  I can't find a reference to Patch_PAN1315.h in BTPSVEND.c, nor do I find an area of the code with #ifdef __SUPPORT_PAN1315_PATCH__

    What I do have is BTSVEND.c having the following in the top of the file:

    /******************************************************************************/
    /* Copyright 2011 Stonestreet One, LLC                                        */
    /* All Rights Reserved.                                                       */
    /* Licensed under the Bluetopia(R) Clickwrap License Agreement from TI        */
    /*                                                                            */
    /*  BTPSVEND.c - Stellaris(R) Bluetooth Chipset Vendor Specific Implementation*/
    /*               for Stonestreet One, LLC Bluetopia(R) Bluetooth Protocol     */
    /*               Stack.                                                       */
    /*                                                                            */
    /******************************************************************************/
    #include "SS1BTPS.h"          /* Bluetopia API Prototypes/Constants.          */
    #include "HCIDRV.h"
    #include "HCITRANS.h"

    #include "bt_ucfg.h"          /* Vendor user configuration constants.         */

    #include "SS1BTVS.h"          /* TI Vendor Specific Prototypes/Constants.     */

    #include "BTPSKRNL.h"
    #include "BTPSVEND.h"

       /* Configuration Constants.                                          */
    #ifndef VENDOR_BAUD_RATE

       #define VENDOR_BAUD_RATE   921600L

    #endif

       /* Internal Variables to this Module (Remember that all variables    */
       /* declared static are initialized to 0 automatically by the         */
       /* compiler as part of standard C/C++).                              */

    #ifdef __SUPPORT_PAN1315ETU__
       /* The following is the binary representation of the Patch Data.     */
    static const unsigned char Patch[] =
    {
       0x01,0x37,0xFE,0x02,0x02,0x1F,0x01,0x0F,0xFD,0x01,0x01,0x01,0x63,0xFD,0x1C,0x04,
       0x04,0x00,0xBC,0x02,0xEF,0xCD,0xAB,0x89,0xEF,0xCD,0xAB,0x89,0x03,0x06,0x0A,0x20,
       0x03,0x4B,0x38,0x1F,0xBF,0xB5,0xB0,0x01,0x08,0x06,0x0D,0x01,0x01,0xFF

        etc, etc, etc.

    So, do I have the latest code, and if not, can you send me a link to that?

    Ron Sturtevant

  • Okay, I downloaded the SDK and installed it, but unlike any other installer I've obtained from TI, this one doesn't allow me to choose a directory for installation, and I'm not sure where everything went at this point.  checking around, but I see no difference in my Stellarisware directory.

    I've tried to attached some Bluetopia files from Stellarisware for you to look at; I think they are current, but if you would check them for me I'd appreciate it.  If the attachement didn't not work, I'll need an email address I can send these to.

    Ron

    2437.StellarisWare_Bluetopia_Safertos.zip

  • Hello Ron,

    This should have a zip folder that you can use. The release notes have more information if you need. Please try the latest release and let us know if you are still seeing the error.

    Best Regards,

    Stonestreet One. 

  • Well, I don't see any attachment I can grab on to in your post - can you try to send it again?

    Ron

  • Hi Ron,
    Sorry I meant the installation. It should install all the required files in C:\TI\Connectivity\CC256X BT\CC256x Stellaris Bluetopia SDK\v1.0. This is also accessible from the start menu->All Programs->Texas Instruments->CC256X BT->CC256x Stellaris Bluetopia SDK V1.0. The Wiki Pages also include information on getting started, loading a profile etc. http://processors.wiki.ti.com/index.php/Stellaris_Bluetopia_Basic_Demo_APPS

     

    Regards,

    StonestreetOne Support.

  • okay, got it.  I'll let you know how it goes.

  • well, it didn't work out so well in my existing project.  The new SDK breaks my compile in the current StellarisWare a2dp_safertos.  I attemted to replace the old Bluetopia directory in C:\StellarisWare, and the compile complains about missing header files.  Pacthing files in, and patching, etc, leads to a compile that has errors on the link.  So, I have backed out those additions and am back to square one with my old project compiling correctly.

    Next step, I imported the new sample for A2DP

    (C:\TI\Connectivity\CC256X BT\CC256x Stellaris Bluetopia SDK\v1.0\CC256x_Stellaris_Bluetopia_Applications\Sample\A2DPDemo\SafeRTOS)

    into code composer and attempted a compile (2 minutes ago), and it obviously has issues as well, as it tells me it can't find files & rules for building them.  Attached is the error list.

    Help, please.

    Ron

  • Hi Ron, are you following this wiki:

    http://processors.wiki.ti.com/index.php/Stellaris_Bluetopia_Basic_Demo_APPS

    Are you still facing problems? I do not see attached the error list.

  • Hi Ron,

    Can you please confirm if you were able to build the release successfully. We have received your feedback about the issues you faced with paths and scripts and are working on getting that resolved. But please let us know if you are still facing build issues.

    Best regards,

    Stonestreet One. 

  • I was able to successfully build the release, download it, and test it on the eval board.  The main issue was the import function not setting paths correctly, but since TI's own projects also have issues with pathing, that isn't just your projects.  Thanks for your support.

    Ron

  • Hi Ron,

    Which IDE and version are you using? Perhaps it is a compiler issue? How did you fix the issue?

     

  • The IDE I'm using is Code Composer Studio, Version: 5.3.0.00090

    I fixed the problems by checking each and every path and predefined variable that resulted from the import into CCS, fixing the ones that weren't correct.  As I stated before, this isn't just a SS1 issue, TI's own Bluetopia project in the Stellarisware tree also had issues like this that were resolved the same way.