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.

HostTest project on CC2650

Other Parts Discussed in Thread: CC3200, CC2650, CC2640

Hi, 

I am trying to connect CC3200 to CC265 using SPI connection and running 2650 as a central device . Would host test project would satisfy the needs for the task ?
If so what modification would be required to do so. 

  • Hi Sid,
    Ideally you would use our CC2650 in a two chip solution as a network processor using our Simple Network Processor (SNP) project. But we only support peripheral mode as of now. So I would recommend using SimpleBLECentral project and just adding in the SPI drivers.

    Best wishes
  • Hi Zahid,

    So Can I use hci commands on the SPI then.
  • Hi Sid,

    If you would like to interface to the CC2650 via HCI commands then yes, HostTestApp is exactly what you're looking for. UART and SPI are supported.
  • Hi Sean,

    Just to confirm a few things before I move forward with this architecture.

    1) I could use Host test on cc2650 to use it in central mode and give commands from 3200 on SPI and UART .
    2) Can I start just sending command on SPI from 3200 , Is it already configured or requires some changes
  • Sid,

    So long as you follow the steps for compiling the hosttestapp project correctly for SPI and use the correct pins, the device should be ready to accept HCI commands at boot. However, operating at the HCI layer requires a good understanding of bluetooth, and would be a serious software development effort. That being said, everything you're looking for is possible.

    If maybe you're not familiar with the HCI layer or BLE then it perhaps could be better to use the simpleBLECentral project and add a SPI driver as Zahid suggested.

    What is your use case?
  • I have currently compiled host test and used it using the Btool and it worked perfectly well for all the functionalities I need I would prefer using the hci commands over SPI so most of the development can be performed on the 3200 , So that I could just send commands to 2640 and receive the data on 3200 and do all the processing there. I actually went through the TI_BLE_Vendor_Specific_HCI_Guide inorder to understand the hci layer.

    I am correct about the way I intend to use it . Is any further documentation I could find about this
  • Hello Sean2, you said "So long as you follow the steps for compiling the hosttestapp project correctly for SPI and use the correct pins, the device should be ready to accept HCI commands at boot."

    Is there any documentation on the steps for compiling the hosttestapp for SPI? How do you configure the correct pins? We are trying to design a custom board using CC2640 and we want to build and load the hosttest firmware into CC2640, and then issue HCI commands from our main microcontroller.

    I have loaded the host_test_cc2640lp_app and host_test_cc2640lp_stack into CCS and gotten them to build. However, I am unsure how to specify SPI mode instead of UART mode. I am also unsure how to specify which pins to use for the SPI interface.

    Thanks for your help,
    Matthew
  • Hi Matthew,

    Changing the build configuration of the host_test project to FlashROM_SPI will setup the device to use SPI.

    The SPI used will be Board_SPI1, this is configured in npi_config.h. For the pinout of the Board_SPI1 module, look at the board file for your device. (src\boards\CC2650_LAUNCHXL).

    Note that you'll need MRDY/SRDY, see the NPI wiki here processors.wiki.ti.com/.../NPI
  • Thanks much Sean, I appreciate it!

    Our custom PCB is using the CC2640F128RSM variant with only 32 pins. Do you know if that part contains both SPI0 and SPI1 peripherals?

    Would it be strange to use the CC2650_LAUNCHXL board file for a custom board? Or should I start with the EM board and change the build define to CC2650DK_4XS ?

    Is MRDY/SRDY necessary for SPI interface? I was under the impression that that was just for UART interfaces.
  • Matthew,

    Yes, the RSM package size has less GPIOs but you still have both SPI peripherals available. You can set all of this in the board file. Since the RSM is based off the the 7x7 package, I would start with the LaunchXL board file and modify as necessary from there.

    yes MRDY/SRDY is always required for SPI regardless of POWER_SAVINGS settings.
  • Edit: the RSM is based on the 4x4mm package. I would base it off the of the 4xD board file and modify from there.
  • For SPI interface to CC26XX, is the traditional SPI chip-select (CS) pin used at all? Or is it just SCK, MISO, MOSI plus MRDY and SRDY?

  • The CC2650D_4XS.h file only contains references to SPI0, are you certain that the 4x4 chip supports SPI1?

    The npi_config.h file contains "error "NPI ERROR: Board_SPI1 SPI module must be used for NPI."" - Is this true, that you must use SPI1 instead of SPI0?