Commit Graph
444 Commits
Author SHA1 Message Date
kpetersn 26771f23dc Added a comment about reverting the change from .69 2018-08-21 12:05:30 -05:00
kpetersn 95c0a4caa2 Don't set "stop" field true if driver returns RA_PROBLEM true. It is
the driver's responsiblity to stop a motor if the condition that results
in the RA_PROBLEM bit being set doesn't result in the motor
automatically stopping.

This partially reverts commit 303a9208e3
2018-08-21 11:56:25 -05:00
kpetersn 270347dfb3 Set LVIO=1 if DLLM > DHLM, since at least one limit being violated 2018-08-20 17:41:34 -05:00
Kevin Peterson a21b1ccbd6 Merge pull request #99 from EuropeanSpallationSource/JOG_LVIO_JOG_nolockup
motorRecord.cc: Jogging against to LVIO in LVIO

This change resets the JOGF/JOGR fields to zero when a limit violation occurs, rather than when the JOGF/JOGR fields get reset to zero by the user.
2018-08-20 14:50:07 -05:00
Torsten Bögershausen 9e5b54323a motorRecord.cc: Jogging against to LVIO in LVIO
When jogging has stopped because the motor is close to a softlimit,
the record seems to be locked up when the same jog button is pressed again.

The user must release the jog button, before doing any other action.
STOP doesn't help, neither does jog into the opposite direction work.

Solution:
Clear the JOGF and JOGR button in the record.
2018-08-20 09:08:22 +02:00
Kevin Peterson 3683d3f0ea Merge pull request #56 from EuropeanSpallationSource/JOG_stopped
Record recognizes motor stop while jogging.

Text from the pull request:

'The following situation came up while debugging soft limits in a
motion controller which had different values then the record.

The motor is at position 50mm (RBV=50), the low soft limit is 15 (LLM=15),
jogging velocity is 10 mm/sec (JVEL=10).

The motion controller has an internal soft limit which is 35 mm, which
we want to test.
Set JOGR to 1, the motor will move backwards.
(Side note: it would be stopped by the record once it passed 25mm).

Before that, the motion controller stops the motor internally and reports DONE.
The state machine in the record is not prepared to handle this and JOGR stays 1.
The expected behavior is that JOGR returns to 0.
Because this is an unexpected stop, reset even pending home requests.
In other words: call clear_buttons(pmr)

Whether or not an alarm is raised may be another question.
The natural thing would be to set LVIO to 1, but we don't know why the controller
stopped the motion.
Unless we add a bit in MSTA like "RA_LVIO"...
But in any case this can and should go into a separate commit.'
2018-07-03 09:11:27 -05:00
Torsten Bögershausen 9c8a8e8c35 Record recognizes motor stop while jogging
The following situation came up while debugging soft limits in a
motion controller which had different values then the record.

The motor is at position 50mm (RBV=50), the low soft limit is 15 (LLM=15),
jogging velocity is 10 mm/sec (JVEL=10).

The motion controller has an internal soft limit which is 35 mm, which
we want to test.
Set JOGR to 1, the motor will move backwards.
(Side note: it would be stopped by the record once it passed 25mm).

Before that, the motion controller stops the motor internally and reports DONE.
The state machine in the record is not prepared to handle this and JOGR stays 1.
The expected behavior is that JOGR returns to 0.
Because this is an unexpected stop, reset even pending home requests.
In other words: call clear_buttons(pmr)

