Machsupport Forum

Mach Discussion => General Mach Discussion => Topic started by: Bob La Londe on March 13, 2013, 08:48:11 PM

Title: Using an Encoder for Jogging
Post by: Bob La Londe on March 13, 2013, 08:48:11 PM
Anybody using an encoder for jogging?  

I am sure somebody must be.  It makes sense.  In my Hurco retrofit I wound up with a couple spare encoders.  One was on the original control console and was used for jogging.  I tested it today with a pair of LEDs and it appears to work.  Now, how would I go about using it to JOG an axis?  I imagine I could wire up one channel like a switch, and then use a separate direction switch, but there must be a more elegant way to do it.  

http://www.youtube.com/watch?v=rhfpo53ajpw
Title: Re: Using an Encoder for Jogging
Post by: Bob La Londe on March 13, 2013, 09:06:40 PM
P.S.  I checked the manual and saw how you connect it and configure it in Mach's ports and pins, but I don't see how you tell Mach which axis you are jogging...  or do you need to configure one for each axis with a selector switch? 
Title: Re: Using an Encoder for Jogging
Post by: Chaoticone on March 13, 2013, 09:23:43 PM
Hit the tab key and the mpg flyout will appear.  There you will set which axis and what mode.  I would set it to single step mode and jog mode to mpg.

Brett
Title: Re: Using an Encoder for Jogging
Post by: Bob La Londe on March 13, 2013, 09:43:44 PM
I think we are not communicating...  If you are using the display screens what is the point of having external controls?

Title: Re: Using an Encoder for Jogging
Post by: Chaoticone on March 13, 2013, 09:49:19 PM
Well, you have to make sure it is the right mode to be able to use the MPG.  MPG only works in mpg mode.

Brett
Title: Re: Using an Encoder for Jogging
Post by: Bob La Londe on March 13, 2013, 10:02:57 PM
Are you saying the only way to use an MPG is to open the flyout screen and manually select the axis on the screen?  That doesn't make any sense at all.  You may need to set MPG mode, but why do so many pendants have selectors then?  Seems like a waste of a perfectly good switch to just put it on there for appearance.   





Title: Re: Using an Encoder for Jogging
Post by: Chaoticone on March 13, 2013, 10:13:35 PM
The pendants with selectors.................. what are they selecting?


Brett
Title: Re: Using an Encoder for Jogging
Post by: HimyKabibble on March 13, 2013, 10:28:19 PM
There are OEM codes for selecting which axis the MPG controls.  You'd need to have switches, and a macropump, brain or plug-in to issue the OEM code at the proper time.  If you search the archives, back in about '08 or so I posted macropump code that implemented full pendant functionality - several jog modes on all axes, Run, Stop, Pause, Rewind, and many other things.  Search on my name, and VistaCNC or iMachPro.

Regards,
Ray L.
Title: Re: Using an Encoder for Jogging
Post by: Bob La Londe on March 14, 2013, 01:53:29 AM
Got it.  Basically you need to have a smart board that will run small macros and send keyboard scan codes.

Well, if I keep this machine Mach when I finish it I won't waste another second with the MPG idea then.  I'll just throw in an arcade joy stick and a couple fire buttons for Z. 
Title: Re: Using an Encoder for Jogging
Post by: HimyKabibble on March 14, 2013, 02:16:19 AM
Got it.  Basically you need to have a smart board that will run small macros and send keyboard scan codes.

Well, if I keep this machine Mach when I finish it I won't waste another second with the MPG idea then.  I'll just throw in an arcade joy stick and a couple fire buttons for Z. 

No, I don't think you got it.  All you need is a Mach3 macro.

Regards,
Ray L.
Title: Re: Using an Encoder for Jogging
Post by: Bob La Londe on March 14, 2013, 02:27:08 AM
And you activate that macro how? 

"You'd need to have switches, and a macropump, brain or plug-in to issue the OEM code at the proper time"

I just wanted to be able to use the encoder I already had as an MPG, but I didn't (as stated) see any real use for it if you have to open the fly out screen and select on screen anyway.  Might as well just create a better looking big button jog screen instead.  (which I intened to do anyway since this machine is getting an 800 x 600 resolution 12" touch screen.) 

Switches I have.  I have lots and lots and lots of swqitches.  Just the switches I took out of the original console for the mill are enough for two or three consoles with a cleaner setup. 

In Mach setup I see where you can use an input to jog an access.  It takes two per axiis which uses up your inputs pretty darn fast.  Better have two ports or a smooth stepper which has an extra set of inputs assigned to a third port. 






Title: Re: Using an Encoder for Jogging
Post by: HimyKabibble on March 14, 2013, 02:32:34 AM
A macropump is a macro that is started automatically when Mach3 starts up, and runs as long as Mach3 is running.  Look at the code I referred you to.  It shows how to implement a full pendant, with no "smarts" in the hardware at all - just switches and the MPG.

Regards,
Ray L.
Title: Re: Using an Encoder for Jogging
Post by: Hood on March 14, 2013, 03:56:13 AM
I use rotary switches on my panels to select the axis and another to select the MPG jog mode (Velocity or Multistep with step size).
The axis selection doesnt need anything other than you set the inputs as OEM triggers then tell Mach the OEM codes for these triggers, for the mode/step size  then you need a brain or macropump.
Hood