diff --git a/iocBoot/iocWithAsyn/motor.cmd.SMChydra b/iocBoot/iocWithAsyn/motor.cmd.SMChydra index 90130ec2..2921b2d2 100644 --- a/iocBoot/iocWithAsyn/motor.cmd.SMChydra +++ b/iocBoot/iocWithAsyn/motor.cmd.SMChydra @@ -12,6 +12,10 @@ asynSetTraceMask("serial5", 0, 1) # Leave ascii selected so traces can be turned on with a single click asynSetTraceIOMask("serial5", 0, 1) +# Set end-of-string terminators +asynOctetSetInputEos("serial5",0,"\r\n") +asynOctetSetOutputEos("serial5",0,"\r\n") + dbLoadTemplate("motor.substitutions.SMChydra") # SMChydraCreateController( diff --git a/motorApp/MicosSrc/SMChydraDriver.cpp b/motorApp/MicosSrc/SMChydraDriver.cpp index dab3174b..c82f25ed 100644 --- a/motorApp/MicosSrc/SMChydraDriver.cpp +++ b/motorApp/MicosSrc/SMChydraDriver.cpp @@ -267,6 +267,10 @@ asynStatus SMChydraAxis::stop(double acceleration ) asynStatus status; //static const char *functionName = "SMChydraAxis::stop"; + // Set stop deceleration (will be overridden by accel if accel is higher) + sprintf(pC_->outString_, "%f %i ssd", (acceleration * axisRes_), (axisNo_ + 1)); + status = pC_->writeController(); + sprintf(pC_->outString_, "%i nabort", (axisNo_ + 1)); status = pC_->writeController(); return status;