I was working on the steppermotor record a little at CEBAF and
found a number of problems - most of them related to using the
IALG field to move to one of the limits on initialization. There
are also problems with PASSIVE motors with no retry count and
monitors of the mcw and mccw fields. The fixes are below. Please
review and put into 3.12.2.
Also - it should be understood that the OMS motors determine that
they have finished moving when the position is the same on 3
subsequent reads (100 milliseconds) - so if the motor is moving
very slowly - VELO is too small - the readback RBV for the motor will
not track the desired value VAL.
****************************************************************
if you initialize to a limit - the overshoot will stop the motor
****************************************************************
--- in the source it reads --
/* stop motor on overshoot */
if (psm->movn){
--- should be ----
/* stop motor on overshoot */
if (psm->movn && (psm->init == 1)){
****************************************************************
****************************************************************
if you initialize to a limit and the retry count is not 0 ---
****************************************************************
--just after the overshoot check at the same level of indentation
if(!psm->movn) {
--should be:
if(!psm->movn && (psm->init == 1)) {
****************************************************************
****************************************************************
if you are using init to a limit in IALG - the move is too big
****************************************************************
status = (*pdest->sm_command)(psm,SM_MOVE,0xfffffff,0);
---and
status = (*pdest->sm_command)(psm,SM_MOVE,-0xfffffff,0);
---should be
status = (*pdest->sm_command)(psm,SM_MOVE,0xffffff,0);
---and
status = (*pdest->sm_command)(psm,SM_MOVE,-0xffffff,0);
-----(one less f)
***************************************************************
***************************************************************
if you are using the fields MCW and MCCW to monitor limits -
they are not being posted.....
***************************************************************
---after
db_post_events(psm,&psm->cw,DBE_VALUE|DBE_LOG);
---and
db_post_events(psm,&psm->ccw,DBE_VALUE|DBE_LOG);
---add
db_post_events(psm,&psm->mcw,DBE_VALUE|DBE_LOG);
---and
db_post_events(psm,&psm->mccw,DBE_VALUE|DBE_LOG);
--- you also need to put these statements in { ... }
*****************************************************************
*****************************************************************
a passive motor record being set by a slider may not get processed
again when the final value is put in the record - occurs if the
record is being processed while new values are being put in the
record as well.
*********************************************************************
--- in the retry portion of the code
if (psm->rcnt < psm->rtry){
--- should be
if ((psm->rcnt < psm->rtry) || (psm->lval != psm->val)){
psm->lval = psm->val;
**********************************************************************
End of returned message
----- End Included Message -----
- Navigate by Date:
- Prev:
Re: mvme162 and epics watson
- Next:
InterViews for Solaris Rozelle Wright
- Index:
1994
<1995>
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
- Navigate by Thread:
- Prev:
EPICS on mvme162 Patavalis Nikos
- Next:
InterViews for Solaris Rozelle Wright
- Index:
1994
<1995>
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
|