mpiSynqNetStatus

Declaration

int32_t mpiSynqNetStatus(MPISynqNet          synqNet,
                      MPISynqNetStatus    *status);

Required Header: stdmpi.h

Description

mpiSynqNetStatus reads status from the network associated with the SynqNet object and writes it into the structure pointed to by status. The SynqNet status structure contains network operation state and error counters. This data is updated every controller sample.

synqNet a handle to a SynqNet object
*status pointer to a SynqNet status structure
Return Values
MPIMessageOK
MPIMessageARG_INVALID

Sample Code

/* getControllerCRCError(...) demonstrates how to read 
controller CRC errors using function mpiSynqNetStatus(...) 
and structure MPISynqNetStatus.
*/ 

int32_t getCRCError(MPISynqNet  synqNet, 
                 int32_t        *crcErrUp, 
                 int32_t        *crcErrDown)
{
   int32_t returnValue;
   MPISynqNetStatus synqNetStatus;

   returnValue = 
      mpiSynqNetStatus(synqNet, 
                       &synqNetStatus);

   if(returnValue == MPIMessageOK)
   {
      *crcErrUp = synqNetStatus.crcError.port[0];
      *crcErrDown = synqNetStatus.crcError.port[1];
   }
   return returnValue;
}

See Also

mpiSqNodeStatus | mpiSynqNetInfo