Trying to get a connection with a TI CC2564 Bluetooth Module

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Trying to get a connection with a TI CC2564 Bluetooth Module

4,049 Views
m_w1
Contributor I

Hi,

i am trying to communicate with a Bluetooth Module CC2564B  (MODNEM) of Texas Instruments with my Kinetis K10 (Cortex M4).

Has anybody made experience with that combination before?

There is the need of loading a Service Pack (.bts-file) onto the Module. I used the Download for CC2564B BT 4.1 SP in the following link:

CC256x Downloads - Texas Instruments Wiki

It can to be converted to a .h-file with a TI-software (CC256x Bluetooth Hardware Evaluation Tool - Texas Instruments Wiki)

Now there is the problem that everytime i try to send the bts-file as hex (i converted the service pack before), the RTS becomes 'HIGH' and doesn't react anymore. RTS must be 'LOW' after a proper Power-Up sequence (as described in CC256x Testing Guide - Texas Instruments Wiki ). With the hex dump 0x01 0x01 0x10 0x00 you get the firmware-version of the module which you need no service pack for. So if i send this hex dump before the service pack, it works. Afterwards, it doesn't. So the problem seems to be down to a correct transmission of the service pack.

Anyone got a suggestion how to achieve a correct transmission of the service pack via a K10 / Cortex M4? All i find about is with MSPs and Python...

Thanks in advance,

Regards

Max

0 Kudos
Reply
4 Replies

2,187 Views
markbennett
Contributor I

Hi Max,

We're also looking to use the CC2564 with a Kinetis K61.  What device stack did you end up using for your project?  As far as I could tell from the TI website, the Bluetopia stack the offer doesn't seem to be available for the Kinetis -- at least it's not listed.

Thanks!

Mark

0 Kudos
Reply

2,187 Views
isaacavila
NXP Employee
NXP Employee

Hello Max,

According to CC 256 Manual, your BT chip supports UART communication using flow control (CTS and RTS: Hardware control for H4 protocol or XON/XOFF software control for H5 protocol), you must ensure that your UART communication accomplishes these requirements. (UART with Flow control)

Are you using your own UART drivers? If so, please, make sure to enable the proper flow control process so communication between your BT chip and your MCU could be successful.

Regards,

Isaac

0 Kudos
Reply

2,187 Views
m_w1
Contributor I

Hi Isaac,

i forgot to mention that i'm using H5 (Three-Wire-Protocol). So therefore i need XON/XOFF, how do i realise that with HTERM or via a C-code in codewarrior while sending commands to the BT module?As far as i know HTERM doesn't provide a possibility for XON/XOFF.

All i do now is sending the service pack data. What must i send for XON/XOFF before/during/after the transmission? If you could please post an example, that would be very helpful.

Thanks in advance!

Regards,

Max

0 Kudos
Reply

2,187 Views
isaacavila
NXP Employee
NXP Employee

Hello Max,

I was reviewing your chip reference manual,  and it says:

"All members of the CC256x family support the H4 protocol (4-wire UART) with hardware flow control. The CC2560B and CC2564B devices also support the H5 protocol (3-wire UART) with software flow control. The CC256x device automatically detects the protocol when it receives the first command."

So, I would like to know if your chip is detecting correctly the used protocol:

On your previous question you mentioned about RTS logic state and then you mentioned about your are using H5 protocol, there is no need to use these lines (RTS and CTS) when using H5 protocol so maybe your chip is detecting your UART communication as H4 instead of H5.

When using H5 protocol, Bluetooth specification mentioned about Software Flow control, Software flow control (XON/XOFF) consists on sending XOFF character from RX side when there is no more space on receiver, so, this way, transmitter will have to stop sending bytes until XON character is received from receiver.

Basically, you need to ensure that when a XOFF character is received from your BT chip, your Kinetis Transmitter will stop sending more byte until XON character is received and transmission will be resumed.

Awfully, i don't have an example about it but this is technically easy to implement. You should find which character represents a XOFF and XON (I quickly looked for this information and your BT chip's reference manual refers about consulting Bluetooth Specification (Vol 4: Host controller Interface, Part D: Three-wire UART transport Layer: 10 Out of frame control))

if you want to use H4 protocol, it uses hardware flow control, and Kinetis supports it too.

I attached a example code (it is done for TWR-K60N512) where hardware flow control is tested, basically, I communicate UART0 with UART1 using hardware flow control (and FIFO capability too). You can see that RTS and CTS lines are controlled by hardware and transmitter will transmit remaining bytes when receiver is capable to received them.

i will recommend you to try both protocols and see if you can have a successful communication with one of them. Also you should look for an example (from TI) and see if there is a special procedure to start communicating with your chip.

Hope this helps,

Best Regards,

Isaac Avila

0 Kudos
Reply