.

mpiRecorderMemory

Declaration

 
long mpiRecorderMemory(MPIRecorder recorder,
                       void        **memory) 
 

Required Header: stdmpi.h

Description

mpiRecorderMemory writes an address to the contents of memory. An address can be used to access a Recorder's (recorder) memory. An address calculated from it can be passed as the src argument to mpiRecorderMemoryGet(...) and as the dst argument to mpiRecorderMemorySet(...).

 
Return Values
MPIMessageOK  

Sample Code


/* recorderHighCountGet(...) demonstrates how to read recorder High
Count directly through memory. mpiRecorderMemory(...) obtains the
recorder control memory pointer. The pointer's address is then passed
into mpiRecorderMemoryGet(...) to obtain the HighCount value.
Note: MEIXmpRecorder *memory must be casted as (void *) in
mpiRecorderMemory.
*/

long recorderHighCountGet(MPIRecorder  recorder, 
                          long         *highCount)
{

   MEIXmpDataRecorder *memory;
   long               returnValue;

   /* Get recorder control memory pointer */
   returnValue = 
   mpiRecorderMemory(recorder, 
                    (void *)&memory);

   /* Get recorder HighCount */
   if(returnValue == MPIMessageOK)
   {

      returnValue = 
         mpiRecorderMemoryGet(recorder,
                              highCount,
                              &memory->HighCount,
                              sizeof(&memory->HighCount));
   }

   return returnValue;
}

See Also

mpiRecorderMemoryGet | mpiRecorderMemorySet

 

       Legal Notice  |  Tech Email  |  Feedback
      
Copyright ©
2001-2021 Motion Engineering