- Added back calculation from motor positions to Q/E variables into
TAS code. - Fixed communication problems in SerPortServer, mainly with terminator detection. - Added SPS switched motors for TOPSI - Debugged Power-PC histogram memory software for TRICS
This commit is contained in:
7
varlog.c
7
varlog.c
@@ -184,21 +184,24 @@
|
||||
int VarlogGetMean(pVarLog self, float *fMean, float *fStdDev)
|
||||
{
|
||||
double dMean, dStdDev;
|
||||
|
||||
int success;
|
||||
|
||||
if(self->iCount > 0)
|
||||
{
|
||||
dMean = self->dSum/(double)self->iCount;
|
||||
dStdDev = sqrt(self->dDeviation/(double)self->iCount);
|
||||
success = 1;
|
||||
}
|
||||
else
|
||||
{
|
||||
dMean = .0;
|
||||
dStdDev = .0;
|
||||
success = 0;
|
||||
}
|
||||
*fMean = (float)dMean;
|
||||
*fStdDev = (float)dStdDev;
|
||||
|
||||
return 1;
|
||||
return success;
|
||||
}
|
||||
/*--------------------------------------------------------------------------*/
|
||||
int VarlogWrapper(pVarLog self, SConnection *pCon,
|
||||
|
||||
Reference in New Issue
Block a user