Skip to content

Commit

Permalink
- Fix for excessive FLNK processing reported by Alexander Söderqvist …
Browse files Browse the repository at this point in the history
…(Cosylab). Modified so that recGblFwdLink() is only called on a False to True transition of DMOV.

- Incremented VERSION # to 6.10.
- Updated comments.
  • Loading branch information
rsluiter committed Feb 25, 2015
1 parent 4d89da1 commit 0ef3905
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 8 deletions.
13 changes: 12 additions & 1 deletion README
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Motor Module R6-9 Release Notes
Motor Module R6-10 Release Notes
===============================================================================

The motor module software in this release is compatible with EPICS base
Expand Down Expand Up @@ -147,6 +147,17 @@ Known Problems
Modification Log for R6-9
=========================

1) Alexander Aulin S�derqvist (Cosylab) reported illogical motor record FLNK
processing. Corrected FLNK processing so that recGblFwdLink() is only
called on a False to True transition of DMOV.

Files modified: motorApp/MotorSrc/motorRecord.cc
motorApp/MotorSrc/motorRecord.dbd


Modification Log for R6-9
=========================

1) Kevin Peterson added support for the Micronix MMC-200 & MMC-100 controllers.

Files added: motorApp/MicronixSrc
Expand Down
17 changes: 10 additions & 7 deletions motorApp/MotorSrc/motorRecord.cc
Original file line number Diff line number Diff line change
Expand Up @@ -183,9 +183,11 @@ HeadURL: $URL$
* - Fix for LOAD_POS not posting RVAL.
* - Reversed order of issuing SET_VEL_BASE and SET_VELOCITY commands. Fixes MAXv
* command errors.
* .71 02-25-15 rls - Fix for excessive motor record forward link processing.
*
*/

#define VERSION 6.9
#define VERSION 6.10

#include <stdlib.h>
#include <string.h>
Expand Down Expand Up @@ -1164,9 +1166,10 @@ where the motor is in a sequence of movements that comprise a single motion.
Update record timestamp, call recGblGetTimeStamp().
Process alarms, call alarm_sub().
Monitor changes to record fields, call monitor().
IF Done Moving field (DMOV) is TRUE.
IF Done Moving field (DMOV) is TRUE, AND, Last Done Moving (LDMV) was False.
Process the forward-scan-link record, call recGblFwdLink().
ENDIF
Update Last Done Moving (LDMV).
Set Processing Active indicator field (PACT) false.
Exit.
Expand Down Expand Up @@ -1402,9 +1405,10 @@ static long process(dbCommon *arg)
alarm_sub(pmr); /* If we've violated alarm limits, yell. */
monitor(pmr); /* If values have changed, broadcast them. */

if (pmr->dmov)
recGblFwdLink(pmr); /* Process the forward-scan-link record. */

if (pmr->dmov != 0 && pmr->ldmv == 0) /* Test for False to True transition. */
recGblFwdLink(pmr); /* Process the forward-scan-link record. */
pmr->ldmv = pmr->dmov;

pmr->pact = 0;
Debug(4, "process:---------------------- end; motor \"%s\"\n", pmr->name);
return (status);
Expand Down Expand Up @@ -1590,8 +1594,7 @@ OFFset = userVAL - DialVAL * DIR
ELSE
Calculate....
IF Retry enabled, AND, [(encoder present, AND, use encoder true),
OR, use readback link true]
IF Retry enabled, AND, Retry mode is Not "In-Position", AND, [(encoder present, AND, use encoder true), OR, use readback link true]
Set relative positioning indicator true.
ELSE
Set relative positioning indicator false.
Expand Down
5 changes: 5 additions & 0 deletions motorApp/MotorSrc/motorRecord.dbd
Original file line number Diff line number Diff line change
Expand Up @@ -589,6 +589,11 @@ recordtype(motor) {
special(SPC_NOMOD)
initial("1")
}
field(LDMV,DBF_SHORT) {
prompt("Last Done moving value")
special(SPC_NOMOD)
initial("1")
}
field(MOVN,DBF_SHORT) {
prompt("Motor is moving")
special(SPC_NOMOD)
Expand Down

0 comments on commit 0ef3905

Please sign in to comment.