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.

IWR1443BOOST: Trying to use config without visualizer

Part Number: IWR1443BOOST
Other Parts Discussed in Thread: IWR1443, , IWR1642BOOST

Hello,

I wanted to set the configuration of the radar device in the code so I don't have to send it every time using mmwave visualizer. I found this forum post:

I tried this and used the .c and .h file and edited them to my own configuration. But when I upload this to my radar it doesn't output anything. I have put it in the CLI_init function as said in the forum post. 

Can someone help me figure this out?

  • Hello Vera,

    As suggested in the thread referenced above, you can use either method to hard-code the config parameters, modifying the mmWave Demo CLI code to your desired requirements or bypassing/removing the CLI and directly programming the device configuration APIs to mimic what the CLI does. In either case, please make sure that you call the complete sequence of APIs which is normally called using the CLI, including the sensor start API.

    While we don't have an example online to achieve this with the OOB demos, you can look at the following TI Design which hard-codes the device configuration by directly programming the mmWave APIs to configure the sensor without a CLI.


    Power Optimization for IWR1443 77GHz-Level Transmitter Reference Design

    Complete source code is provided as a zip file on the design webpage under Software (2) section. Please note that this design is based on mmWave SDK 1.1.0.2 and not ported to the latest mmWave SDK which is 1.2.0.5, but it should serve as a good reference on how to program the various mmWave APIs to achieve the desired sensor configuration.

    The configuration is done in function demo_staticConfig() in iwr1443/source/demo.c. Please click the "This resolved my issue" button if your query is answered.

    Thanks

    -Nitin 

  • 
    

    Hi Nitin,

    Thanks for the reply.

    This is a good sollution but it also costs me a lot of time to figure out how to apply this to the software as I have to modify the datapathtask to remove all the cli commands. Maybe I am going to give it a try in the future. But for now I would like to use the cli method.

    I have been trying to get it to work but no success so far. I found out that in the example I reference to in my first post that they used a mailbox and have at every setting in the cli.c a function called mmwDemo_mboxWrite where they write the settings to, see the piece of code below.

    int32_t MmwDemo_CLIGuiMonSel (int32_t argc, char* argv[])
    {
        MmwDemo_GuiMonSel   guiMonSel;
        MmwDemo_message     message;
    
        /* Sanity Check: Minimum argument check */
        if (argc != 7)
        {
            CLI_write ("Error: Invalid usage of the CLI command\n");
            return -1;
        }
    
        /* Initialize the ADC Output configuration: */
        memset ((void *)&guiMonSel, 0, sizeof(MmwDemo_GuiMonSel));
    
        /* Populate configuration: */
        guiMonSel.detectedObjects           = atoi (argv[1]);
        guiMonSel.logMagRange               = atoi (argv[2]);
        guiMonSel.noiseProfile              = atoi (argv[3]);
        guiMonSel.rangeAzimuthHeatMap       = atoi (argv[4]);
        guiMonSel.rangeDopplerHeatMap       = atoi (argv[5]);
        guiMonSel.statsInfo                 = atoi (argv[6]);
    
        /* Save Configuration to use later */
        memcpy((void *)&gMmwMCB.cliCfg.guiMonSel, (void *)&guiMonSel, sizeof(MmwDemo_GuiMonSel));
    
    
        /* Send configuration to DSS */
        memset((void *)&message, 0, sizeof(MmwDemo_message));
    
        message.type = MMWDEMO_MSS2DSS_GUIMON_CFG;
        memcpy((void *)&message.body.guiMonSel, (void *)&guiMonSel, sizeof(MmwDemo_GuiMonSel));
    
        if (MmwDemo_mboxWrite(&message) == 0)
            return 0;
        else
            return -1;
    }

    But when I build this code it seems it cannot finde the mboxwrite function, is this because it is an older function that had been replaced in the newer version? And do I even need he mailbox thing to set all the config parameters?

    Thanks for your help!

  • I am also trying to figure it out with debugging but the program crashes when it loads. I uploaded a picture of the error.

    If I comment the function MmwDemo_IniRSSDSSCfg() out of the CLIInit function(this is from the reference I used for de CLI commands) then it just loads the program and I can start it. So is the way that they did it in the reference wrong or did I do something wrong? If I need to post more information just let me know.

  • Hi Vera,

    Which EVM are you testing this on, IWR1443BOOST or IWR1642BOOST?

    I ask because your original post is tagged with IWR1443BOOST, but the code you referred to above is from the xwr16xx OOB demo and meant to run on an IWR16xx device/EVM which has the DSS (DSP SubSystem containing the C674x DSP). If you run this on a 1443 device, it would not work as 1443 has only the MSS (R4F core). Please confirm which device you are using.

    Thanks
    -Nitin
  • Hello Nitin,

    I am using the IWR1443BOOST. The code that I posted above was from that example I posted in my first post, I have tried to use it without the message stuff and couldn't get it to work.
    I also tried out the code you provided and couldn't get that to work either. When I put everything in my code it doesn't set up the config of the mmwave and comes back with an error code but I haven't figured out yet what that error code means. The error code was something like -2000000, don't know it exactly and can't try it now to see the error code.

    Thanks,
    Vera
  • Hi Vera,

    As I mentioned, the code snippet you posted above is from the IWR16xx demo version of the function MmwDemo_CliGuiMonSel. I have attached a snapshot comparing this function between the 14xx and 16xx OOB demos from the latest SDK. You can see that the 14xx function (to the left) does not write to the dss mailbox. I assume that the example code provided by Herman Stubeda in the above thread was for xwr16xx OOB demo.

    You need to replace this function with the 14xx OOB demo equivalent as shown in the snapshot. Please also note that the example shared in the thread you referred to is probably based on mmWave SDK 1.1.0.2 since the latest SDK 1.2.0.5 was note available in Nov 2017. So the easiest way would be to get this code running in the IWR14xx demo from that SDK version and once you have it working with SDK 1.1.0.2, port it to the latest SDK 1.2.0.5 using the migration guide provided in the release notes for the latest SDK.

    -Nitin