Other Parts Discussed in Thread: MMWAVE-SDK
Howdy,
I have been using the traffic monitoring demo for quite sometime and have adapted it to function with ROS. For my research I would like to have has much information about tracked targets as possible, and unfortunately, the traffic monitoring demo does not transmit each target's covariance matrix. I have looked through the traffic monitoring code for the 18XX radars in CCS and found in mss_main.c the data structure that is transmited via UART is trackerProc_Target *tList in the function TrackerDemo_transmitProcessedOutput.
void TrackerDemo_transmitProcessedOutput(UART_Handle uartHandle,
DPC_ObjectDetection_ExecuteResult *result)
{
uint32_t packetLen;
uint32_t tlvIdx = 0;
uint32_t numPaddingBytes;
uint8_t padding[MMWDEMO_OUTPUT_MSG_SEGMENT_LEN];
MmwDemo_output_message_tl tl[MMWDEMO_OUTPUT_MSG_MAX];
DPIF_PointCloudCartesian *objOut;
DPIF_PointCloudSpherical *objOutSph;
DPIF_PointCloudSideInfo *objOutSideInfo;
DPC_ObjectDetection_Stats *stats;
trackerProc_Target *tList;
trackerProc_TargetIndex *tIndex;
int32_t errCode;
...
I have followed back the data structure (trackerProc_Target) to the file mmwave_industrial_toolbox_4_4_1/labs/common/src/dpu/trackerproc/trackerproc.h where it is defined as:
typedef struct trackerProc_Target_t { /*! @brief tracking ID */ uint32_t tid; /*! @brief Detected target X coordinate, in m */ float posX; /*! @brief Detected target Y coordinate, in m */ float posY; /*! @brief Detected target X velocity, in m/s */ float velX; /*! @brief Detected target Y velocity, in m/s */ float velY; /*! @brief Detected target X acceleration, in m/s2 */ float accX; /*! @brief Detected target Y acceleration, in m/s2 */ float accY; #ifdef GTRACK_3D /*! @brief Detected target Z coordinate, in m */ float posZ; /*! @brief Detected target Y velocity, in m/s */ float velZ; /*! @brief Detected target Z velocity, in m/s */ float accZ; /*! @brief Detected target dimensions */ //float dim[3]; #endif #ifdef TRACKER_EC_OUTPUT #ifdef GTRACK_3D /*! @brief Target Error covarience matrix, [4x4 float], in row major order, range, azimuth, elev, doppler */ float ec[16]; float g; #else /*! @brief Target Error covarience matrix, [3x3 float], in row major order, range, azimuth, doppler */ float ec[9]; float g; #endif #endif
It shows that the tList can store the covariance given that #ifdef TRACKER_EC_OUTPUT is true. In CCS it shows that TRACKER_EC_OUTPUT is false, and I am unfamiliar with how to turn on and off macros. I am only using TX1, and TX2 so GTRACK_3D is unnecessary; however, I can get that information if I use a 3D profile. Would having TRACKER_EC_OUTPUT set to true cause any issues with the current traffic monitoring code or would the macro handle all the changes? Most importantly, how is TRACKER_EC_OUTPUT set? Also, would any other data structures need to be modified to accommodate the increased memory size, or is this also handled by the macro?
Thanks for the help,
Andrew