wiki:Docs/Prog/Manual/ApplicationLibraries/lib825ev/Weight/CheckWIM

Version 4 (modified by Don Wilson, 14 years ago) ( diff )

--

CheckWIM

Checks for availability of weight data in the high speed WIM weight buffer

int CheckWIM(int nScale)

Parameters

  • nScale - scale number

Return Value

  • Returns number of weights recorded in buffer

Remarks

For high speed the buffer records integer gross weight values only.

Example

extern int* pwim;

// Do WIM setup first ...
CSleep slp(1);
int i, x;
while(1)
{
   slp.Pause();
   x = CheckWIM(1);
   if(x > 0)
   {
      // Loop through WIM samples
      for(i = 0; i < x; i++)
      {
          printf("weight %d\r\n", pwim[i]);
      }
   }
   else if(CheckWtRcv(1))  // If below threshold
   {
   
   }
   // Check for keypress or some other action to exit loop ...
}

See Also

Note: See TracWiki for help on using the wiki.