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.

SPP in CC2541

Other Parts Discussed in Thread: CC2541, CC2560, CC2540

Hello!
I want to ask some questions concerning CC2541F256RHAR chip. I used it in the diagram, but now I am afraid that made the wrong choice chips.
I need to create the channel of an exchange of serial data through an air. The exchange isn't constant, and occurs only in certain timepoints. Host-controler transfers data in the form of UART. I assumed that CC2541 will obtain the data UART and to transfer them to an air. And too with CC2541 use - to accept the receiver, and to transform again to UART.
For this purpose I assumed to use the SPP profile, however, as is clarified, it is absent in CC2541.
I yet wasn't engaged in detailed study of CC2541 therefore I want to get advice at you: how I can organize such half duplex transmission of serial data with CC2541 use?
Thanks in advance.

P.S. I am sorry if my question seems silly. I use for the first time BlueTooth as the developer. I will be grateful for any useful ideas.

  • Hi,

    I am afraid LE is wrong technology - Serial Port Profile is Bluetooth Classic/EDR profile, and single-mode BLE devices like CC254x has no support for these. Dual-mode BT 4.0 device or BT classic one (e.g. CC2560, Casira-based modules, etc.) will do.

    Having said that, what data rate are you aiming at? BLE is disaster when it comes to throughput (naturally, every low-power radio technology is!), but it is well-capable of several kilobits per second, and sometime it is enough. 

    If such speed is enough,  start with Bluetooth Core spec (it is free to download, and 2000+ pages - good reading :-D) and TI's sample projects that come with BLE stack. Basically, you'll want to create connection between two devices (one of which, master, will initiate and one will offer itself as connectable one), and repeatedly write/read values to attributes (pre-defined data field that are available for master device to write/read). 

    If you need more than 10kbyte/s, then BLE won't cut it, at least not with TI's stack. However, 2541 has support of so-called proprietary mode, allowing to program radio core at low level. No the easist way, though.

     

    Oleg

  • Data transmission rate at me low. Data packets have length of 75 bytes and at most 100 times a second (in reality less as packets are transferred only if data changed) are transferred. And as I already spoke, data are transferred in a two-way alternative operation.
    What can you advise in this situation? Unfortunately, to change a chip already it is very problematic.

    P.S. I am glad to meet the compatriot at a forum. ))))

  •  There are quite a few, actually :)

    Possibilities:

    1) Using CC2541 proprietary mode.

    I assume that it is not easy, or will take some time (you'll have to create radio link at much lower level than when using GAP/GATT facilities). But I have no experience with it, so maybe it is not actually hard. 

    Check this out: http://processors.wiki.ti.com/index.php/CC2541_Dual_Stack

    Judging by this, it looks that upcoming BLE 1.3 stack for CC254x devices should have support for native mode, which may make your task whole lot easier.

     

     2) Try to achieve this speed under BLE 1.2.1 IMHO.

    Risky. 7.5kbyte/s is a lot for BLE. Take a look at this example, though: http://processors.wiki.ti.com/index.php/CC2540_Data_Throughput

    If you have development kit, or hardware already produced and working, may as well give it a try. But, honestly, this data rate look unrealistic to me.

     

     3) Switch chips. Are you' plunged into this work with hardware already designed and in production? If hardware is not made and ICs are not bought yet, may be better to use another chip.

  • 1 . Of the same I thought initially, as alternative of SPP.
    2 . Thanks, I will look. But, I repeat, this speed - MAXIMUM, and improbable.
    3 . Unfortunately, the printed circuit board is already ready. Besides, there is no time for waiting of new chips.

  • I would like to specify by the third option. I want to check, it will be how difficult to remake ready pcb-board that instead of CC2541 to use CC2560 (I correctly understood, what you suggest to use it? ) .
    It would be desirable to manage already ready scheme, but time for development hasn't enough therefore I want to use it as reserve option, the device prototype is still made only.
    I would like to learn, whether you can guarantee that the CC2560 chip will be able to provide me the following conditions: there are two parts of the device (the main and dongle). They have to find independently each other and independently create connection then to exchange consecutive data at a speed of 7-8 kbyte/s (to create completely transparent UART-BT Bridge). Also one of processors (on the main device) will have to communicate with fuel-gas for control of level of a charge of the battery. Whether probably to apply CC2560 in this case?

  • 2) According to the link it is specified that speed 5.9kbyte/s is achievable. I looked at a format of my package if as much as possible to cut down additional information, I can reduce speed approximately to 5.5kbyte/s. But, unfortunately, it while a little than helps me because I don't know with what to begin. The processor for me new, with BT I never worked earlier. Perhaps, you can prompt what of examples needs to be taken me in BLE as a basis for work?
    Sorry, that I ask so many questions, simply situation very urgent, it is necessary to think over all reserve options.
    Thanks for your patience)))

  •  Hi 

    (1) may be most reliable speed-wise, if changing hardware is no-no.

    (2) CC256x has totally different package and, if I am not mistaking, needs host MCU to make use of Bluetooth via HCI interface (256x provides UART for this). CC2540 could be used that way, too (with host sending GATT/GAP or lower level HCI commands via UART). Still, their packages/pinouts are not same. 

    If you have CC2540 as a single device (no host MCU), then CC256x is probably out of question. 

    A system using CC2560 as a BT 2.1 endpoint will most certainly allow for more than 10kbyte/s. As of connection procedure - well, that's up to you to decide how the do it, but with SPP, there still will be initiator for SPP link, and there will still be a device passively waiting. I don't quite understand how the y could do it independently.

    For starters, just get TI's BLE stack at this wiki page. Do you have working hardware/development kit at hand? Their stack installation contains two staple examples of BLE Master and Slave devices (Central and Peripheral roles as they call it), they are good to start your own application with just minor changes. 

    Also, there is semi-useful MasterSlaveSwitch example, which contains very basic code for switching between Peripheral and Central devices.

    I do recommend to at least skim through so-called Bluetooth Core document. It is frighteningly large at first glance, but you don't need it all to start - just book 1 and book 6 (the latter is about BLE).

    BR,

    Oleg