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.

DCA1000EVM: CLI inconsistent data size in each capture

Part Number: DCA1000EVM
Other Parts Discussed in Thread: IWR1642

Hi,

I'm using a DCA1000EVM and an IWR1642 ES1 (OOB demo from SDK 01.02). When using the DCA1000EVM CLI tool to collect the raw data, I got inconsistent data size in each capture. 

The configuration is 1000 samples per chirp, 64 chirps per frame, 25 frames per seconds, 1 TX and 1 RX, and each capture is 5 seconds. The capture is in "raw" data mode and "Duration" stop mode. I expect 1000*64*25*5*2*2=32,000,000 bytes of data, but I'm getting random data size, e.g. 31,999,968, 32,254,768, 32,007,248, 31,967,936, etc. The DCA1000EVM is always started before starting the sensor.

I'm using the demo visualizer to control the radar and can confirm the data is correct from the visualizer. I can also confirm that it works with mmWaveStudio version 1. I've attached the radar configuration file and the DCA1000EVM CLI configuration file. 

config.zip

Could you please guide me where the problem might be?

Thanks,

Han

  • Hi, Han:

    Please check the SDK01.02 users guide mention that it support DCA1000 CLI tool.  By the way, the "Duration" stop mode may not work for this tool.  Please try to use the actual size and let me know. 

    Best,

    Zigang

  • Hi Zigang,

    The SDK 01.02 does not mention anything about the CLI tool. It does capture the expected data size when using "bytes" stop mode. 

    Do you mean the "Duration" stop mode may not work with SDK 01.02 or all versions of SDK? Or are you implying the CLI is not supported with SDK 01.02 at all?

    Thanks,

    Han

  • Great to hear that!  My impression is that "Duration" is not working for all SDK version.   

    Best,

    Zigang

  • Now I'm trying to use the "infinite" mode and set the "maxRecFileSize_MB" parameter. If I set it to 32, I expect the file size to be either 32,000,000 bytes or 32*1024*1024=33,554,432 bytes, but the data in each file is actually 33,553,520 bytes, though the "size on disk" of the file would be 33,554,432. My data size of each frame is supposed to be 64000 bytes. This makes it nearly impossible to ensure each file saves a certain number of complete frames, since the "maxRecFileSize_MB" parameter seems must be an integer. Is there a workaround for this? 

  • HI, Han:

    In the "infinite"mode, the data will keep coming until you send the stop command to DCA1000.   But each file size will be "maxRecFileSize_MB", and then it will continue onto the second file and etc.

    Best,

    Zigang

  • Yes, I understand that. Could you please answer my question?

  • HI, Han:

    I was able to get the right size.   I am sending the DCA1000 capture start before sending sensorStart.   Are you doing the same?

    sendCfg(COM_PORT_RADAR_CONFIG, sensorStopFile);
    system(['DCA1000EVM_CLI_Control.exe start_record ', datacardConfigJsonFile]);
    pause(0.5);
    sendCfg(COM_PORT_RADAR_CONFIG, sensorRestartFile);

    Best,

    Zigang

  • Yes. Are you saying you get the correct number of data points in each file after setting the "maxRecFileSize_MB" parameter, i.e. 32 MB = 32,000,000 bytes = 4,000,000 16bit complex? 

     

  • I change the "maxRecFileSize_MB" to 128K because I can want to wait for very long, and my capture file size is 128*1024Kbyte = 1131072KByte.

    Best,

    Zigang

  • Using the same setting I got 134,216,992 bytes = 131071.3 Kbytes, 0.7 Kbytes is missing, could you confirm if this is the same as yours?

  • Here attached my json file for you to check. 

    Best,

    Zigang

    {
    	"DCA1000Config": {
    		"dataLoggingMode": "raw",
    		"dataTransferMode": "LVDSCapture",
    		"dataCaptureMode": "ethernetStream",
    		"lvdsMode": 2,
    		"dataFormatMode": 3,
    		"packetDelay_us": 25,
    		"ethernetConfig": {
    			"DCA1000IPAddress": "192.168.33.180",
    			"DCA1000ConfigPort": 4096,
    			"DCA1000DataPort": 4098
    		},
    		"ethernetConfigUpdate": {
    			"systemIPAddress": "192.168.33.30",
    			"DCA1000IPAddress": "192.168.33.180",
    			"DCA1000MACAddress": "12.34.56.78.90.12",
    			"DCA1000ConfigPort": 4096,
    			"DCA1000DataPort": 4098
    		},
    		"captureConfig": {
    			"fileBasePath": "C:\\myCliSavedData",
    			"filePrefix": "adc_data",
    			"maxRecFileSize_MB": 128,
    			"sequenceNumberEnable": 1,
    			"captureStopMode": "infinite",
    			"bytesToCapture": 405504000,
    			"durationToCapture_ms": 1000,
    			"framesToCapture": 5
    		},
    		"dataFormatConfig": {
    			"MSBToggle": 0,
    			"reorderEnable": 1,
    			"laneFmtMap": 0,
    			"dataPortConfig": [
    				{
    					"portIdx": 0,
    					"dataType": "complex"
    				},
    				{
    					"portIdx": 1,
    					"dataType": "complex"
    				},
    				{
    					"portIdx": 2,
    					"dataType": "complex"
    				},
    				{
    					"portIdx": 3,
    					"dataType": "complex"
    				},
    				{
    					"portIdx": 4,
    					"dataType": "complex"
    				}
    			]
    		}
    	}
    }
    

  • Here also attached my example radar configuration file for you to try. chirp1_60G_quick.cfg

    Best,

    Zigang

  • The json files are exactly the same. Your cfg file is not for IWR1642 ES1. 

  • Can you modify your profile/chirp configuration to have 512 samples and 50ms frame time to see whether things are different?  

    You can also try with radar studio to see whether you have the same file size issue. 

    It will be great if you can try with latest version of the device with more recent SDK version.   I never tested this feature with that old version of device and old version of the SDK.    You can check the SDK 1.02 users guide to see whether it claims that it support DCA1000 CLI interface.  

    Best,

    Zigang

  • With 512 samples and 50 ms frame time, I have exactly the same issue.

    I don't find the "maxRecFileSize_MB" option or anything similar in radar studio. 

    Could you please post a screenshot of your captured bin file like the one below?

  • HI, 

    The maxRecFileSize_MB for radar studio is configured inside cf.json under the C:\ti\mmwave_studio_02_01_01_00\mmWaveStudio\PostProc\.   

    Not sure it can be modified.  But you can check to see whether the size is matching with the value inside cf.json.

    My size is the same as yours.  It should be good then.  

     

    Best,

    Zigang

    Zigang

  • I have also check the log file that saved together with the bin file.   I see there is some package loss and filled up with zeros. 

    Raw Data :
    Out of sequence count - 2
    Out of sequence seen from 455588 to 455602
    First Packet ID - 1
    Last Packet ID - 488819
    Number of received packets - 488798
    Number of zero filled packets - 21
    Number of zero filled bytes - 30576
    Capture start time - Fri Mar 11 17:01:45 2022
    Capture end time - Fri Mar 11 17:03:16 2022
    Duration(sec) - 91

    Do you want to send me your log file.

    Best,

    Zigang

  • I don't have zero filled packets. 

    But anyway, what is more important is, if I parse this bin file, I get 33,554,248 complex data, but I'm expecting 128 MB data which should contain 128*1024*1024/4 = 33,554,432 complex data. Do you agree with me on this? 

  • Agree with you.   On my size, I usually only part of the data for analysis, so I do not care too much whether the file size is exactly correct, as long as the data are all continuous inside the data file.   Can you let me know how do you plan to use these captures and why the data size is that important to you?  Can you have a work around?  Let us say you need to process about 100 frames of data, then you program the capture about 110 frames so you always have enough data to process.    

    On the other hand, you can try capture with radar studio, I believe the data size there should be accurate.

    Best,

    Ziang

  • It is just the mismatch between the expected size and the captured size makes me concern about potential data loss. It would be good if the bug can be fixed in a later release. Anyway, thank you very much for your help.