diff --git a/site_ansto/hardsup/west4100util.c b/site_ansto/hardsup/west4100util.c index a6dde8dd..10a2d2a6 100644 --- a/site_ansto/hardsup/west4100util.c +++ b/site_ansto/hardsup/west4100util.c @@ -346,7 +346,7 @@ /*--------------------------------------------------------------------------*/ int WEST4100_Query(pWEST4100 *pData, int parAddress, int *parValue) { - unsigned char pCommand[20], pReply[132], pAddress[1]; + unsigned char pCommand[20], pReply[132], pAddress[2]; int iRet; pWEST4100 self; @@ -374,7 +374,7 @@ /* -------------------------------------------------------------------------*/ int WEST4100_Write(pWEST4100 *pData, int parAddress, int parValue) { - unsigned char displaytext[20]; + unsigned char displaytext[40]; int iRet; pWEST4100 self; diff --git a/site_ansto/motor_dmc2280.c b/site_ansto/motor_dmc2280.c index 82060725..17f3b8c9 100644 --- a/site_ansto/motor_dmc2280.c +++ b/site_ansto/motor_dmc2280.c @@ -5445,8 +5445,7 @@ int DMC2280Action(SConnection *pCon, SicsInterp *pSics, void *pData, } return 1; } else if(self->abs_encoder && strcasecmp("stats", argv[1]) == 0) { - char line[132]; - snprintf(line, CMDLEN, "%s.stats=%s samples=%.0f, slope=%f, intercept=%f, r=%f, stepsPerX=%f", + SCPrintf(pCon, eValue, "%s.stats=%s samples=%.0f, slope=%f, intercept=%f, r=%f, stepsPerX=%f", self->name, self->doStats ? "ON" : "OFF", self->S_n, @@ -5454,7 +5453,6 @@ int DMC2280Action(SConnection *pCon, SicsInterp *pSics, void *pData, self->S_b, self->S_r, self->cntsPerX * self->S_m); - SCWrite(pCon, line, eValue); if (argc > 2) { if (strcasecmp(argv[2], "reset") == 0) { /* reset the stats */