diff --git a/src/sinqAxis.cpp b/src/sinqAxis.cpp index 7a0e361..7cd70b6 100644 --- a/src/sinqAxis.cpp +++ b/src/sinqAxis.cpp @@ -205,6 +205,21 @@ sinqAxis::sinqAxis(class sinqController *pC, int axisNo) exit(-1); } + /* + Initialize the parameter library entry for the motor message text, because + it is read during the first poll before it has been written to. + */ + status = setStringParam(pC_->motorMessageText(), ""); + if (status != asynSuccess) { + asynPrint(pC_->pasynUser(), ASYN_TRACE_ERROR, + "Controller \"%s\", axis %d => %s, line %d:\nFATAL ERROR " + "(setting a parameter value failed " + "with %s)\n. Terminating IOC", + pC->portName, axisNo_, __PRETTY_FUNCTION__, __LINE__, + pC_->stringifyAsynStatus(status)); + exit(-1); + } + // Motor is assumed to be enabled status = setIntegerParam(pC_->motorEnableRBV(), 1); if (status != asynSuccess) {