Function mon_get_monitoring

Function Documentation

ECAL_API int mon_get_monitoring(const char **mon_buf_, int *mon_buf_len_)

Get monitoring protobuf string.

Return

Monitoring buffer length or zero if failed.

// let eCAL allocate memory for the monitoring buffer and return the pointer to 'buf'
const char* mon_buf_     = NULL;
int         mon_buf_len_ = 0;
mon_get_monitoring(subscriber_handle, &mon_buf_, &mon_buf_len_);
if(mon_buf_len_ > 0)
{
  ...
  // PROCESS THE BUFFER CONTENT HERE
  ...
  // finally free the allocated memory
  ecal_free_mem(((void*)rcv_buf););
}

Parameters
  • [out] mon_buf_: Pointer to store the monitoring information.

  • [out] mon_buf_len_: Length of allocated buffer, eCAL is allocating the buffer for you, use ecal_free_mem to free the buffer finally.