[How do I?] Mach3-turn Rpm, Index Sensor. Optical/proximity...

countryguy

Active User
Registered
Joined
May 7, 2014
Messages
776
I found the note below from Jumps4 when searching around on my issue. Maybe someone can confirm if the Mach3 version for RPM is real?

Issue: GekoG540. I have a regular ol' Opto Switch currently installed w/ reflective tape on the lathe pully. This setup also requires yet another 5v power supply. The design is setup to put the signal into pin 1 of the G540. It does not seem to be working. (Checking on my OScope). Before I go and mess with an Opto setup, Does anyone have a preference? Opto's -vs- Proximity's rated?

I read about how slow opto's are and on the flip side, the proximity's are rated in how fast they can run?
Q1) Is there anything in all this for a simple MAch3 turn setup? No need for overkill, but we would like to be more accurate than less and none of these seem all that expensive.

Q2) I read the G540 inputs are internally pulled to +12V and trigger as edge low as an input? But I am still just picking notes here and there off forums. Do we have some specifics about the G540 inputs and are folks using them as Vcc for the opto-transistor switch? Someone have something elegant for a pulse here off the pulley?

The setup that came w/ my unit has: 1- 220Ohm resister on the Vcc side of the emitter diode. On the transistor (pulse out) they had emitter to ground and collector to Pin 1 on the Gecko.
anyway- Before I go change this up and even bother with it.... What's out there as a quick hit, bolt and go. For 5-10 bucks I just do not have the time to play with so many projects going on.

Some sample optek circuits. ( I have a few optek sensors I bought to do the Mill spindle so I can experiment). Here are the 2 designs - common collector and common emitter outputs. Thought I would pass on the info. It's a good PDF for simply photo on/off stuff. :)
http://optekinc.com/pdf/app bulletin 213-opto assemblies.pdf

Anyway, Thanks as always- time to learn the lathe and get into turning!