Whether or not an alarm is raised may be another question.
The natural thing would be to set LVIO to 1, but we don't know why the
controller stopped the motion.
Unless we add a bit in MSTA like "RA_LVIO"...
But in any case this can and should go into a separate commit.
2018-06-29 11:38:31 +02:00
Kevin Peterson 7a758b7238 Merge pull request #84 from mp49/encoder_ratio_fix
Keep the sign information on the MRES and ERES used to calculate the encoder ratio. This fixes issue #82.
2018-06-27 12:21:22 -05:00
Kevin Peterson 0dc3a09a0b Merge pull request #36 from rokvintar/ls_status_update_fix
Status of limit switches updated independent of movement direction.  Fixes #35
2018-06-26 15:45:59 -05:00
Kevin Peterson 90bb52f3c6 Merge pull request #60 from EuropeanSpallationSource/record-DLYandSTOP-problem
Record: motor record DLY and STOP problem
2018-05-01 09:51:03 -05:00
Kevin Peterson f3d4e0fd1d Merge pull request #83 from mp49/autopower_fix
Fix issue with power being left on when using autoPower option in asy…
2018-04-27 10:42:03 -05:00
sluiter 7493d50bc8 If URIP=Yes and reading RDBL causes LINK error, do not start a new target position move. 2018-04-10 14:30:50 -05:00
sluiter c1c4407644 Replaced invalid LT_EPICSBASE logic with working logic from SSCAN. Since EPICS_VERSION_INT defined in EPICSbase 3.15, added EPICS_PATCH_LEVEL argument. 2018-01-04 14:52:05 -06:00
klang a62c5e4e57 Further gcc errors reported 2017-11-21 16:49:37 -06:00
Matthew Pearson 928f79fc9d Keep the sign information on the MRES and ERES used to calculate the encoder ratio. This fixes issue #82. 2017-09-29 12:01:48 -04:00
Matthew Pearson 8229bb7658 Fix issue with power being left on when using autoPower option in asynMotorController. This could happen if the motor doesn't move because it's already in position, so the poller doesn't detect a move. 2017-09-29 11:36:59 -04:00
rsluiter 220d18fcff Merge pull request #63 from rsluiter/master
Stop motor if URIP is Yes and RDBL read returns an error.
2017-09-13 13:45:04 -05:00
Mitch D'Ewart b201e40ee3 Changed ACCL calculation when VELO == VBAS.
Previously ACCL was only calculated as (VELO-VBAS)/TIME.
This could cause problems for drivers setting ACCL=0.
Now if VELO == VBAS, ACCL = VELO/TIME.
2017-08-07 13:56:07 -07:00
sluiter db5da2f075 Stop motor if URIP is Yes and RDBL read returns an error. 2017-05-19 10:19:36 -05:00
Torsten Bögershausen 38186d00e4 Record: motor record DLY and STOP problem
Fix the problem that the record gets stuck when STOP is
pressed while the record is in MIP_DELAY (and the motor
is standing still, so that there is no record processing).

Currently the MIP_DELAY bits are set to 0, when a STOP is issued.
As the motor already hase stopped, the DMOV field never goes to 1.
There are 2 possible solutions here:
a) STOP wins:
  pmr->dmov = FALSE;
  MARK(M_DMOV);

b) DELAY wins
  Send a STOP to the controller (just to be sure), but wait for the DELAY.

a) may cause probles later, whena new positionioning is done after the STOP
and a new DELAY is triggered.
As the old callback is still active, it may be executed before the new
callback. And the time will be too short.
For this reason go with b)

