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.

CCS/CC1352P: Issue with CC1352 UART Data Reception from MSP430

Prodigy 100 points

Replies: 1

Views: 33

Part Number: CC1352P

Tool/software: Code Composer Studio

Hi,

I am using CC1352 uart interface to read electrical parameters from MSP430-i2040 chip.

The data communication is fine but I am facing a peculiar issue. When I directly print data from MSP430-i2040 on to my CC1352 debug port I get the following data as below, 

55 AA 0A 04 80 01 01 17 00 00 00 9D 00
55 AA 0A 04 81 01 01 82 2F 00 00 38 01
55 AA 0A 04 82 01 01 20 00 00 00 A8 00
55 AA 0A 04 83 01 01 2F 43 00 00 FB 00
55 AA 0A 04 84 01 01 CA 02 00 00 56 01
55 AA 08 04 85 01 01 00 00 8B 00
55 AA 0E 04 86 01 01 04 00 00 00 00 00 00 00 90 00
55 AA 0E 04 87 01 01 C8 FF FF FF FF 4E 08
55 AA 0E 04 88 01 01 38 00 00 00 00 00 00 00 C6 00
55 AA 0E 04 89 01 01 3B 02 00 00 00 00 00 00 CC 00
55 AA 0E 04 8A 01 01 BF 01 00 00 00 00 00 00 50 01
55 AA 0E 04 8B 01 01 DA 02 00 00 00 00 00 00 6D 01

But when I connect MSP TX to CC1352 RX and read data in my code, the data is getting truncated, I am receiving up to 5th line of above data that is up to 84 and after that  instead of getting the 86, its starting again with 80, that is the 1st packet like below,

55 AA 0A 04 80 01 01 17 00 00 00 9D 00 
55 AA 0A 04 81 01 01 82 2F 00 00 38 01 
55 AA 0A 04 82 01 01 20 00 00 00 A8 00 
55 AA 0A 04 83 01 01 2F 43 00 00 FB 00 
55 AA 0A 04 84 01 01 CA 02 00 00 56 01 

55 AA 0A 04 80 01 01 17 00 00 00 9D 00 
55 AA 0A 04 81 01 01 82 2F 00 00 38 01 
55 AA 0A 04 82 01 01 20 00 00 00 A8 00 
55 AA 0A 04 83 01 01 2F 43 00 00 FB 00 
55 AA 0A 04 84 01 01 CA 02 00 00 56 01 

Please let me know why it works fine when I directly print MSP TX data and why it does not when I read in my code in CC1352P2.

Below in my CC1352 UART configuration,

.readMode = UART_MODE_BLOCKING,
.writeMode = UART_MODE_BLOCKING,
.readTimeout = UART_WAIT_FOREVER,
.writeTimeout = UART_WAIT_FOREVER,
.readCallback = NULL,
.writeCallback = NULL,
.readReturnMode = UART_RETURN_FULL,
.readDataMode = UART_DATA_TEXT,
.writeDataMode = UART_DATA_BINARY,
.readEcho = UART_ECHO_OFF,
.baudRate = 115200,
.dataLength = UART_LEN_8,
.stopBits = UART_STOP_ONE,
.parityType = UART_PAR_NONE

Regards,

Praveen TV

 

1 Reply

  • Hi Praveen,

    Can you please share your CC1352P initialization and how you are processing the incoming UART data on the CC1352P?  Default UART values are provided below and I further recommend that you read through the comments in UART.h: https://software-dl.ti.com/dsps/dsps_public_sw/sdo_sb/targetcontent/tirtos/2_21_01_08/exports/tirtos_full_2_21_01_08/products/tidrivers_cc13xx_cc26xx_2_21_01_01/docs/doxygen/html/_u_a_r_t_8h.html 

     *  Defaults values are:
     *      readMode = UART_MODE_BLOCKING;
     *      writeMode = UART_MODE_BLOCKING;
     *      readTimeout = UART_WAIT_FOREVER;
     *      writeTimeout = UART_WAIT_FOREVER;
     *      readCallback = NULL;
     *      writeCallback = NULL;
     *      readReturnMode = UART_RETURN_NEWLINE;
     *      readDataMode = UART_DATA_TEXT;
     *      writeDataMode = UART_DATA_TEXT;
     *      readEcho = UART_ECHO_ON;
     *      baudRate = 115200;
     *      dataLength = UART_LEN_8;
     *      stopBits = UART_STOP_ONE;
     *      parityType = UART_PAR_NONE;

    Regards,
    Ryan

    To better aid the community, please click on the "This Resolved my issue" button whenever a post answers your question!

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.