Machsupport Forum

Mach Discussion => General Mach Discussion => Topic started by: Vaklin on October 22, 2009, 12:13:37 PM

Title: HOLD machine via LPT pin?
Post by: Vaklin on October 22, 2009, 12:13:37 PM
Hi!
Tried to do search, but many possibilities to write the question gives none results.

So, in my design, tool is not always ready to do it's job. I know when it is ready or not and I have a swtich output (OC, relay doesn't matter in this case). How I can hold the machine in exactly current position until the tool be ready? I mean, not before next line, just right now. This should be done via input LPT pin. eStop doesn't suits of course.

Something ready for use?
Title: Re: HOLD machine via LPT pin?
Post by: Hood on October 22, 2009, 02:48:53 PM
If your axis are in motion at the time then your only option is to feedhold which you can do via an input using an OEM trigger.
Hood
Title: Re: HOLD machine via LPT pin?
Post by: Konrad K on October 22, 2009, 03:22:58 PM
Good afternoon,

in my experience, using the safety lockout should work fine. This input is normally used to stop the machine immediately if an external guard is triggered, and also inhibits re-start. (Of course, it is done by software, and thus not as reliable as an E-Stop, but works very well)


To enable the safety lockout, tick "program safety lockout " in "General Config".  (bottem left corner of the menu)
Also assign your input pin to "Input #1".


Have fun ;-)
Konrad
Title: Re: HOLD machine via LPT pin?
Post by: Hood on October 22, 2009, 03:26:50 PM

in my experience, using the safety lockout should work fine.


That will lose position if an axis is in motion in motion.

Hood
Title: Re: HOLD machine via LPT pin?
Post by: Vaklin on October 22, 2009, 03:29:46 PM
Thank you Konrad. This should do the job. Tomorrow will try it and write a report.
Software stop is enough if works as described. The tool will be "almost" ready for a small period of time until motion stops.


----

Oppps. Losing position is not good. Anyway, tomorrow will try and will ask about OEM trgiger how to if is necessary.
Title: Re: HOLD machine via LPT pin?
Post by: Hood on October 22, 2009, 03:34:04 PM
Can you tell us a bit more about the tool in the respect of why and how it becomes "not ready"

Hood
Title: Re: HOLD machine via LPT pin?
Post by: Konrad K on October 22, 2009, 03:40:02 PM
Thanks Hood.
It's useful to learn that it works in my case, but not in all cases...


(I was writing about experience... In some cases, knowledge is actually better than experience ;-) )

Konrad
Title: Re: HOLD machine via LPT pin?
Post by: Hood on October 22, 2009, 03:45:15 PM
I may be wrong, often am ;)

On My Lathe I use that as an error signal input from the servo drives so it will E-Stop at the same time due to that reason but if I did not have it set up as such it would possibly do as yours does. Do your motors decelerate to a stop and the DROs show that deceleration?

Hood
Title: Re: HOLD machine via LPT pin?
Post by: Vaklin on October 22, 2009, 03:55:12 PM
Tool is profile molded hot wire, laser or something similar, which may be ready or not ready in exact time. If this is laser, only happens not cut or bad cut. Should revert the program, second time in the same way, worst cut and more and more. If this is molded hot wire and from some case it isn't enough "hot" the shape will be deformed and all next process will be for nothing. Material will be for garbage too.

With another words. Any pulse which comes from the mach3 to the drivers should be send after checking the tool situation. Situation is self recovered, so just is enough to await permission to move.

And one more modification in my post. Not necessary to decelerate the motors. In any case between two pulses software has no care about next step to limit current or something like this. I'm talking about steppers. So, inertia after the step will be cut from the stepper drivers. They are enabled and all is fine. Just to await some time and go again. Now, acceleration after this hold situation is discussable, but we talking about a level few higher which mach3 covers...
Title: Re: HOLD machine via LPT pin?
Post by: Konrad K on October 22, 2009, 04:12:04 PM
Do your motors decelerate to a stop and the DROs show that deceleration?

Hood

This would have to be checked on the machine... Can report on Saturday, or Sunday. But I can state that I use a stepper motor drive and it doesn't lose steps at all when opening the protective window and the machine is forced to stop that way. - In E-Stop it definitely does.

But now, I am courious. Let's wait the weekend. :-)

Konrad

Title: Re: HOLD machine via LPT pin?
Post by: Konrad K on October 22, 2009, 04:19:11 PM
If this is molded hot wire and from some case it isn't enough "hot" the shape will be deformed and all next process will be for nothing.


... sounds like you need to modulate the feedrate by tool condition.

High temperature -> High feedrate
Low temperature -> low feedrate.

Wasn't there a possibility to do a "feed per revolution" mode? (Hood?   >:D )
If so, you just needed to transform the hot wire temperature to spindle index pulses some way.   ;D

Konrad
Title: Re: HOLD machine via LPT pin?
Post by: Hood on October 22, 2009, 04:23:01 PM
G95 does feed per rev.

Will be very interested to see what your tests reveal, can see a few applications where it would be handy for me if it can do that :)

Hood
Title: Re: HOLD machine via LPT pin?
Post by: Hood on October 22, 2009, 04:45:51 PM
Just asked Art and he has said it halts immediately without deceleration.
Hood
Title: Re: HOLD machine via LPT pin?
Post by: Hood on October 22, 2009, 04:50:40 PM
 Vaklin
