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-CC2650: CC2650

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

Tool/software: TI-RTOS

Hi all,

I try to make an application where a cc2650 and a MCU talk together by UART with CCS 6.1.1.

The goal is to give a bluetooth intruction to the cc2650 with a phone, then the cc2650 send this instruction to the MCU by UART, and the MCU give an answer to the cc2650 by UART.

the problem is the answer from the MCU to the cc2650. In fact, the answer is detected but not read.

code below:

void receiveUART(){
	int ret;
	ret = UART_read(hUart, UART_rxBuf, DS_STREAM_LEN);
	printf("The UART read %d bytes\n", ret); //after some tests, ret = 0
	_nop(); //empty instruction (to make test)
}


UART_Params* UART_Init(){
    UART_Params_init(&paramsUart);

    paramsUart.readMode = UART_MODE_CALLBACK;
    paramsUart.readCallback = readCallback;
    paramsUart.readEcho = UART_ECHO_OFF;
    paramsUart.readDataMode = UART_DATA_BINARY;
    paramsUart.baudRate  = 115200;
    paramsUart.readReturnMode = UART_RETURN_FULL;
    hUart = UART_open(Board_UART, &paramsUart);
    if (!hUart){
    	printf("UART did not open");
    }
    return &paramsUart;
}

after some tests, I can say that I go into the receiveUART function(), that all initialization are good (I think but I'm maybe wrong) and I don't think that this is an electronical problem.

This application belongs to a company, so i can't give you all the sources.

Thanks.

  • sorry, I made a mistake, it's cc2640 5x5, not 2650.
  • Hi,

    You can probably reuse SPP BLE server/client project:
    github.com/.../spp_ble.md

    which already has bidirectional UART setup to connect your MCU.

    Best wishes
  • Hi Zahid,
    thank for your reply.

    I try to import the SPP BLE server/client project in my worspace, but on almost all the .c and .h file, I have this error when I try to read them :
    "Error retrieving content description for resource ' /resource.c '."

    I have seen in another forum that I need to copy/paste the project to avoiod this error, but when I try this, I have another error :
    "Problems encountered while copying resources.
    Resource '/path/resource.c' does not exist."

    When I check the path of resources that got a copy problem, I see that the resolved location doesn't exist, but I don't understand why and what can I do...

    I know that's another problem, but maybe you have some suggestion?

    Regards,
    Lucas