[Home]Jog-While-Paused

LinuxCNCKnowledgeBase | RecentChanges | PageIndex | Preferences | LinuxCNC.org

Difference (from prior major revision) (minor diff, author diff)

Removed: 1d0


Changed: 8,11c7,8
* enable jog moves during auto pause (in coordinated mode, that is
axes, not joints)
* un-pausing will return to the position where 'pause' was hit, then
continue the auto run
* enable jog moves during auto pause (in coordinated mode, that is axes, not joints)
* un-pausing will return to the position where 'pause' was hit, then continue the auto run

Changed: 17,18c14
* provide the primitives to record a jog history during pause, and
replay it for return (could be done in HAL or Python)
* provide the primitives to record a jog history during pause, and replay it for return (could be done in HAL or Python)

Changed: 27,40c23,25
* a complete 'jog solution' including keyboard jog, MPG support, your
daughter's kinect etc. All it does is provide the HAL hooks to provide
these features, but it doesnt do so by itself. This is experimental,
and needs some shakeout. Until then, some HAL plumbing is
needed, it isnt yet clear to me how jogging in coordinated mode fits
in the overall picture.

* touchoff during pause. This is a fundamental restriction in current linuxcnc
and forcing the issue would have some serious side effects.

* MDI during pause. As far as the rest of linuxcnc is concerned,
jog-while-paused is not visible - it all looks like a loooong pause.
This modification assures that at resume happens at the point where
where 'pause' was hit.
* a complete 'jog solution' including keyboard jog, MPG support, your daughter's kinect etc. All it does is provide the HAL hooks to provide these features, but it doesnt do so by itself. This is experimental, and needs some shakeout. Until then, some HAL plumbing is needed, it isnt yet clear to me how jogging in coordinated mode fits in the overall picture.

* touchoff during pause. This is a fundamental restriction in current linuxcnc and forcing the issue would have some serious side effects.

Changed: 42,43c27,29
* jog moves during spindle-synced moves. These changes rely on
the current 'pause' capabilities.
* MDI during pause. As far as the rest of linuxcnc is concerned, jog-while-paused is not visible - it all looks like a loooong pause. This modification assures that at resume happens at the point where where 'pause' was hit.

* jog moves during spindle-synced moves. These changes rely on the current 'pause' capabilities.

Changed: 49c35,37
http://git.mah.priv.at/gitweb/emc2-dev.git/shortlog/refs/heads/jog-while-paused-preview1

http://git.mah.priv.at/gitweb?p=emc2-dev.git;a=shortlog;h=refs/heads/jog-while-paused-preview2-rebase-onto-master


Added: 55a44,46

set feed to some realistic value in the glade panel


Added: 56a48


Added: 57a50


Added: 58a52


Added: 59a54


Changed: 77,78c72
** 4 = jogging - currently executing a move due to a valid offset
*applied
** 4 = jogging - currently executing a move due to a valid offset applied

Changed: 81,82c75
* motion.pause-at-motion, s32: the motion type at which the pause
request was honored.
* motion.pause-at-motion, s32: the motion type at which the pause request was honored.

Changed: 90,94c83,84
* motion.pause-offset-in-range: bit - the value of the pause-offset-*
pins would result in a move not violating machine
*constraints. Updated during states 1 and 2.
* motion.in-position: existing motion pin signifying the end of a
*motion has been reached and no further motions are pending.
* motion.pause-offset-in-range: bit - the value of the pause-offset-* pins would result in a move not violating machineconstraints. Updated during states 1 and 2.
* motion.in-position: existing motion pin signifying the end of a coordinated motion has been reached and no further motions are pending.

Changed: 107,113c97,99
* the Axis 'Pause' button causes transition to the paused state at
next chance (EMC_TASK_PLAN_PAUSE NML message).
* The Axis 'Resume from pause' (clicking pause button in paused state)
causes transition to the running state (EMC_TASK_PLAN_RESUME NML message).
* The Axis 'Step' button resumes the pause for the current motion if
paused in the initial pause position. If not in the initial pause
position, it triggers a return move. (EMC_TASK_PLAN_STEP NML message).
* the Axis 'Pause' button causes transition to the paused state at next chance (EMC_TASK_PLAN_PAUSE NML message).
* The Axis 'Resume from pause' (clicking pause button in paused state) causes transition to the running state (EMC_TASK_PLAN_RESUME NML message).
* The Axis 'Step' button resumes the pause for the current motion if paused in the initial pause position. If not in the initial pause position, it triggers a return move. (EMC_TASK_PLAN_STEP NML message).

