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.

RTOS/LAUNCHXL-CC2640R2: CC2640R2, Simple Peripheral, Data Transfer and related problems

Part Number: LAUNCHXL-CC2640R2
Other Parts Discussed in Thread: CC2640,

Tool/software: TI-RTOS

Hi All,

CC2640 Newbie here, so please be as clear as you can... My issue is this:

I was able to compile and run "simple-peripheral" application on my demo board. Also, I've compiled an app on Android which scans for (connectable) BLE devices. All in all, everything works perfect, I am able to scan, connect, read services and characteristics of my demo board. There is one problem, however,

I need the demo board to be able to send 4Mb of data to Android application (using BLE, of course), and perhaps receive 1Mb of data from the Android app. 

So, what is the best approach here? Shall the demo board be peripheral only? Is that enough to send and receive data?

Also, can anyone guide me to resources on how to modify the simple peripheral to send user defined data? I.e. if the advertisement data is sent using this function:

// Advertisement data (max size = 31 bytes, though this is
// best kept short to conserve power while advertising)
static uint8_t advertData[] =
{

...

}

It would be difficult to send all, 4Mb of data.

Can anyone help?

  • Hi Okan,

    Have you looked at SimpleLink Academy yet? I'd highly recommend it for anyone new to BLE and CC2640r2 since it includes labs that give step by step instructions that will help you modify the simple peripheral to send user defined data. 

    We have a few examples that send large amounts of data as well. Although they may not be exactly like your application, you can see how the application sets up and sends larger amounts of data. You can try looking at the audio streaming examples found on our GitHub. If you are planning on using BLE5, you can also look at the throughput examples found here.

     

    Let me know if you have any more questions.

    Regards,

    Jessica

    Please click the "This Resolved My Issue" button on this post if it answers your question

  • Hi Jessica,

    Thank you for sharing the link with me, was not aware of it beforehand.

    I've checked it and decided to install VoGP BLE peripheral project on my LAUNCHXL-CC2640R2 board. The project compiles and runs on the board, also sends some debug info on COM port as shown on the project github page.

    However, the LEDs don't light up in anyway and the board is not detectable by various scanner BLE scanner apps (including mine)

    The peripheral_audio_over_ble project is very similar to simple_peripheral project, yet the first one fails to be detected. I've checked the code and not sure why it doesn't work out for me.

    Is it because I don't have the extra daughterboard with AUX in for headphone/microphone set? So, the board in its current setup is not able to communicate with another board with ADC or AUX socket.

    However, I do see this on CCS UART terminal (i.e. @ COM8 I open a serial port):

    Audio Tx Peripheral with DLE
    0xB1..... (some UUID her)
    Initialized
    Advertising

    So, my question is, why does it say advertising and yet it is not scannable? Why are the LEDs not working?
  • Hi Okan,

    After looking through the example code, it appears that the LEDs are only setup to run with the central audio example and not the peripheral version. If you use the central example, they will light up.

    As I said in my previous post, these examples won't run exactly the same as your example but you can still see how they handle sending large amounts of data. In the bidirectional audio examples, the central device is set up to automatically connect to the audio peripheral based on the peripheral's advertisement data. The peripheral device uses limited discoverable mode and may not be picked up by other scanners. These examples were designed to run together and not as stand alone examples which is why the peripheral project is behaving like that.

    Let me know if you have any more questions.

    Regards,

    Jessica

    Please click the "This Resolved My Issue" button on this post if it answers your question

  • Hi Jessica,

    Thanks for the help, your answers are clear and concise enough for me. I may have additional questions in the future but it's better I ask them separately.

    Thanks

    - Okan