- Reworked the connection object and the IO system
- Reworked the support for TRICS - Added a second generation motor
This commit is contained in:
10
statistics.c
10
statistics.c
@ -51,8 +51,8 @@ int StatisticsCommand(SConnection *con, SicsInterp *pSics, void *pData,
|
||||
|
||||
gettimeofday(&now, 0);
|
||||
dif = timeFloat(timeDif(lastStat, now));
|
||||
SCPrintf(con, eStatus, "calls/s time[%] full[%] mean[ms] command");
|
||||
SCPrintf(con, eStatus, "----------------------------------------------");
|
||||
SCPrintf(con, eValue, "calls/s time[%] full[%] mean[ms] command");
|
||||
SCPrintf(con, eValue, "----------------------------------------------");
|
||||
for (p = list; p != NULL; p = p->next) {
|
||||
if (dif > 0) {
|
||||
calls = p->cnt / dif;
|
||||
@ -64,7 +64,7 @@ int StatisticsCommand(SConnection *con, SicsInterp *pSics, void *pData,
|
||||
} else {
|
||||
dt = 0;
|
||||
}
|
||||
SCPrintf(con, eStatus, "%7.1f %7.1f %7.1f %8.2f %s", calls,
|
||||
SCPrintf(con, eValue, "%7.1f %7.1f %7.1f %8.2f %s", calls,
|
||||
percent, full, dt, p->name);
|
||||
}
|
||||
}
|
||||
@ -74,8 +74,8 @@ int StatisticsCommand(SConnection *con, SicsInterp *pSics, void *pData,
|
||||
p->total.tv_sec = 0;
|
||||
p->total.tv_usec = 0;
|
||||
}
|
||||
SCPrintf(con, eStatus, "----------------------------------------------");
|
||||
SCPrintf(con, eStatus, "total time %.2f", dif);
|
||||
SCPrintf(con, eValue, "----------------------------------------------");
|
||||
SCPrintf(con, eValue, "total time %.2f", dif);
|
||||
lastStat = now;
|
||||
return 1;
|
||||
}
|
||||
|
Reference in New Issue
Block a user