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.

AWR1843BOOST: Task of mmr demo: MRR_MSS_mmWaveCtrlTask

Expert 2050 points
Part Number: AWR1843BOOST

In automotive lab 007_mrr demo, there is a task MRR_MSS_mmWaveCtrlTask. I am not very clear what this task is used for? Can you please explain little bit what is the major function of this task in the demo, which user interface is related with this task, is there any impact if we remove this task?

...
/*****************************************************************************
 * Launch the mmWave control execution task
 * - This should have a higher priroity than any other task which uses the
 *   mmWave control API
 *****************************************************************************/
Task_Params_init(&taskParams);
taskParams.priority  = 6;
taskParams.stackSize = 3*1024;
Task_create(MRR_MSS_mmWaveCtrlTask, &taskParams, NULL);

...
 *  @b Description
 *  @n
 *      This is the task which provides an execution context for
 *      the mmWave control module.
 *
 *  @param[in]  arg0
 *      Argument0 with which the task was created
 *  @param[in]  arg1
 *      Argument1 with which the task was created
 *
 *  @retval
 *      Not Applicable.
 */
static void MRR_MSS_mmWaveCtrlTask (UArg arg0, UArg arg1)
{
    int32_t errCode;

    while (1)
    {

        /* Execute the mmWave control module: */
        if (MMWave_execute (gMrrMSSMCB.ctrlHandle, &errCode) < 0)
        {
            System_printf ("Error: mmWave control execution failed [Error code %d]\n", errCode);
        }
    }
}

Kind regards

  • Hi Lei,

    This task is quite important. It gives mmWave a separate task context to run in. mmWave library is what configures the RF, so, without it, the RF won't run at all, and you won't get any data on the ADC buffer.

    Finally, MMWave_execute will spend nearly all of its time in a sleep state, waiting for a semaphore in case it has to receive some messages from the RF via mmwavelink. You can try reducing the stack size of the task a little if memory footprint is a concern. The task should be very light in terms of processor load to begin with.

    Regards,

    Aayush