From Jumps4: Mach3 version specific for RPM and turn to do threads:
in mach3 turn threading can only be done on a breakout board using a parallel port as far as I know. a uc100 usb will not work and I'm not sure any other usb or ethernet cards thread.
mach3 needs to be an older version the latest version does not work ( I'll try to see what version I'm running and send it to you )
pins 10,11,12,13 and 15 are input pins on the breakout board, use what ever one your not using for homing and limit swiches that is left. and on the configuration input screen set that breakout board pin number as the "index"
you can only use one pulse per revolution.
here is a good mach3 pdf to help you out ( http://www.machsupport.com/wp-content/uploads/2013/02/Mach3_Threading.pdf )
threading works best a low speed in mach3 usually not above 150
other people have other results but mach3 turn has never worked correctly for threading and it has required the writing of mach4 to try to resolve the problems. but dont rush out and buy mach4 i'm not sure they have it working yet either . I read their yahoo group daily and see nothing about threading on the lathe yet.
the longer the thread is and the greater the pitch the greater the chance of mach3 making a mistake, at this point i'm having good results at 3 inches of threads at 8 threads per inch turning 100 rpm.
shield all your input wiring, ground the shield only on one end at the controller.
once you have all this working then I would try connecting it to your pfd
trying to do them both at the same time may cause you more problems resolving issues.
hope that helps
Steve
 
Some really good info here:
http://www.cnczone.com/forums/gecko...0-inductive-proximity-switches-one-input.html

The plan; Since I already have all the parts laying around. (see... I'm learning! never throw anything away... Keep everything right Jim! :) lately, more time building and upgrading than making. That ratio needs a little work of late but I am learning a TON!

from the Optec guide: "When fast switch response times are needed or direct TTL compatibility is required, consider the addition of a buffer as shown in figures 3 through 6." (see image #3 in link above). I'll just do that for now I guess.

Still open to any/all comments on optical vs the proximity stuff. tis a new area for me.
 
Educate me here. Does Mach3 use spindle RPM for threading or is it using spindle position / scaled pulse input? It would seem difficult to sync the spindle with the leadscrew without an encoder, but maybe I'm making it too complicated.

If it were me, a prox sensor reading the spindle gear teeth would seem to be the best. Most prox sensors have an operating frequency of 3 to 5 kHz, and a 10-30 V operating voltage. As long as you keep the lathe below about 15,000 RPM you should be good:grin:
 
Educate me here. Does Mach3 use spindle RPM for threading or is it using spindle position / scaled pulse input? It would seem difficult to sync the spindle with the leadscrew without an encoder, but maybe I'm making it too complicated.

If it were me, a prox sensor reading the spindle gear teeth would seem to be the best. Most prox sensors have an operating frequency of 3 to 5 kHz, and a 10-30 V operating voltage. As long as you keep the lathe below about 15,000 RPM you should be good:grin:
Mach3 uses a single input pulse to locate the spindle orientation. So far as I know you can not use multiple pulses/spindle rev such as a proxy switch on the gear teeth. That would be too convenient, lol. So in essence It has a single reference point that tells mach when to start the threading movement. It also uses that for the RPM display. Sucks if you ever wanted to do double lead threads! My solution was to install an optical switch directly onto the spindle and read that. You could easily pop a hole in one of your gears and use a photogate like I have so long as it's a 1:1 ratio with the spindle rotation.
IMAG0640_zpsum8dta0w.jpg

Also, for what it's worth, I've never had a problem threading with this set-up and the latest version of Mack (.66 i think). I even had it running on a USB smoothstepper with no problem (with threading anyways). I'll go home and check what version of mach I currently have installed.
 
TY very much CS. looking forward to getting back home from my trip and setting up!
 
OK... 4:45am and I was soldering this morning. whoot!
Index pulse to a gecko G540 and MAch3 actually showing RPMs is installed and operational.
Some pics and notes:
The Optek sensor used is here: http://optekinc.com/datasheets/OPB745WZ.pdf
The circuit used is here: See my image below w/ noted G540 connetions and 15VDC hook ups.
http://optekinc.com/pdf/app bulletin 213-opto assemblies.pdf
The 2N3904 transistor page is here: https://www.sparkfun.com/datasheets/Components/2N3904.pdf


Notes:
  • For R2 - The use of a small pot (potentiometer) 50K or 100K even allows you to trim out the setup.
  • how to trim: Shine the phototransitor onto your reflective material. Connect you voltmeter to VOut and GND. Adjust R2 up or down in Ohms to set the VOut signal to a lower value. Trim it from 1VDc down to a few hundred millivolts or so.
  • With my unit, readings were: Off the reflective tape =15Vdc. On the tape: under 300mv.
  • Example: with a 20K R2 setting, my setup would pulse from 15Vdc to 7VDc. Still not enough to signal a "LOW" on the g540.
  • Setting R2 to 36K put the signal down to 300mv (millivolts) and my Mach3/index pulse light then would show up.
  • Why does this matter? Well, my 12VDC small transformer output 16.5 VDC. these things are all over the map and I did not wish to find the resistor calc'd on 12Vdc did not work w/ 16VDc. you could install a 12V regulator. Foe me, just easier to trim w/ R2.
  • R3 is a pot on mine since you might not find the 50Kohm 1/4 wattt? RadioShack did not have it. They did have the small 100K pots for a buck-something. Easy!
I ran the lathe up to 110% on the VFD. The waveform on my HEath-Scope showed no skew or rise time lag. The pic is over 1000rpm on the lathe pully. It seems to fast enough for my needs!

Of course, it's all new and I'm not sure how it'll all work out for threading.. :) But at least I got it done today.

Tomorrow, VFD 10V hookups to the G540 and Mach3. Mach 3 will run the VFD next. I have the hitachi WJ something. 300 I think.

G540-index-RPM.jpg index-Sweep.jpg IMG_0697.JPG
 
Back
Top