EPICS Controls Argonne National Laboratory

Experimental Physics and
Industrial Control System

1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  <20082009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024  Index 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  <20082009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
<== Date ==> <== Thread ==>

Subject: Re: Problem with soft motor record
From: Tim Mooney <[email protected]>
To: Ron Sluiter <[email protected]>
Cc: [email protected]
Date: Fri, 22 Feb 2008 16:23:14 -0600


Ron Sluiter wrote:
Hello Harvey,

Two issues.

First, I recommend setting the LOCK field to "Yes" for all multi-axis
"soft" motor applications. From the motorRecord.html <http://www.aps.anl.gov/bcda/synApps/motor/R6-3/motorRecord.html#Fields_misc> document;


After a "hard" motor initiated move, Soft Channel device support automatically synchronizes a "soft" motor's target position with a "hard" motor's readback position. Soft Channel device support detects that the "hard" motor has initiated the move when it sees the PV pointed to by DINP go false, while the "soft" record's DMOV is true. Automatic synchronization is undesirable in a multi-axis application. Hence, setting the LOCK field to "Yes" disables this automatic synchronization.
Second, in the gap_softmotor.db the GapMotor has this
 field(DINP, "$(device):GapGetTransform.F NPP MS").

The GapGetTransform record of has this,
  field(CLCF, "D && E")

Simply AND'ing the DMOV's of all the "hard" motors for the "soft" motor's
DMOV Input Link (DINP) is not going to work 100% of the time.

In a two "hard" motor example, if both "hard" motors are sent "new" positions,
with one motor sent to its' current position and the other motor sent to a position
that results in an actual move; AND'ing the DMOV's may result in two
false to true transition, rather than one.


This is because telling a motor to go to its' current position always results in
a false to true transition of DMOV, but it may or may not happen coincident
with the other motor's DMOV transition.


I can't recommend any way of fixing this in a database.  I know other's
have solutions that have worked for them.  Hopefully, they will respond.

We've fixed this for a two-motor system as follows: 1) create a "gate" PV 2) the record that writes to the hard motors sets the gate PV to "open" before writing to them 3) motors are always written to in the following order: motor1, then motor2 4) the gate gets closed when motor2.DMOV goes to 1. (motor1 cannot cause the gate to close.) 5) The two-motor system is done when gate==closed && motor1.DMOV && motor2.DMOV


Hope this helps,
Ron

Rarback, Harvey wrote:
Motor record gurus,

I have encountered a number of problems with my use of the soft motor record. I am using motor driver version 6.22 (with SLAC modifications for RTEMS) on EPICS base 3.14.8.2. The hardware is an OMS MAXv-8000 motor controller along with Kramert 505F SSI encoder readout.

First the part that works pretty well:

One soft motor "RowPhaseMotor" (see attached epu_softmotor.db) that moves four real EPU girder motors (see epu_realmotors.db). We have no encoders for these temporary motors and so use motor pulses as our position readback. The soft motor links RDBL, DINP, and STOO seem to behave as documented with the exception that "the value specified by DINP is used to set the DONE bit in the MSTA field; which in turn sets the DMOV field". The DONE bit appears to always be set correctly, but the DMOV field sometimes remains at zero after the move.

Now the problematic part:

One soft motor "GapMotor" (see gap_softmotor.db) that moves two real undulator jaws (see gap_realmotors.db). There are absolute linear encoders on the two jaws and I have set a retry count of two for both motors because of mechanical imperfections and magnetic deflection forces that don't allow reproducible motions. Each jaw motor/encoder combination seems to work ok. When I try to control these jaws with the soft motor, weird non-reproducible things happen:

  - the DONE bit often stays true throughout the soft motor move
  - the DMOV field stays false during and after the move
  - the soft motor will process and move again after both real motor moves are finished
  - sometimes one of the two jaws will start moving without any command.

I've tried various ways to get the done condition to work, but without success. I would appreciate any suggestions.

                                   --Harvey
----
Harvey Rarback                        phone:      (650)926-3963
Stanford Linear Accelerator Center    fax:        (650)926-4100
2575 Sand Hill Road                   home phone: (650)560-9111
Menlo Park, CA 94025
[email protected]             http://ssrl.slac.stanford.edu/~rarback

       "Always tell the truth, that way you don't have to keep track."
                                     Pogo



-- Tim Mooney ([email protected]) (630)252-5417 Beamline Controls & Data Acquisition Group Advanced Photon Source, Argonne National Lab.

References:
Problem with soft motor record Rarback, Harvey
Re: Problem with soft motor record Ron Sluiter

Navigate by Date:
Prev: Re: Problem with soft motor record Ron Sluiter
Next: Re: TTL output with soft IOC on Linux Robert Horrox
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  <20082009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
Navigate by Thread:
Prev: Re: Problem with soft motor record Ron Sluiter
Next: RE: Problem with soft motor record Shepherd, EL (Emma)
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  <20082009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
ANJ, 02 Sep 2010 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·