http://www.aps.anl.gov/epics/tech-talk/2015/msg01786.php
2017-03-09 10:58:31 +01:00
ext-muir_j 02612bad41 Fix motorApp/MotorSrc/README header dash lines
Make motorApp/MotorSrc/README header dash lines match length of header text.
2017-03-08 07:05:27 -06:00
Mark Rivers 38cfa6aedf Minor corrections 2017-03-07 13:41:32 -06:00
timmmooney 5cad105357 ignore SET field, so a database can do it instead 2017-01-12 11:09:55 -06:00
sluiter c970afbfe7 Reverted FLNK change. Except for the condition that DMOV == FALSE, FLNK processing was standard. 2016-09-28 16:07:59 -05:00
Keenan Lang ee4bddd761 Merge pull request #33 from keenanlang/master
Switch asynMotorAxis status_ and statusChanged_ to be protected
2016-08-25 13:41:20 -05:00
Vintar Rok 7ee34a791b Velocity, baseVelocity and acceleration read only when needed. Fix for #37 2016-08-22 09:59:03 +02:00
Vintar Rok ddef3a8754 Status of limit switches updated independent of movement direction. Issue #35 2016-08-18 18:21:03 +02:00
Keenan Lang ebe51c0ebb Reverted wrong change, this should get it back to what I wanted it to be. 2016-07-25 14:42:51 -05:00
Keenan Lang 40816ddc65 Revert "Switched motor status and statusChanged to be protected instead of private."
This reverts commit 36ff229c44b8273cd7c4967a13eb64a24f73d37d.
2016-07-25 14:38:38 -05:00
Keenan Lang 4494eb14be Switched motor status and statusChanged to be protected instead of private. 2016-07-25 14:32:44 -05:00
sluiter d52fe5ee2e Changed jog error checks from dial to user limits. 2016-02-19 11:14:53 -06:00
Torsten Bögershausen 532afdc5a0 Remove all lines with svn keywords
They have no meaning in Git, are not updated and may cause unwanted diffs when
otherwise nothing is changed in a file
2015-11-23 08:23:12 +01:00
prjemian 204515c143 Introduce end-of-line normalization 2015-10-16 12:31:42 -05:00
Ron Sluiter 82eb77fa19 Bug introduced with -r 19129; change made to eliminate call to maybeRetry() removed DMOV check. Restored DMOV check. 2015-07-30 16:56:08 +00:00
Ron Sluiter 3090983c31 Bug fix for target position (VAL/DVAL/RVAL) initialization error when the motor record is configured to do retries. 2015-07-29 15:50:23 +00:00
timmmooney ac900b9061 Make syncTargetPosition() correctly handle URIP=True 2015-07-28 17:15:06 +00:00
MarkRivers 102f74b584 Changed resolution, offset and direction parameters from being profile move parameters to being general parameters that any driver can have access to 2015-03-21 21:22:24 +00:00
MarkRivers 3188c16af6 Fixed typo in comment 2015-03-21 18:24:10 +00:00
Ron Sluiter 30d47b772d - UEIP can only be set true if the device/driver has set the MSTA EA_PRESENT indicator true.
- UEIP and URIP are mutually exclusive.
- RDBL sets RRBV rather than DRBV.
2015-03-13 20:29:07 +00:00
mp49 36dfab4a78 MotorSrc: add parameters to asynMotorController to deal with automatic amplifier control via setClosedLoop. The amplifier enable is done in the writeFloat64 function with a configurable delay, and the disable is implemented in the poller function in asynMotorController. Added utilty functions to asynMotorAxis. Also add a parameter to use in the derived classes for post move delays. An example of this has been implemented in the motorSimDriver.cpp. Add example database for automatic amplifier control. 2015-03-09 20:19:53 +00:00
Ron Sluiter 606957579d Fixed error reported by Alexander Söderqvist (Cosylab) when position command is to the same position that it is currently located, FLNK not processed. 2015-03-06 18:26:55 +00:00
Ron Sluiter 0ef39053aa - Fix for excessive FLNK processing reported by Alexander Söderqvist (Cosylab). Modified so that recGblFwdLink() is only called on a False to True transition of DMOV.
- Incremented VERSION # to 6.10.
- Updated comments.
2015-02-25 21:07:43 +00:00
Ron Sluiter 0054f45b32 Removed postProcess flag (pp) from LOAD_POS. Fixes bug where target positions were not updating.
Removed redundant postings of RMP and REP by moving them to device support's motor_update_values() and update_values().
 Fix for LOAD_POS not posting RVAL.
 Reversed order of issuing SET_VEL_BASE and SET_VELOCITY commands. Fixes MAXv command errors.
2014-09-11 15:37:22 +00:00
Ron Sluiter 95819d8a2a RMP and REP were being posted with same value. Moved CA posting of changes to the RMP, REP and RVEL fields from motor record to update_values(). 2014-09-11 15:28:26 +00:00
mp49 ea2616382d devMotorAsyn: always do SET_ENC_RATIO at the beginning of the init_controller function. This fixes an issue that was causing set position to fail in some cases. 2014-08-05 15:58:40 +00:00
Ron Sluiter 12ce2c552b Clear "forceCallback" before processing motor record (from params->callback) and only if forceCallback is ON.
(Fixes motor record left in the moving state (DMOV=0) after limit switch error reported by Andy Foster.)
2014-06-12 14:00:42 +00:00
Ron Sluiter db27747293 Jens Eden's mod to add EPICS_BYTE_ORDER to the logic of setting {MSB/LSB}_First. 2014-06-02 14:52:23 +00:00
Ron Sluiter 303a9208e3 - Set "stop" field true if driver returns RA_PROBLEM true.
- Increment version to 6.9
2014-05-23 15:39:57 +00:00
MarkRivers d6b6ec6187 Added profileMoveMode 2014-05-22 21:53:45 +00:00
MarkRivers ef90294671 Added profileMoveMode 2014-05-22 21:53:31 +00:00