Changed: 120,130c106,110
*** if pause-offset-in-range is true, enable pause-offset-enable ->
move starts, state changes to 4 (jogging)
*** stop current jog: disable pause-offset-enable, curent jog move in
progress stops immediately.
** end of jog move reached: keep pause-offset-enable applied until
motion.in-position becomes true.
** continuous jogging: keep pause-offset-enabled - any change to
pause-offset-* will be honored by a corresponding linear move
immediately.
* for pause, step, resume from HAL use halui.program.pause,
halui.program.resume, halui.program.step
*** if pause-offset-in-range is true, enable pause-offset-enable -> move starts, state changes to 4 (jogging)
*** stop current jog: disable pause-offset-enable, curent jog move inprogress stops immediately.
** end of jog move reached: keep pause-offset-enable applied until motion.in-position becomes true.
** continuous jogging: keep pause-offset-enabled - any change to pause-offset-* will be honored by a corresponding linear move immediately.
* for pause, step, resume from HAL use halui.program.pause, halui.program.resume, halui.program.step

Added: 144a125,129

Deficiencies and surprises




* There's currently no support for spindle, mist, flood handling etc during pause. Some HAL plumbing required for now.
* I dont know how to handle a rotary indexer during jog.


Added: 167a153
--

Added: 168a155
Updated to master on Aug 7,2012; added missing retract.hal file.

Jog-while-pause changes to motion

what it is

An enhancement to the motion pause handling to:

the intent is to provide a stopgap solution to the 'pause, jog away, clean swarf, continue' issue to provide the basis for other scenarios

what it doesnt provide:

How to try it out

Pull

 http://git.mah.priv.at/gitweb?p=emc2-dev.git;a=shortlog;h=refs/heads/jog-while-paused-preview2-rebase-onto-master

and build

 cd configs/sim/axis 
 linuxcnc jog-while-pause9.ini

execute, hit pause somewhere

set feed to some realistic value in the glade panel

press 'pause-offset-enable'

change some offset

press 'pause-offset-enable' again

press 'step' to return to pause point

press 'pause' again to continue

Integration notes

I assume here you want to build a jog-while-paused support component, for instance for an MPG. I use 'IPP' to mean the 'inital pause position', which is the pose where the pause request was honored and state changed from running to paused.

Status pins:

Control pins:

Pause, Resume and Step:

HAL flows:

Python notes:

for recording/replaying jog history: to determine the current pause point, use the linuxcnc module and query linuxcnc.stat.position when state is 1 or 2. Some example supporting code can be found in configs/sim/axis/gladevcp-jwp.py .

Changes in behaviour:

The DRO values for velocity, and distance-to-go are set to zero during a pause, and thereafter reflect velocity and DTG of the jog moves. On resume the velocity and DTG values of the initial paused move are restored.

Deficiencies and surprises

Programming notes

The basic approach is to employ an alternate motion queue - on pause, motion control is switched to the alternate queue, and arbitrary moves can be executed. Switchback to the primary motion queue happens on 'resume'; if the current pose doesnt match where execution was paused, a linear move to the pause point is executed. Then primary motion queue execution continues as before.

WRT pause, the externally significant change is that 'paused' isnt just an emcmotStatus flag anymore, but the state of the pause FSM (see enum pause_state in mot_priv.h). Any state other than 'not paused' is nonzero which is compatible with current task assumptions.

The semantics of 'step' are now such that if paused on the inital pause position, a return move to the initial pause position is executed. That seemed the most logical step to me.

While this implementation relies on the current pause behavior, the underlying mechanism could be used to for more advanced backout strategies, like retracting during a threading move.

--

Updated to master on Aug 7,2012; added missing retract.hal file.


LinuxCNCKnowledgeBase | RecentChanges | PageIndex | Preferences | LinuxCNC.org
This page is read-only. Follow the BasicSteps to edit pages. | View other revisions
Last edited April 7, 2014 2:21 am by MichaelHaberler (diff)
Search:
Published under a Creative Commons License