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.

IWR1443: reconfigure sensor failed in capture demo of mmWave SDK 1.0

Part Number: IWR1443

Hi,

After I configure the sensor once with xWR1443 capture demo in mmWave sdk 1.0 on ES2.0 EVM, I would like to reconfigure the sensor without reloading the image ( I try the demo in ccs).

I tried to send "sensorStop" command in serial port to stop sensor, but get error in CCS.

If I didn't send "sensorStop" command and just send the configure command again in serial port, I still got error.

I checked the error code info in the code, but I still don't why it failed.

#define MMWAVE_ERRNO_BASE                   (-13000)

/**
 * @brief   Error Code: Invalid argument
 */
#define MMWAVE_EINVAL                   (MMWAVE_ERRNO_BASE-1)

/**
 * @brief   Error Code: mmWave link sensor failed
 */
#define MMWAVE_ESENSOR                  (MMWAVE_ERRNO_BASE-12)

I have ever run the mmw demo and it is ok to reconfigure the sensor configuration in web GUI. Why the reconfiguration in capture demo failed? Would you pls kindly advise what I missed?

Thanks,

  • Hi Chris,

    Can you please confirm if the failure because of new values of configuration vs reload of configuration.

    If you try to new values of configuration from scratch (1st time) does that work without errors?
    We will try the snapshot based values at our end as well and get back to you.

    Thank you,
    Vaibhav
  • Hello Chris,

    In my experience, it has not been possible to reload a new sensor configuration without resetting the device and relaunching the target configuration. Every time I need to load a new profile I have to first reset the device and then relaunch the target config and reconnect the device before configuring the sensor.

    Regards,

    Adrian
  • Vaibhav Mahimkar said:
    Can you please confirm if the failure because of new values of configuration vs reload of configuration.

    No matter new values or reload the old config, I met same error.

  • aozer said:


    In my experience, it has not been possible to reload a new sensor configuration without resetting the device and relaunching the target configuration. Every time I need to load a new profile I have to first reset the device and then relaunch the target config and reconnect the device before configuring the sensor.

    If you tried the mmw demo in sdk 1.0 with mmWave Demo Visualizer, you can change the sensor config in GUI without power off/on the board. I saw "sensorStop" before reconfigure the param in the console of mmWave Demo Visualizer.

    Thanks,

  • Hello Chris,

    Yes, you can do this in the mmWave Demo Visualizer but for some reason I have not been able to do this through CCS. I end up having to reload the image every time.

    Regards,

    Adrian
  • Adrian,

    I checked the main.c in capture demo and mmw demo and found for sensorStop command, both of them will call MMWave_stop(). I still don't know why the sensorStop failed on catpure demo.

    As my customer still asked for a capture demo (csi output) with reconfigure feature, would you pls help to check why sensorStop failed in capture demo? How to make the sensor reconfigure work in capture demo?

    Will the capture demo of next release of sdk support reconfigure feature?

    Thanks,
  • Hi,

    Would you pls kindly help?

    Thanks,
  • Hello Chris,

    I have contacted the SDK team, I will update you with the response.

    Regards,

    Adrian
  • Hello Chris,

    The SDK team has told me that this is a known issue that will be fixed in the next release. The current workaround is as follows:

    For advanced users who are comfortable in building the SDK base component (mmWave API), we can suggest following code workaround for supporting finite frames and sensorStop.
    - ti\control\mmwave\src\mmwave_link.c: MMWave_stopLink(): return success when rlSensorStop() returns value 21. Now rebuild mmWave library and then the demo. Refer to the SDK user guide for build instructions.
  • Adrian,

    Thanks for your help!

    But I can't understand why the error only happens in capture demo, but not mmw demo with same sensor configuration. Would you pls help again?

    Thanks,
  • Hello Chris,

    I will update you once I find out from the SDK team.

    Regards,

    Adrian
  • Hello Chris,

    This is because the mmWave link API returns an informational error to indicate that the frame has already ended. The default scripts in the capture demo only send N frames while the scripts used by the mmW demo are configured for infinite frames.

    The mmWave_stop on the remote peer will not get invoked if the rlSensorStop returns the informational message that the FRAME has already ended. The mmWave treats all link API failures as fatal error messages. The infrastructure needs to be upgraded to handle these warning conditions properly.

    This affects the sensorStop command in capture demo most as the usage of finite frames is more prevalent in that demo. SensorStop works in mmW demo with Visualizer since the number of frames are set to infinite in this demo.

  • Adrian,

    After fixed the -13001 error, I met new error when I added CSI output support in capture demo. It seems that CBUFF_init should be called only once. I will try to move CBUFF_init/open to CaptureDemo_initTask() and see if it can fix the issue or not.

    Below is the error I saw after fixed the -13001 error as you suggested and adding CSI output.

  • Hi,

    I changed CaptureDemo_CLISensorStop function in capture_cli.c as below. No error in CCS output console. I will try to detect the CSI signal to see if it works or not.

    static int32_t CaptureDemo_CLISensorStop (int32_t argc, char* argv[])
    {
    int32_t errCode;

    /* Stop the sensor: */
    if (MMWave_stop (gCaptureMCB.ctrlHandle, &errCode) < 0)
    {
    System_printf ("Error: mmWave Stop failed [Error code %d]\n", errCode);
    return -1;
    }

    //add by chris
    if (gCaptureMCB.hsi != Capture_HSI_NONE)
    {
    /* Close the CBUFF Driver: */
    if (CBUFF_close (gCaptureMCB.cbuffHandle, &errCode) < 0)
    {
    System_printf ("Debug: CBUFF Driver close failed [Error code %d]\n", errCode);
    return -1;
    }

    /* Deinitialize and shutdown the CBUFF: */
    if (CBUFF_deinit (gCaptureMCB.cbuffHandle, &errCode) < 0)
    {
    System_printf ("Debug: CBUFF Driver deinit failed [Error code %d]\n", errCode);
    return -1;
    }
    }
    //--------------------------------------
    return 0;
    }

    Thanks,
  • Hello Chris,

    Were you able to detect the CSI signal?

    Regards,

    Adrian
  • Adrian,

    Yes. I can detect the CSI data signal with my modified code after reconfig. I have shared the code change to customer to see if they can get right data on CSI after reconfigure or not.

    Thanks,