You could possibly do this in a similar way  as I do with the FRO pot, what I have is if the pot is put to zero a Brain will feedhold then when the pot is again increased the start button will be pressed via the brain and the motion will again start.
You could use an input instead of the pot, you need to look at other things in the Brain as well such as the FeedHold LED, this is so that it will only press the start if the feedhold LED is currently active thus avoiding false triggering.
Hood
Title: Re: HOLD machine via LPT pin?
Post by: Vaklin on October 22, 2009, 05:01:05 PM
Konrad, I'm so happy you touched my sick theme from few months. Here is no spindle at all. But... almost all adequate CAM software hearing mill knows rotate tool. Especially checked SolidCAM. Next step to take a look to mastercam. In any case I'll cheat the software, but this is slow solution.

The described behavior has a lot of application. BTW if the stepper drivers are smart and checks the current in windings they will know is the step actually goes or not. Hold the step with the trigger until it done (some timeout, possible to done never) logic AND from all steppers and HOLD until all rest steps are present will prepare closed loop steppers. ;) For servos situation is bit different, but if one good guy has understood what I have talked, soon servo drivers will have two different pulse dependable closed loop controls. Unfortunately, for now I can't explain more about this feature, because I don't know will he does this or not.


----

Hood, no buttons. This will be absolutely automatic solution. How often and how many times will present the "not ready" condition knows no one. Stupid is to stay near the machine to wait if this present or not. Also, temperature depends from what part of the tool is in use right now. High temperature will compensate with low heating PWM, low one ... only with no movement until it normalized. Temperature is provisional in this explanation. Every condition which you want and can resolve is suitable.


----

Good is to know for missing deceleration. Important is to know after recovering machine starts on the same place with the rest of steps to done program line.
Title: Re: HOLD machine via LPT pin?
Post by: Hood on October 22, 2009, 05:05:25 PM
I was meaning an input from the tool to signal it was ready rather than just a button for the operator, some form of thermocouple possibly?

Hood
Title: Re: HOLD machine via LPT pin?
Post by: Vaklin on October 22, 2009, 06:07:04 PM
How to measure is another question. In any case the signal is binary. Ready/ NOT Ready. Doesn't matter what this means relative to exact tool, motor or something more. Enough is to await until condition is normalized. Anyone can use it as wants. Just should to test, is solution explained by Konrad covers this. This feature can be used to hold the machine on the night with switch key too. End of working time, turn the key to hold, go to the home. On the next morning just turn the key to GO and go ahead :)

Funny and usable ...
Title: Re: HOLD machine via LPT pin?
Post by: Vaklin on October 23, 2009, 08:36:08 AM
Just tested Konrad's solution. Works pretty fine! Stops after complete the step, next step pulse comes after recovery, no fluctuation...
Very useable for servo drivers with "not in place yet" output which are driving big tables... And for my strange needs is useable too.

10X Konrad!
Title: Re: HOLD machine via LPT pin?
Post by: Hood on October 23, 2009, 10:36:14 AM
Will be excellent if it is the case and there is no loss of position, only problem I have in my test so far is it screws up the SmoothStepper :(

Hood
Title: Re: HOLD machine via LPT pin?
Post by: Vaklin on October 23, 2009, 12:32:21 PM
Ask the producer... Don't tell me the answer. I know. Every producer does THE BEST, doesn't change anything because of "support", because of lot of PCB's sold and ready for sale .... because they are doing for money :(
But, doesn't matter. In any case ask the producer... BTW, to be objective in your questions, can you add somewhere a big size photo of the solder and component side of the PCB. I want to take a look about architecture. 169 eur without delivery just to take a look is out of mind. After that we can discuss for what exactly you have paid and how to do it usable...
Title: Re: HOLD machine via LPT pin?
Post by: Vaklin on October 23, 2009, 12:36:51 PM
I forget to try, will ask. I hope, in HOLD position, pins state changed by modal codes don't reverse, isn't it? Not fatal, but better is to stay in place...
Title: Re: HOLD machine via LPT pin?
Post by: Hood on October 23, 2009, 01:03:53 PM
Sorry I dont what you are either saying or asking.

Hood
Title: Re: HOLD machine via LPT pin?
Post by: Vaklin on October 23, 2009, 01:17:29 PM
Mxx somewhere in the program changes output state of pin X from LOW to HIGH. I'm holding the Mach3 via LPT. What will happens with the pin X output level? Will go back to LOW or will stay HIGH as I ordered with Mxx?

Modal code for "coolant" for example, but this is just for example...
Title: Re: HOLD machine via LPT pin?
Post by: Konrad K on October 25, 2009, 06:12:31 PM
Hi Hood,

I checked... No surprise for you: of course NO acceleration and decelaration when opening the window.   :(

Frankly speaking: After Art said this, I didn't even believe that there woud be proper start or stop...


Konrad
Title: Re: HOLD machine via LPT pin?
Post by: Hood on October 25, 2009, 06:19:15 PM
Konrad, thanks for testing it out, would have been a handy thing if it did work.

Hood
Title: resume the gcode
Post by: cmcmanager on December 02, 2009, 10:06:04 AM
Hi all!

Can you tell me about the resume of  last situation of g-code ,after user close the mach3 ?
By the way when we need to work off ,how can we  save the current gcode so user resume it(the next line of gcode) at last day!?

thanks.
mostafa