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.

IWR6843: Wiring & circuit modification for UART communication between mmWave IWR6843 and CC3235

Part Number: IWR6843
Other Parts Discussed in Thread: TIDA-010022, MMWAVEICBOOST, , CC3235S, SYSCONFIG, AWR1843BOOST

I looked at document TIDA-010022 from TI, but there's no source code of it. After reading, I wanna ask:

1. wifi module in that document is CC1352. In order to communicate between IWR6843 & CC1352 via UART, both modules must modify some parts. Do I need to modify in case I connect IWR6843 & CC3235 via UART? If yes, which part do I need to add/remove? In the document, it mentions MMWAVEICBOOST needs to add R81, R122 but doesn't say which value of resistor I need to use. Please tell me in details in case I use CC3235.

2. on CC1352, it must remove SMA connector before connecting to IWR6843. How about CC3235?

3. on CC1352, it must removethe following jumpers: "5V", "3V3", "RXD", and "TXD" and switch the XDS110 power jumper to "Extern" Power. On CC3235, I don't see 3V3 jumper. Is it VBAT or BRD jumper? Do I have to remove both VBAT & BRD jumper?

4. How to switch XDS110  to Extern Power?

5. Which pins do I need to connect for UART communication? As I understand, connect P1.3 on CC3235 to pin 5 of J5 connector and connect P1.4 on CC3235 to pin 7 of J5 connector  on MMWAVEICBOOST, right?

6. As in the photo below, please explain the difference between UART (data port ) and UART (CLI port). As I know, IWR6843 MMWAVEBOOST EVM and CC3235 only have 1 USB port. How can they communicate via 2 separate UART port?

