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.

cc2541: Host MCU code for interfacing with network processor

Part Number: CC2541
Other Parts Discussed in Thread: CC2541, BLE-STACK

Hi,

I am trying to use the CC2541 as a network processor, connected over SPI with a host MCU running linux. Are there any host-side application examples? I am running HostTestRelease with the gatt database off chip (in order to received hci messages when attributes are written to)

Thanks

  • Hi Sam,

    Are you looking for an embedded example or a PC application? You can find both at www.ti.com/ble-wiki in the CC254x section.

    Is there a reason you are interested in using the CC2541 over the CC26xx or CC2640R2 devices? Are you interested in being a central device or a peripheral?

    The CC26xx has support for BLE4.2 features and the BLE-Stack v2.2.1 SDK which it uses has a Simple Network Processor example that works well with the MSP432 Bluetooth Plugin. This would give you several host-side examples. It has the additional benefit of being available in a pre-certified module.

    The CC2640R2 is our newest device which has support for BLE4.2 features. It has more available flash than the CC26xx and is Bluetooth 5 ready.
  • Hi Rachel,

    The module I am working on already has a CC2541 onboard, interfaced by SPI to a host MCU (running a flavor of linux), so unfortunately a CC26xx is not an option for me.

    I am interested in being a peripheral device. My goal is to for the module to advertise itself as a peripheral with several GATT services, and allow a PC or phone to connect over bluetooth and write values to the gatt characteristics. The MCU would then act upon the values written.

    I know that if I am going to use HostTest, I need to compile with GATT_DB_OFF_CHIP so that the HCI events notifying of updated gatt attributes are transmitted over SPI to the host. My question is: is there any example code for the MCU side, to implement the GATT database and/or handle the HCI events coming back from the CC2541?

    Thanks

    Sam

  • Hi Sam,

    If you have to use the CC2541 with another MCU, you should look through the wiki page I referenced previously: http://www.ti.com/ble-wiki

    Here is a page that may help you: http://processors.wiki.ti.com/index.php/CC254X_WITH_EXT_MCU

  • There are also some community examples of interfacing Host Test to a linux host at the CC254x PC Examples page: processors.wiki.ti.com/.../CC254X_PC_Examples
  • That is helpful. I don't see an example in those pages of setting up a GATT database on the host (to use with the GATT_DB_OFF_CHIP option). Are there any example solutions?