In short, please give me instruction with schematic diagram for wiring between IWR6843 & CC3235 via UART, resistor value for hardware modification on 2 modules, ect...

  • Dear Hector:

    At a high level you will need to use the 40 pin headers that are underneath the MMWAVEICBOOST to the CC3235 LP for both UART RX/TX. Do this you will need to do the following:

    -To find the right schematic you will need to know the name of the antenna module that you are using: ISK, ODS, or AOP

    1. Understand using the MMWAVEICBOOST/IWR6843 schematic and MMWAVEICBOOST user's guide how the UART signals go from the 40 pin connector(which will connect to the CC3235) to the 60 pin connector(which connects to the IWR6843) as well as what are the RX/TX pin numbers/mux settings that connect to the CC3235 and IWR6843 chips respectively.

    2. Make a modification to mss_main.c such that when you send data over MSS LOGGER signal (refer to schematic) that you send nothing from the Data Processing Chain from the radar, but instead send something simple like: "Hello World" and have modified software on the CC3235 end that can read that "Hello World" for verification.

    3. These steps are high level and should not be treated as step by step instructions there will be aspects to this that you will have to figure out on your own especially for the CC3235. Frame you strategy in a way where you do the simplest foundational step that you can and get that to work then step by step move closer to your end goal.

    Best regards,

    Connor Desmond

  • Hi Connor,

    1. I'm using IWR68-ISK attach to MMWAVEICBOOST.

    2. Here's my CC3235S pin settings on SysConfig. So I must use P62 as TX and P45 as RX for UART communication to IWR6843 MMWAVEICBOOST, right? Previously, I thought I need to use P04 and P03 for UART.

    3. In SimpleLink SDK, I don't see main_mss.c program. There're 2 types free-RTOS, TI-RTOS. . Which type should I choose as a base project? Besides, in each type has CCS, GCC folder. After flashing, which bin file (ccs or gcc) should I flash on device?

    4. On MMWAVEICBOOST, document says I need to add R122, but I can't find location of R122. Where's it and which value of resistance needed?

    5. I don't get your point of "UART signals go from the 40 pin connector(which will connect to the CC3235) to the 60 pin connector(which connects to the IWR6843) ".

    -> 40-pin connector is on CC3235. How can 40-pin connector connect to CC3235 when it's already on CC3235?

    Do u mean I need to modify jumper and something to enable UART TX/RX on CC3235 and MMWAVEICBOOST connect together?

    6. Do i really need to modify circuit on 2 modules for communication via UART? Will damage happen if I don't modify circuit?

    How about modification requirement for SPI communication?

  • Dear Hector,

    Anything that is specific to the CC3235 is better to be directed to a forum which supports those devices. I will help you specifically with regards to the IWR6843. On the underside of the MMWAVEICBOOST there is a 40 pin connector that is designed to be placed directly on top of a TI Launch pad e.g. the launchpad that you have for your CC3235 device. Now it is not guaranteed that the TX/RX pins will line up even if physically it can fit. This is where you need to verify that it does or does not fit using the provided schematics. Then using the schematic for the MMWAVEICBOOST find the RX/TX connections and follow those connections all the way back to the 60 pin connector where the antenna module fits on top of. It is the 60 pin connector which has the signals that will eventually make their way to your CC3235. Do this and let me know the results.

    Could you please link the document that you referenced in point 4 which refers to the resistor modification.

    Just so you know I am talking about the HW on the ICBOOST+ISK, not the HW on the CC3235.

    Best regards,

    Connor Desmond

  • Hi Connor,

    In TIDA-010022 document, we must use 2 UART ports for configuration and radar data output. Do I need to declare both UART ports on CC3235? RS232_RX and RS232_TX are UART1, right? 

    Do I need to use UART1 for configuration and UART0_Tx for data output?

    All pins are not fixed but can be customized by pins settings on SysConfig, so we shouldn't do wiring based on the schematics below, right?

    Please tell me how to do UART pins wiring for configuration and radar data output based on pins settings below.

    Here's the document I refer http://www.ti.com/lit/ug/tidue71d/tidue71d.pdf?ts=1590999826113

  • Dear Hector:

    This a question that I would post in the CC3235 forum. Do you have any questions related to the IWR6843 and the steps that I given you to try?

    Best regards,

    Connor Desmond

  • Dear Connor,

    1. How to enable MSS_Logger pin on MMWAVEICBOOST to send data? I see it's in pin 9 of J6 connector. But not sure which pinmux settings code can I write for it. I think MSS_LOGGER is UART-3 when we do pinmux settings (corresponds MSS_UARTB_TX in datasheet, right? On some module such as AWR1843BOOST, MSS_Logger is not connected but has to be enabled by soldering a resistor to the circuit. How about IWR6843-ISK?

    Here's my draft code for Mss_logger write data from IWR6843

    /* Setup the PINMUX to bring out the MSS UART-3 */
        Pinmux_Set_OverrideCtrl(SOC_XWR68XX_PINF14_PADAJ, PINMUX_OUTEN_RETAIN_HW_CTRL, PINMUX_INPEN_RETAIN_HW_CTRL);
        Pinmux_Set_FuncSel(SOC_XWR68XX_PINF14_PADAJ, SOC_XWR68XX_PINF14_PADAJ_MSS_UARTB_TX);
    
    
        UART_writePolling(handle, ptrTestBanner, strlen((const char*)ptrTestBanner));
        for (index = 0; index < 64; index++)
        {
            /* Write out the character: */
            status = UART_writePolling(handle, &txData, 1);
            if (status < 0)
            {
                System_printf("Error: Unable to send out the data [%d] on UART-3 [Error %d]\n", index, status);
                return -1;
            }
    
            /* Next iteration; next character */
            if (txData == 'Z')
            {
                txData = 'A';
            }
            else
            {
                txData++;
            }
        }
        System_printf ("Debug: Write to the UART-3 was successful. Please verify the Console application.\n");
        UART_close (handle);

    2. RS232 TX/RX pins (pin 5 and pin 7 on J5 connector MMWAVEICBOOST) needs to be connected to RS232 RX/TX pins on CC3235 for transferring configuration, right? What if I send Cfg directly from PC to IWR6843 at boot-up time? In that case do I still need to use RS232 RX/TX pins to connect these 2 modules?

    3. If I want to connect IWR6843BOOST to CC3235 via RS232 TX/RX pins for configuration, do I need to add some resistors on MMWAVEICBOOST? If yes, which resistor?

    4. You said I need to send data from IWR6843 to CC3235 via MSS_logger pin. As I see, MSS_logger pin is for UART function. If I use SPI or I2C, I guess I can't use MSS_Logger pin in that case, so which pin do I need to use to send data to CC3235?

    5. Please tell me how to debug SimpleLink device (CC3235) on CCS Debug mode. I can do it with mmWave devices by xer4f file. But SimpleLink device doesn't have xer4f. So I don't know how to do.

  • Hector,

    MSS_Logger signal is connected to pin 9 of the 40 pin connector and has the 0 ohm resistor in place. From my current understanding there should be no HW changes to the EVM to get out the data through UART. Follow the settings that found in page 11 in the MMWAVEICBOOST User's Guide to change the switch settings such that the MSS_Logger is rerouted to the 40 pin connector underneath the MMWAVEICBOOST EVM. Try this out. Concurrently, also use Tera-Term or PuTTY to verify that you can recieve UART data on the CC3235 end. If you do that and it works you will know that the issue(if there is one) is on the side of the IWR6843 and will speed up the debugging process. This should be enough information for you to get the UART signals out of MMWAVEICBOOST. I am closing this thread.

    Best regards,

    Connor Desmond

  • Hi Connor,

    1. Pins position on header of MMWAVEICBOOST & CC3235S wifi module are fixed no matter how we set pinmux, right?e.g. I can set F14, H14 or any ball number in the table below for Mss_Logger signal, but we still connect to Mss_logger at pin 9 on J6 connector MMWAVEICBOOST, right?

    2. As I know, UART wiring only need to connect 

    CC3235    IWR6843

    TX               RX

    RX               TX

    GND            GND

    But a document says I also need to connect CTS & RTS pins. Please confirm whether it's needed.

  • Hector,

    There is only pinmuxing done with regards to pins of a chip e.g. IWR6843. The pins on the J6 header are fixed. With regards to using CTS and RTS this signals ares used for flow control, and some applications require them. I would try with and without them in your application.

    Best regards,

    Connor Desmond

  • Connor,

    So IWR6843 header pin is different from CC3235S. Regarding CC3235S, we must choose pins on header for wiring based on Sysconfig pins settings, but IWR6843 header pins are always fixed.

    How about the case I want to send radar data from IWR6843 to CC3235S via SPI? Which pin do I need to use for sending data  from IWR6843? I think those pins are: pin 2,6,12,14 on J6 and pin 13 on J5 of MMWAVEICBOOST connect to corresponding pins on CC3235S, right?

    Do I still need to use UART pins for sending configuration from CC3235S to IWR6843 in that case?

  • Hector:

    1. So IWR6843 header pin is different from CC3235S. Regarding CC3235S, we must choose pins on header for wiring based on Sysconfig pins settings, but IWR6843 header pins are always fixed.

    [CD]>> If the switch settings on the MMWAVEICBOOST are set such that the UART signals are rerouted to the 40 pins headers then the signals should be there. Where the signals are on the 40 pin header are fixed. As I mentioned before we do not support CC3235 devices so it is possible that the CC3235 LP that I assume you are using may not match up perfectly. You may need to use jumper cables to prototype.

    2. How about the case I want to send radar data from IWR6843 to CC3235S via SPI? Which pin do I need to use for sending data  from IWR6843? I think those pins are: pin 2,6,12,14 on J6 and pin 13 on J5 of MMWAVEICBOOST connect to corresponding pins on CC3235S, right?

    [CD]>> This question has already been posted in the following thread:

    e2e.ti.com/.../3348072

    3. Do I still need to use UART pins for sending configuration from CC3235S to IWR6843 in that case?

    [CD]>>The Out of Box demo and the EVM's that we provide use UART for configuration. With that being said there are other peripherals which could be used, but that would require you to modify existing code and debug on your own. I would suggest getting your system up and running with UART first since there is reference code that already works.

    Best regards,

    Connor Desmond

  • Connor,

    I have a question about UART FIFO flush after received data from IWR6843 in this thread. Please help me this issue: (4) CC3235S: UARTCC32XX.h FIFO flush (TIDA-010022 reference) - Wi-Fi forum - Wi-Fi - TI E2E support forums

  • Connor,

    About UART read from IWR6843 to CC3235, I connected UART0 & UART1 of IWR6843 to CC3235. I sent Cfg directly from PC to IWR6843, then pin MSS_Logger connects to UART1_RX of CC3235. But when I used Teraterm, I saw no data on UART data port of CC3235 even though I saw point cloud on IWR6843. If I send Cfg to IWR6843 directly from PC, do I need to modify the code of CC3235 sensor node to not send Configuration parameters?

    As I see, in order to transfer data via boosterpack header, we must set J9 jumper to bottom side. So how can you check whether CC3235 can receive data from IWR6843 correctly via Teraterm in case we can't set J9 jumper on CC3235 for COM port and boosterpack at once?

    I tried to connect 3 pins of RX J9 jumper on CC3235S to transfer data and check data received from MSS_LOGGER pin IWR6843. LED D7 lights green, but Teraterm still shows nothing on data port of CC3235S. What may cause this issue?

  • Hector,

    1. About UART read from IWR6843 to CC3235, I connected UART0 & UART1 of IWR6843 to CC3235. I sent Cfg directly from PC to IWR6843, then pin MSS_Logger connects to UART1_RX of CC3235. But when I used Teraterm, I saw no data on UART data port of CC3235 even though I saw point cloud on IWR6843. If I send Cfg to IWR6843 directly from PC, do I need to modify the code of CC3235 sensor node to not send Configuration parameters?

    [CD]>>Did you change the switch settings on the MMWAVEICEBOOTST. If you did then the connection to the PC will no longer be there. If you didn't the UART will not go to the 40 pin header.

  • Connor,

    I set switch settings on the MMWAVEICEBOOTST as column 3. Currently, I can still send Cfg from PC to IWR6843 via XDS110 USB port. But the switch settings below should be able to let Mss_Logger pin sends data to CC3235, I don't know why there's no data received on CC3235.

  • Hector,

    I will get back to you in a couple of days I need to verify some information pertaining to your issue.

    BR,

    Connor Desmond

  • Thanks Connor,

    Here's more details:

    The pins settings of UART0, UART1 set by SysConfig and wiring for CC3235S is as follows:

    UART0 pins settings (send Configuration from CC3235 to IWR6843)

    .rxPin              = UART2CC32XX_PIN_57_UART0_RX,  
    .txPin              = UART2CC32XX_PIN_55_UART0_TX,

    UART1 pins settings (to receive radar data from MSS_LOGGER pin of IWR6843 EVM)
    .rxPin              = UARTCC32XX_PIN_02_UART1_RX,  
    .txPin              = UARTCC32XX_PIN_UNASSIGNED,

    CC3235S(boosterpack header)        IWR6843 MMWAVEICBOOST

      GND                                                    GND

      P57                                                     TX (pin 5 on J5)

      P55                                                     RX (pin 7 on J5)

      P45                                                     MSS_LOGGER (pin 9 on J6)

    wiring position on Boosterpack header CC3235S

    I set J9 jumper to bottom side. So CC3235S UART is routed to boosterpack header to connect to TX/RX and Mss_logger pins on ICBOOST

  • Dear Hector,

    1. If you have the settings correct for the MMWAVEICBOOST then you will be able to get the MSS_LOGGER signal out of the 40 PIN connector. I have personally tested this and verified.

    2. If you want to get configuration TX/RX through the 40 PIN connector you have to change the S1.5 to the OFF position, but keep the other switches the same according to the MMWAVEICBOOST's user guide.

    With these steps assuming that your board is fully functional, you will be able to connect them to an external device. With regards to the process for making that work is beyond the scope of this forum and would be better directed towards the forum of that device e.g. CC3235.

    Best regards,

    Connor Desmond

  • Hi Connor,

    I used oscilloscope to check signal on both Mss_logger pin and pin 45 (UART1_RX on CC3235). Mss_logger voltage is always at high level (about 33~35V). It means radar hasn't been initialized (hasn't received Cfg settings) successfully. Please tell me how to solve it. Here's the code I used to send Cfg from CC3235S to IWR6843 and to receive data from Mss_logger pin. After that, I put mmwaveTaskInit(); in main_tirtos.c of CC3235S project. And the result is 6843 uninitialized as mentioned above.

    Note: I set switch S1.1~S1.12 to enable 40-pin connector on MMWAVEICBOOST, and I flashed demo code for IWR6843

    //#define DEBUG_PRINT
    #define MMWAVE_SENSOR 1
    
    #define MMWAVE_TASK_STACK_SIZE     1024
    #define MMWAVE_TASK_PRIORITY       1
    
    #define MMWAVE_COMMAND_DELAY    1000000     //  1 seconds
    #define MMWAVE_START_DELAY      20000000    //  20 seconds
    
    Task_Struct mmwaveTask;
    Char mmwaveTaskStack[MMWAVE_TASK_STACK_SIZE];
    
    Semaphore_Handle mmwaveSemHandle;
    Semaphore_Struct mmwaveSemStruct;
    
    UART_Handle mmwaveUartHandle;
    UART_Params mmwaveUartParams;
    UART_Handle mmwaveLoggerUartHandle;
    UART_Params mmwaveLoggerUartParams;
    
    uint8_t currentInterval = 0;
    volatile uint8_t sensor_connected = 0;
    
    Smsgs_mmwaveSensorField_t latestMmwaveData;
    
    
    // Updated command list for IWR6843 (60Hz)
    const char *CommandList[] = {"dfeDataOutputMode 1\r",
                        "channelCfg 15 5 0\r",
                        "adcCfg 2 1\r",
                        "adcbufCfg 0 1 1 1\r",
                        "profileCfg 0 60.6 30 10 62 0 0 53 1 128 2500 0 0 30\r",
                        "chirpCfg 0 0 0 0 0 0 0 1\r",
                        "chirpCfg 1 1 0 0 0 0 0 4\r",
                        "frameCfg 0 1 128 0 50 1 0\r",
                        "lowPower 0 1\r",
                        "guiMonitor 1 1 0 0\r",
                        "cfarCfg 6 4 4 4 4 16 16 4 4 50 62 0\r",
                        "doaCfg 600 1875 30 1 1 0\r",
                        "SceneryParam -6 6 0.5 6\r",
                        "GatingParam 4 3 2 0\r",
                        "StateParam 10 5 100 100 5\r",
                        "AllocationParam 250 250 0.25 10 1 2\r",
                        "AccelerationParam 1 1 1\r",
                        "PointCloudEn 0\r",
                        "trackingCfg 1 2 250 20 52 82 50 90\r",
                        "sensorStart\r"
    };
    
    void mmwaveTaskInit(void)
    {
        /* Construct Semaphore */
        Semaphore_Params semParams;
        Semaphore_Params_init(&semParams);
        Semaphore_construct(&mmwaveSemStruct, 0, &semParams);
        mmwaveSemHandle = Semaphore_handle(&mmwaveSemStruct);
    
        /* Configure display task. */
        Task_Params taskParams;
        Task_Params_init(&taskParams);
        taskParams.stack = mmwaveTaskStack;
        taskParams.stackSize = MMWAVE_TASK_STACK_SIZE;
        taskParams.priority = MMWAVE_TASK_PRIORITY;
        Task_construct(&mmwaveTask, mmwaveTaskFxn, &taskParams, NULL);
    
        UART_init();
    
        /* Open mmwave configuration UART port */
        UART_Params_init(&mmwaveUartParams);
        mmwaveUartParams.writeDataMode = UART_DATA_BINARY;
        mmwaveUartParams.readDataMode = UART_DATA_BINARY;
        mmwaveUartParams.readReturnMode = UART_RETURN_FULL;
        mmwaveUartParams.readEcho = UART_ECHO_OFF;
        mmwaveUartParams.baudRate = 115200;  //Configuration baud rate
        mmwaveUartParams.readTimeout = 500000 / Clock_tickPeriod;
    
        //mmwaveUartHandle = UART_open(Board_UART0, &mmwaveUartParams);
        mmwaveUartHandle = UART_open(CONFIG_UART_0, &mmwaveUartParams);
        if (mmwaveUartHandle == NULL) {
            /* UART_open() failed */
            while (1);
        }
    
        /* Open mmwave logger UART port */
        UART_Params_init(&mmwaveLoggerUartParams);
        mmwaveLoggerUartParams.writeDataMode = UART_DATA_BINARY;
        mmwaveLoggerUartParams.readDataMode = UART_DATA_BINARY;
        mmwaveLoggerUartParams.readReturnMode = UART_RETURN_FULL;
        mmwaveLoggerUartParams.readEcho = UART_ECHO_OFF;
        mmwaveLoggerUartParams.baudRate = 921600;  //Configuration baud rate
        mmwaveLoggerUartParams.readTimeout = 500000 / Clock_tickPeriod;
    
        //mmwaveLoggerUartHandle = UART_open(Board_UART1, &mmwaveLoggerUartParams);
        mmwaveLoggerUartHandle = UART_open(CONFIG_UART2_0, &mmwaveLoggerUartParams);
    
        if (mmwaveLoggerUartHandle == NULL) {
            /* UART_open() failed */
            while (1);
        }
    }
    
    void mmWave_init(void)
    {
        int command_index;
        int byte_index;
        int retries;
        char input[4];
        char dump;
        int CommandLength;
    
        //UART_control(mmwaveUartHandle, UARTCC32XX_CMD_RX_FIFO_FLUSH, 0);
    
        //parse all the commands in the config files
        for (command_index = 0; command_index<sizeof(CommandList)/sizeof(CommandList[0]); command_index++)
        {
    
    #if 0
            // Send command to mmwave
            UART_write(mmwaveUartHandle, CommandList[command_index], strlen(CommandList[command_index]));
    
            // Wait before sending next command
            Task_sleep(MMWAVE_COMMAND_DELAY / Clock_tickPeriod);
    
    #else
            //parse each command for 5 times if it parses the wrong command.
            //successful write UART: dfeDataOutputMode 1\r
            //successful read UART: dfeDataOutputMode 1\r\nDone\r\n
    
            for (retries=0; retries<5; retries++)
            {
                CommandLength = strlen(CommandList[command_index]);
                for (byte_index=0; byte_index<CommandLength; byte_index++)
                {
                    //each command is parsed a byte per time
                    //read a byte per time and store into array called "dump"
                    UART_write(mmwaveUartHandle, &CommandList[command_index][byte_index], 1);
                    UART_read(mmwaveUartHandle, &dump, 1);
                }
                //take care of additional byte "\n"
                UART_read(mmwaveUartHandle, &dump, 1);
    
                //read next 4 bytes and store it into array called "input"
                UART_read(mmwaveUartHandle, input, 4);
    
                //keep reading until reaches the last byte ">"
                while (dump!= '>')
                {
                    UART_read(mmwaveUartHandle, &dump, 1);
                }
    
                //if array "input" is equal to "Done", which means it receives the right command
                if (input[0]=='D' && input[1]=='o' && input[2]=='n' && input[3]== 'e')
                {
                    break;
                }
            }
    #endif
        }
    }
    
    /*!
     * @brief       Main task function
     *
     * @param       a0 -
     * @param       a1 -
     */
    #define EMPTY_TEST
    
    Void mmwaveTaskFxn(UArg a0, UArg a1)
    {
        // Wait for the mmWave to power on before initializing the mmWave
        Task_sleep(MMWAVE_START_DELAY / Clock_tickPeriod);
    
        // Wait for the sensor to be connected to the collector
        while(!sensor_connected);
    
        // Initialize and start the mmWave
        mmWave_init();
    
        //UART_control(mmwaveLoggerUartHandle, UARTCC32XX_CMD_RX_FIFO_FLUSH, 0);
    
    #ifdef MMWAVE_SENSOR
        while(1)
        {
            /* Get mmWave value */
            uint8_t status = readmmwave(&mmwaveSensor);
    
            switch(status)
            {
                case MMWAVE_STATUS_SUCCESS:
                    #ifdef DEBUG_PRINT
                    UART_write(mmwaveLoggerUartHandle, "S", 1);
                    #endif
                    //Util_setEvent(&Sensor_events, SENSOR_MMWAVE_EVT);
                    //Ssf_PostAppSem();
                    break;
                case MMWAVE_STATUS_INVALID_SYNC:
                    #ifdef DEBUG_PRINT
                    UART_write(mmwaveLoggerUartHandle, "!SYNC\n\r", 7);
                    #endif
                    break;
                case MMWAVE_STATUS_TLV_TOO_LONG:
                    #ifdef DEBUG_PRINT
                    UART_write(mmwaveLoggerUartHandle, "TLV>PKT\n\r", 9);
                    #endif
                    break;
                case MMWAVE_STATUS_PKT_TOO_LONG:
                    #ifdef DEBUG_PRINT
                    UART_write(mmwaveLoggerUartHandle, "PKT!=CNT\n\r", 10);
                    #endif
                    break;
                case MMWAVE_STATUS_INVALID_TLV:
                    #ifdef DEBUG_PRINT
                    UART_write(mmwaveLoggerUartHandle, "!TLV\n\r", 6);
                    #endif
                    break;
            }
    
        }
    #endif
    }
    
    Smsgs_mmwaveSensorField_t mmwaveSensor =
        { 0 };
    
    uint8_t readmmwave(Smsgs_mmwaveSensorField_t* mmWaveData)
    {
        mmWaveDataUART_t mmWaveUart;
        char input = 0x0;
        char pBuf[250];
        uint32_t i = 0;
        uint32_t count = 0;
        uint32_t len_cnt = 0;
        uint32_t len_pkt = 0;
    
        uint32_t num_tlv = 0;
        uint32_t tlv_index = 0;
        uint32_t tlv_type = 0;
        uint32_t tlv_length = 0;
    
        uint32_t obj_index = 0;
        uint32_t num_obj = 0;
    
        // SYNC WORD: 02 01 04 03 06 05 08 07
        // Wait for start of sync word
        while(input != 0x02)
        {
            UART_read(mmwaveLoggerUartHandle, &input, 1);
        }
    
        // Verify that next 7 bytes are the correct sync pattern
        len_cnt = 1;
        count = 0;
        while(count < 7)
        {
            len_cnt += UART_read(mmwaveLoggerUartHandle, &input, 1);
            switch(count)
            {
                case 0: if(input == 0x01) count++; else return MMWAVE_STATUS_INVALID_SYNC; break;
                case 1: if(input == 0x04) count++; else return MMWAVE_STATUS_INVALID_SYNC; break;
                case 2: if(input == 0x03) count++; else return MMWAVE_STATUS_INVALID_SYNC; break;
                case 3: if(input == 0x06) count++; else return MMWAVE_STATUS_INVALID_SYNC; break;
                case 4: if(input == 0x05) count++; else return MMWAVE_STATUS_INVALID_SYNC; break;
                case 5: if(input == 0x08) count++; else return MMWAVE_STATUS_INVALID_SYNC; break;
                case 6: if(input == 0x07) count++; else return MMWAVE_STATUS_INVALID_SYNC; break;
            }
        }
    
        #ifdef DEBUG_PRINT
        UART_write(mmwaveLoggerUartHandle, "$", 1);
        #endif
    
        // Read remaining frame header
        len_cnt += UART_read(mmwaveLoggerUartHandle, pBuf, 44);
        len_pkt = ((uint32_t)((pBuf[12]) & 0x00FF) +
                  ((uint32_t)((pBuf[13]) & 0x00FF) << 8) +
                  ((uint32_t)((pBuf[14]) & 0x00FF) << 16) +
                  ((uint32_t)((pBuf[15]) & 0x00FF) << 24));
    
        mmWaveData->frame_number = ((uint32_t)((pBuf[16]) & 0x00FF) +
                ((uint32_t)((pBuf[17]) & 0x00FF) << 8) +
                ((uint32_t)((pBuf[18]) & 0x00FF) << 16) +
                ((uint32_t)((pBuf[19]) & 0x00FF) << 24));
    
        num_tlv = (pBuf[40] & 0x00FF) + ((pBuf[41] & 0x00FF) << 8);
    
    
        // Process each TLV structure
        for(tlv_index=0; tlv_index<num_tlv; tlv_index++)
        {
            // Read TLV header
            len_cnt += UART_read(mmwaveLoggerUartHandle, pBuf, 8);
    
            // TLV type
            tlv_type =  ((uint32_t)((pBuf[0]) & 0x00FF) +
                        ((uint32_t)((pBuf[1]) & 0x00FF) << 8) +
                        ((uint32_t)((pBuf[2]) & 0x00FF) << 16) +
                        ((uint32_t)((pBuf[3]) & 0x00FF) << 24));
    
            // TLV length
            tlv_length =((uint32_t)((pBuf[4]) & 0x00FF) +
                        ((uint32_t)((pBuf[5]) & 0x00FF) << 8) +
                        ((uint32_t)((pBuf[6]) & 0x00FF) << 16) +
                        ((uint32_t)((pBuf[7]) & 0x00FF) << 24));
    
            if(tlv_length > len_pkt){
                return MMWAVE_STATUS_TLV_TOO_LONG;
            }
    
            switch(tlv_type)
            {
                case 0x07:
    
                    // Save length for offline processing. Do not want to slow down
                    // reading the UART stream by calculating the number of objects
                    tlv_length = tlv_length - 8;
                    num_obj = tlv_length;
                    obj_index = 0;
    
                    while(tlv_length > 0)
                    {
                        //Board_Led_toggle(board_led_type_LED1);
    
                        // Save first 10 object information
                        if(obj_index < SMSGS_SENSOR_MMWAVE_MAX_OBJ)
                        {
                            // Save object information (tid, posx, posy)
                            len_cnt += UART_read(mmwaveLoggerUartHandle, mmWaveUart.objInfo[obj_index].info, 12);
                            // Discard unneeded information
                            len_cnt += UART_read(mmwaveLoggerUartHandle, pBuf, 56);
                        }
                        else
                        {
                            // Already read max number of objects. Read the remaining objects and discard
                            len_cnt += UART_read(mmwaveLoggerUartHandle, pBuf, 68);
                        }
                        // Increase number of objects saved
                        obj_index++;
                        // Decrement length counter to see if there are any additional data to be processed
                        tlv_length = tlv_length - 68;
                    }
    
                    #ifdef DEBUG_PRINT
                    UART_write(mmwaveLoggerUartHandle, "&", 1);
                    #endif
    
                    break;
    
                case 0x06:
                    tlv_length = tlv_length - 8;
                    while(tlv_length > 0){
                        len_cnt += UART_read(mmwaveLoggerUartHandle, pBuf, 16);
                        tlv_length = tlv_length - 16;
                    }
    
                    #ifdef DEBUG_PRINT
                    UART_write(mmwaveLoggerUartHandle, "^", 1);
                    #endif
                    break;
                case 0x08:
                    tlv_length = tlv_length - 8;
                    len_cnt += UART_read(mmwaveLoggerUartHandle, pBuf, tlv_length);
                    #ifdef DEBUG_PRINT
                    UART_write(mmwaveLoggerUartHandle, "*", 1);
                    #endif
                    break;
                default:
                    return MMWAVE_STATUS_INVALID_TLV;
            }
        }
    
    
        // POST PROCESSING
    
        // Only continue processing if full frame was received
        if(len_cnt != len_pkt)
            return MMWAVE_STATUS_PKT_TOO_LONG;
    
        // Number of objects
        mmWaveData->num_objs = num_obj / 68;
        // Object information
        for(i=0; i<SMSGS_SENSOR_MMWAVE_MAX_OBJ; i++)
        {
            // Only calculate if there's valid data in the array
            if(i < mmWaveData->num_objs)
            {
                mmWaveData->objInfo[i].tid  = Util_buildUint32(mmWaveUart.objInfo[i].info[0],
                                                               mmWaveUart.objInfo[i].info[1],
                                                               mmWaveUart.objInfo[i].info[2],
                                                               mmWaveUart.objInfo[i].info[3]);
                mmWaveData->objInfo[i].posx = Util_buildUint32(mmWaveUart.objInfo[i].info[4],
                                                               mmWaveUart.objInfo[i].info[5],
                                                               mmWaveUart.objInfo[i].info[6],
                                                               mmWaveUart.objInfo[i].info[7]);
                mmWaveData->objInfo[i].posy = Util_buildUint32(mmWaveUart.objInfo[i].info[8],
                                                               mmWaveUart.objInfo[i].info[9],
                                                               mmWaveUart.objInfo[i].info[10],
                                                               mmWaveUart.objInfo[i].info[11]);
            }
            else
            {
                mmWaveData->objInfo[i].tid  = 0;
                mmWaveData->objInfo[i].posx = 0;
                mmWaveData->objInfo[i].posy = 0;
            }
        }
    
    
        //UART_control(mmwaveLoggerUartHandle, UARTCC32XX_CMD_RX_FIFO_FLUSH, 0);
    
        return MMWAVE_STATUS_SUCCESS;
    }
    
    void mmwaveStart(void)
    {
        sensor_connected = 1;
        Semaphore_post(mmwaveSemHandle);
    }
    

  • Hector,

    I have verified for you personally that with your setup(IWR6843+ICBOOST) that I can configure the device as well as get data out of the device via the 40 pin headers underneath the ICBOOST, and have provided explicit instruction to do so. Also we have confirmed that you can run the Out of Box Demo, so your board is functional in that regard. Where those signals go beyond the IWR6843+ICBOOST is beyond the scope of this thread, thus I am going to close this thread.

    Best regards,

    Connor Desmond