Machsupport Forum

Mach Discussion => General Mach Discussion => Topic started by: Biermann on April 30, 2011, 08:27:22 PM

Title: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Biermann on April 30, 2011, 08:27:22 PM
After a lot of searching, and much reading, I have found many different opinions and suggestions on the types of sensors/methods used for homing.  I need to outfit a mill and lathe and am looking for the best accuracy and repeatability while maintaining robustness.  Figuring that there will be metal swarf, coolant and oil potentially reaching these sensors.  From what I've read electrical/magnetic switches such as inductive proximity, and hall effect sensors, can shift register due to temperature and electrical interference in the region of a few .001's over the course of a few hours.  On the plus side there are no mechanical part to wear out and it easy to get IP65/67 version's.  On the other hand you have a micro-switch which does not suffer from the previously mentioned climate shifts and electrical interference dilemma, but have mechanical mechanisms that can wear out and fail, that and it's hard to come by waterproof versions cheaply.  

So if you guy's wouldn't mind listing what systems you are using, and/or have tried and scrapped for something better, and what level of accuracy/repeatability you experience.  Is the position shift from some types of sensors only critical if you have to perform manual tool changes over the course of a long cycle, or are using setup plates for repeat parts w/o re-zeroing on the workpiece?  Also, in regards to proximity switches if you use them can you list the model# and the sensing distance.

Which is most accurate and repeatable, and has the least worry of false triggers of the following types of systems:

1) Proximity (inductive)
2) Micro Switch
3) Laser
4) Hall Effect
5) Other...

Thanks.
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Jeff_Birt on April 30, 2011, 11:25:00 PM
No matter what type of sensor or switch you use it will not be super accurate all by itself. For really accurate homing it is best to use a combination of a home sensor/switch and an index pulse on the axis motor itself. The home sensor/switch and the index pulse are seen at the same time the controller considers this 'home'. Since the index pulse is based on the angle of the axis motor itself it is very accurate.

Having said all of that you have to stop and ask yourself if having a very accurate homing sensor is even needed for your method of operation. A home sensor only sets the zero for the machine coordinates, it lets the machine get a bearing on where each axis is physically when you start up. For most operations you bolt a part/fixture to the mill table and then you zero the machine to some feature of the part/fixture (local coordinates), you can even have multiple fixtures and multiple local coordinate systems set up. There will be a relationship between the mechanical and these local coordinate systems (an offset), but since you will likely always zero to the part or fixture each time the accuracy of the home sensor is not important.
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Eugenio7 on July 16, 2012, 06:28:04 AM
I was looking at this homing issues and wanted a simple working solution, I did not care if it was not 100% automatic. The only accurate method seems to need the use of encoders or some sort of sensor on the motor shafts and axis switches. This looks expensive for a small china cnc and I don't have enough inputs anyway.

My solution was to use the MachBlue screen and probe. There is a centering function that allows you to center your tool to a circle. So I just fixed a piece of machined pipe to a corner of my cnc table outside of the usable area, and fixed an arm to the spindle plate to reach this pipe with a 1/8" shank from a broken endmill soldered to it. The pipe has an plug soldered inside midway through so all I have to do is center the shank to this pipe, probe the z axis at this position and set my machine coordinates to zero. You have to jog manually to the pipe so it might be slow, but it is very accurate.

Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Hood on July 16, 2012, 07:22:32 AM
I used to use optical sensons that were within a housing and a flag was held on a sprung rod that stuck out either side of the housing. I originally bought them from a place in the USA but they sold up and as far as I know the people that took over dont do them. They are easy enough to make up and I had made a few for other machines. They were very accurate and I once did tests by repeatedly homing and watching a glass scale DRO and only once or twice out of 100 or so homings (from different distances) did the DRO read other than 0 and even then it was only 0.005mm

I now however use the switch/ encoder index homing as my servo drives are capable of it.

Hood
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: DICKEYBIRD on October 15, 2012, 06:54:33 PM
No matter what type of sensor or switch you use it will not be super accurate all by itself. For really accurate homing it is best to use a combination of a home sensor/switch and an index pulse on the axis motor itself. The home sensor/switch and the index pulse are seen at the same time the controller considers this 'home'. Since the index pulse is based on the angle of the axis motor itself it is very accurate.
I recently stumbled across this powerful statement and was wondering how one accomplishes "an index pulse on the axis motor itself" and if it's possible on a regular stepper motor without a shaft encoder.  I'm intrigued by this concept and would like to learn more.

Anyone have further info on the matter or links?

Thanks!
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Chaoticone on October 15, 2012, 07:12:58 PM
No matter what type of sensor or switch you use it will not be super accurate all by itself. For really accurate homing it is best to use a combination of a home sensor/switch and an index pulse on the axis motor itself. The home sensor/switch and the index pulse are seen at the same time the controller considers this 'home'. Since the index pulse is based on the angle of the axis motor itself it is very accurate.
I recently stumbled across this powerful statement and was wondering how one accomplishes "an index pulse on the axis motor itself" and if it's possible on a regular stepper motor without a shaft encoder.  I'm intrigued by this concept and would like to learn more.

Anyone have further info on the matter or links?

Thanks!

This thread may help explain that and give an alternate idea on "finer homing" by mechanical means.

http://www.machsupport.com/forum/index.php/topic,22610.msg157871.html#msg157871

Brett
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: RICH on October 15, 2012, 08:08:19 PM
Quote
you have to stop and ask yourself if having a very accurate homing sensor is even needed


I don't have any on my machines. If I couldn't get accurately back to a location without switches then switches are not going to help me. Hope that makes some sense .....

RICH
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: BR549 on October 15, 2012, 09:22:46 PM
There are times when accurate homing is usefull and MOST of the time it doesn't mean a thing to the average user. Most of the time only when you are using dedicated fixturing does it come into play.

Just a thought, (;-) TP
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Jeff_Birt on October 15, 2012, 09:49:55 PM
No matter what type of sensor or switch you use it will not be super accurate all by itself. For really accurate homing it is best to use a combination of a home sensor/switch and an index pulse on the axis motor itself. The home sensor/switch and the index pulse are seen at the same time the controller considers this 'home'. Since the index pulse is based on the angle of the axis motor itself it is very accurate.
I recently stumbled across this powerful statement and was wondering how one accomplishes "an index pulse on the axis motor itself" and if it's possible on a regular stepper motor without a shaft encoder.  I'm intrigued by this concept and would like to learn more.

Anyone have further info on the matter or links?

Thanks!

You must have an encoder on the motor for the described homing process to work. As Rich and Terry have said though on a typical machine tool really accurate homing does not mean a whole lot. Think of how you use a mill, you clamp a piece of stock on the table, indicate to the edges of the stock to set your part zero and then start machining. Having a super accurate home has no bearing on where your stock is. If you have a machine set up to run only one part, and if you never crash into the fixturing or otherwise disturb it than you might be able to home and then offset to your fixture. I bet most guys would still indicate to the fixture though to make sure nothing had happened to throw things off.
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: DICKEYBIRD on October 15, 2012, 11:01:47 PM
Thanks very much for the input gents.:)

I'm actually working with a lathe instead of a mill and was hoping to find a way to consistently & very accurately set at least the X-axis zero point so I wouldn't have to use standard methods to indicate to the work.  A known refererence to the spindle centerline would be useful methinks.

What I was thinking was to have a regular mechanical switch to identify the initial rough home point and then have a slotted disc/optical sensor on the ballscrew.  Is it possible to configure Mach to recognize the rough point, slow way down then count a couple turns of the disc and stop/zero at the edge of the slot?  Seems to me that would produce a consistent zero point, no?
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Hood on October 16, 2012, 03:11:46 AM
For me homing has to be accurate, if I run a part one day and want to run the same the next day I want to know I can just place in the soft jaws of the vice and press start and away it goes.
 On a lathe it is especially important for the tool dia, I dont want to have to take a test cut each time I start the lathe, measure the dia and then set the tool offsets. I have a turret and I want to switch on, home and then when I call a tool and tell it to cut a diameter I know it will be there.
I use Index homing but I do it external to Mach as my servo drives support that homing feature. What happens is I send a signal to my drives from Mach, they start homing and look for the home switch input, when they see that input they then search for the index pulse from the encoder and then they stop and set that as home and send a signal to Mach which then sets the machine coordinates.
 There used to be a board that could do similar, it was made by CNC building blocks but sadly Ed no longer makes them. It worked in a similar manner except Mach actually did the homing moves, it was just that the building blocks bob delayed the signal to Mach. Hers how it worked. Mach started homing and saw the switch being activated and reversed the axis, the BOB however would not tell Mach the switch had again closed until it had seen the index pulse of the encode. It would then tell Mach the switch had closed and Mach set the machine coords.
 
As mentioned in my previous  post however if you use optical switches you can also get very accurate homing, that was proven by the tests I did, so if you dont have encoders and drives capable of homing then optos are a very cheap and accurate choice.
Hood
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: RICH on October 16, 2012, 06:41:21 AM
Guess I am a little off topic relative to the original question but if you'll excuse me.

We alluded to the relationship of homing to axis movement and tool postion. You need repeatable
and accurate axis movement and tool position. The turret can provide accurate tool position while other methods leave something to be desired. Each part of the system must be as good as the other.
Perfect homing using switches will be of no value if capable axis movement and tool position are not available.
Thus you'll be right back to manualy doing touch off in many instances.

Said a different way, assuming that homing is spot on, it's what's happening prior to and after homing that
makes or breaks the value of homing automation.

BTW, the turret realy comes into play when coupled with a Cam program providing code for a complex part on the lathe. One of these days i will make one..........

Till then,
RICH

Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Overloaded on October 16, 2012, 07:01:14 AM
Another situation where accurate homing is important.
I set my gang tooled lathe up for a large production run of one particular part using 4 tools.
The machine ran 500+ parts per day for months and was shut down every night.
It was imperative that the operator fired it up, homed it and went right on making parts.
One dimension (thread PD) was critical so it had to home accurately.

I experimented with several brands of micro-switches and found Omron (model ?) to be repeatably accurate to .0001" to .0002" which was close enough.
I much prefer Hood's servo homing and would have used that except this is a stepper based machine.
My next one will used the encoder and servos.
Russ
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: DICKEYBIRD on October 16, 2012, 08:56:34 AM
The machine ran 500+ parts per day for months and was shut down every night.
It was imperative that the operator fired it up, homed it and went right on making parts.
Exactly.  I don't run near that many parts and the operator is always me but having the machine start from the same point is important to me as well.

My other machine, crude as it is, has old style stepper motors with very strong cogging (proper term?) without power.  I guess it's dumb luck but the machine has no motor movement whatsoever when powered down or turned on.  I did a run of 1100 parts over a period of 4 months and the only time I had to reset the zero point is when I screwed up & crashed it.  All I had to do was shut it down properly, close the lid to keep out pesky cats and I knew it'd be right where I left it the next day.

The new machine's more modern steppers turn easily when no power is applied and jump a bit when powered on, hence my desire to have an easy, precise method of zeroing it.  They are double shaft motors so I guess I could rig a mechanical lock on the unused end to lock down before turning the machine off for the day.:D

I was hoping you experts would say "Oh yeah, piece o' cake, put a sensor & slotted disc on the stepper, $2 Radio Shack switch on the carriage, write a simple macro in Mach and Robert's yer Father's brother.";)
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Overloaded on October 16, 2012, 09:26:02 AM
Here's a thought ... a poor mans encoder / index homing.
Simple slotted disc and photo sw. (or cheap enc w/ index) on the back of a stepper. Totally enclosed, all sealed up.
Mach allows jogging while Home switch is active, so .....
Manually jog the axis to within 1 turn of finding the index pulse and then home normally.
It would have increased accuracy resolution due to the screw pitch as well as any belt reduction.
Bit of work involved, but it would be quite accurate.
Just 4 fun,
Russ
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: DICKEYBIRD on October 16, 2012, 10:04:00 AM
Thank's Russ, sounds good!  Should be easy enough even for me.  I'll be experimenting with that down the road a bit.
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Hood on October 16, 2012, 10:22:03 AM
Why not just make up some optos in a sealed box, you will have very accurate homing and wont have to mess about fitting pseudo encoders.
Hood
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: DICKEYBIRD on October 16, 2012, 10:29:42 AM
Why not just make up some optos in a sealed box, you will have very accurate homing and wont have to mess about fitting pseudo encoders.
Hood
I read your description of that earlier in the thread but I must be even more dense than usual today.  (Too much blood in my coffeestream?)  Got any dusty ol' .jpgs lying around somewhere to help edumacate me?
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Hood on October 16, 2012, 10:47:16 AM
Here is a picture of the inside of the original ones I bought from the USA, there is a flag that is attached to the rod and in the pic it is blocking the opto. When the axis reaches one of the ends of travel the rod hits the stop and pushes the flag out and thus the opto is no longer blocked.
These ones are overly complicated as there are actually 2 optos, one for each end of axis when in reality only one is needed.

Hood
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: DICKEYBIRD on October 16, 2012, 10:56:27 AM
Ahh, I see (said the blind man)  Thanks, that looks very doable!
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: mc on October 16, 2012, 05:59:42 PM
Here's what I used for the X-axis homing on my lathe -
(http://farm6.staticflickr.com/5026/5582741641_b07e86900d.jpg) (http://www.flickr.com/photos/mc_mtb/5582741641/)
Home Switch (http://www.flickr.com/photos/mc_mtb/5582741641/) by mc_mtb (http://www.flickr.com/people/mc_mtb/), on Flickr

It's a Sunx PMR44P (RS part no. 480-5231).
I should really build some form of cover for it, but it's not attracted any swarf yet, and it's easily noticeable if it has. Repeatability is excellent, and only part size issues I get is when tips need replaced, or it loses steps due to trying stupid things.
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: DICKEYBIRD on October 16, 2012, 07:14:09 PM
Thanks mc, what kind of electronic wizardry goes between the sensor and your B.O.B.?
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: metlcutr55 on October 16, 2012, 11:19:15 PM
being in a position where i want to pull a old fanuc system off my 20 yr old nardini engine lathe, and replace it with a basic stepper system, this thread has been interesting.  with the old fanuc, i could count on homing and then counting on the machine to be exactly where it was supposed to be , machine coord wise. going to steppers with no index pulse, having to rely on the quality and repeatability of the home switches, has been one of my concerns.  even my servo knee mill can err, if the switches get dirty (ie cast iron jobs) and react slowly and differently than the last time they were used. but this is usually easy to see, as the error is often a full motor revolution or a multiple of.  the lathe has never failed me in this manner, the switches are of much higher quality, and are very well shielded.  it is very handy to be able to count on ones work coords on startup, but with no index pulse on the upcoming lathe steppers, i fear being off a thou, or 3, that could be a problem, not easy to see by eye.  i had thought if i mounted way on the back of the lathe, one of these (http://www.edgetechnologyproducts.com/pro-touch-off-gage.html) for the x and one for the z, kept them covered, and mounted a ball on a stem on the cross slide, the x & z machine coords could be easily checked by hand at any time.  perhaps a nicely made sq and // block could be subbed for the gages, then using a pc of .001 shim as a feeler to do the same thing.  checking the mill is easier, pick up a known work coord, or mount a permanent reference on the table somewhere as someone here prev mentioned.  the lathe is a lil harder, but this might work?  your thoughts? and thanks.
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: mc on October 17, 2012, 11:06:18 AM
Thanks mc, what kind of electronic wizardry goes between the sensor and your B.O.B.?
Nothing!
It's connected through a BOB that has pull down resistors, so all I needed was a PNP version (you'd need a NPN version if you have a pull-up resistor).
All it needs is a 5V and GND from the BOB, and the output wire (I think I used dark on) is connected to the input pin on the BOB.

They come in various mounts, so you can usually find one that fits with minimal extra mount/bracket work, so check the datasheet and find one that suits your chosen position best.
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: DICKEYBIRD on October 17, 2012, 01:07:41 PM
It's connected through a BOB that has pull down resistors, so all I needed was a PNP version (you'd need a NPN version if you have a pull-up resistor).
Oh yeah, to me that's definitely electronic wizardry.:(

Now you're gonna make me try to decipher my C11 manual again.  I went to the Jethro Bodine School of Cipherin' and Goesintas and have a long way to go to understand what you said.  I went with a C3 for my spindle index sensor (which works great) but definitely want to avoid buying 2 more of them if I can do it without frying something.
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: mc on October 17, 2012, 01:42:35 PM
Just looked at the manual for the C11, and it has jumpers to select pull up, or pull down resistor for each input.

Without going into too much detail, the NPN/PNP refers to the type of transistor used to switch the sensor output. A NPN transistor will switch to earth, where as a PNP transistor will switch to supply voltage.
In this application, using an NPN, the input pin must be pulled high, and will then be driven low when the sensor is activated. A PNP requires the input pulled low, and will then drive it high when activated.

The benefit of the C3, is it provides a TTL output, which doesn't require the use of any external pull-up resistors. The TTL actually drives the output high or low, instead of leaving it to 'float' when not activated. This is what the original C3 would do if set to Open Collector mode.
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Dan13 on October 17, 2012, 02:25:14 PM
Hi,

I used to make these home switches with the integral photo sensor. Now there is a new version that will soon be available but still have some of these left if that's of interest to you. Repeatability of these is better than 0.003mm and they are fully waterproof.

Dan
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: DICKEYBIRD on October 17, 2012, 03:15:21 PM
Thanks mc, I wish I could have had you looking over my shoulder when I was having C11/KB speed control isolation/hookup issues.  I think the C11's a good value but some sections of the manual drive me nuts.

Thanks Dan your opto switch unit really looks great!  What would a couple cost including shipping from Oz?  Might be more than my tightwad budget can afford but shoot me a PM when you get a minute.
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Overloaded on October 17, 2012, 03:34:23 PM
Hi,

I used to make these home switches with the integral photo sensor. Now there is a new version that will soon be available but still have some of these left if that's of interest to you. Repeatability of these is better than 0.003mm and they are fully waterproof.

Dan

Very nice Dan,
   This one looks to be one sided. Do you have any that are 2 sided ?
Also, what is the amount of over-travel ?
and the $

Thanks,
Russ
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Hood on October 17, 2012, 03:37:04 PM
Look good Dan, are they a  similar kind of idea to the ones I posted a pic of?
Are your revised ones going to have the rod out either side so you just need one per axis?
Hood
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Dan13 on October 17, 2012, 04:00:18 PM
Thanks.

These are single sided, Russ. First intention was making them double sided, but it interfered with the requirement of making them smallest possible and I decided to make them this way. The plunger stroke is 5mm, dimensions are 29x23x14mm. You supply anything between 5 to 15VDC and output is active low. Price is $30.

Hood, yes, they are based on the same concept. The new ones are an entirely different design (round frame with M12x1 external thread - like the industrial proximity switches) and they are single ended as well.

Dan
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Hood on October 17, 2012, 04:05:40 PM
Sounds reasonable Dan, the ones I bought years ago were double sided and $50 so only needed one per axis but that was a lot of years ago, probably 8, so yours are on a par and being plastic probably better.
I had toyed with the idea of making some with  a roller cam operated flag, that way travel accidental overtravel wouldnt be a problem but as I went to Index homing in the drives I never proceeded wit them
Hood
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Dan13 on October 17, 2012, 04:16:56 PM
Thanks Hood. These are not plastic however - it's an anodized aluminium there ;)

Mounting them to trigger against an inclined surface could be used to solve the overtavel problem. But I mount them just before the hard stop.

Dan
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Hood on October 17, 2012, 04:21:00 PM
Ah ok, looked plastic and knowing you made the plastic stepper end covers I just presumed they were as well
The roller cam method has a few advantages to my thinking. One is you only need 1 switch per axis if you wish, second is if you wish to have separate home switches (big travel machine etc) then you can do that.
Hood
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Dan13 on October 17, 2012, 04:24:15 PM
I agree on the roller type advantages you mentioned, but every additional moving link reduces repeatability in my opinion, that's why I tried to stay away of this.

Dan
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Hood on October 17, 2012, 04:29:42 PM
Not sure if repeatability would be an issue if they were high enough spec. The Honeywell switches I use are very accurate and repeatable but there in lies the problem, they cost a lot because of that. I was going to be making them for myself so cost and effort of making them  was not an issue, you on the other hand are making them to sell so I can see it would likely not be cost effective for you to go that route as it would be very expensive to produce, probably more than 3 or 4 times what you charge for one of your switches.
Hood
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Dan13 on October 18, 2012, 04:13:34 AM
True. Do you have a link to the Honeywell switches? What type are they and what accuracy?

Dan
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: DICKEYBIRD on October 18, 2012, 11:36:19 AM
If I was to install one of these http://www.ebay.com/itm/110936667967?ssPageName=STRK:MEWNX:IT&_trksid=p3984.m1497.l2649 and a disc with one hole in it on the end of my double shaft stepper with a mechanical switch on the axis slide adjusted to switch "on" the ground to the opto device close to the home position, I would have a very accurate and repeatable home, yes?

This assumes that the opto is set up as a normal home switch input in Mach and the mechanical switch does nothing but switch on & off the ground (or power?) to the opto.  If this has been discussed before and I missed it I apologize.  Seems like it ought'a work a treat??
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: mc on October 18, 2012, 12:05:52 PM
It would depend on how the sensor acts when the ground is disconnected and reconnected. Provided the output goes to high impedence or shorts to +5V when disconnected, and it doesn't do anything daft to the output when powered up (i.e. it remains at 5V, and doesn't spike to gnd), then it should work.

One thing I'd suggest is make the slot in the disc pretty big, otherwise there's a chance you could overshoot the slot if you're homing at a reasonable speed.
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: DICKEYBIRD on October 18, 2012, 01:05:40 PM
Ahh, OK thanks.  I figured I'd have to play around with it to get it to work.  Hopefully the sensor electronics don't do anything weird on power up but come to think about I could leave it powered up and just switch the signal?

Being a retro'd ORAC lathe it has little X-axis travel and with a very slow homing feed rate it won't take long at all. ;)
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: cjmerlin on October 18, 2012, 02:55:37 PM
Hi Dickybird, I've an Orac and use an opto sensor like the one MC showed one the page before. On the Orac X slide at the rear on the right side there is a hole with grubscrew that had a rod which travelled with the axis and pressed on a switch located just above the stepper motor. I replaced the rod with a flat sided bar with a slot cut in it and replaced the switch with the opto sensor. My X axis rapid is 2000mm/sec and I home the axis at 80% and it is accurate to less that 0.01mm.

John 
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: DICKEYBIRD on October 18, 2012, 03:56:00 PM
Hi John, nice to see a fellow ORAC user here; I may have to pick your brain later!;D

Yep, I'm familiar with the switch actuator rod you're referring to.  Mine didn't come with one and I figured if I had to make something I might as well use a manual switch on that rod and add the indexing disc/opto sensor to the stepper to get even more accuracy.  I have double shaft motors so it shouldn't be too hard to do.
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: mc on October 18, 2012, 05:09:56 PM
Ahh, OK thanks.  I figured I'd have to play around with it to get it to work.  Hopefully the sensor electronics don't do anything weird on power up but come to think about I could leave it powered up and just switch the signal?
It's not very clear from the ebay listing as to how the signal functions in regard to the sensor being blocked/clear, but your suggestion is doable.

If you arrange things so once the switch closes it connects the sensor signal to the BOB then it will work. You'd just to need to make sure the BOB input is set to pull-up/down to match whatever the blocked (or unblocked if using an index tap instead of an index cut-out) state of the sensor is.
For example, if using an index cut-out and the blocked sensor signal is 5V, then set the BOB to pull-up.
That way with the index switch untriggered/open circuit, the BOB input sees 5V. Then when the switch is triggered, the BOB input still sees 5V, until the sensor becomes unblocked and switchess the BOB input to ground.
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: DICKEYBIRD on October 18, 2012, 06:57:56 PM
Thanks mc!  You explain things so clearly even I should be able to get it working without letting any smoke out!
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: DICKEYBIRD on November 07, 2012, 11:42:52 AM
Hi ya’ll, is nice Mr. mc still on board??  I’m trying to make sure I don’t do something really stoopid with this pull-up/pull-down thing.  My latest grandson isn’t quite ready for pull-ups yet so I better get busy.  The other 3 figured it out for themselves so I reckon they’ll all be electronics whizzes.;D

I now have the hardware mounted solidly with a NO micro-switch adjusted to close about 3 turns of the stepper motor before the axis bottoms out and I mounted the opto on the motor with a half-circle disc on the motor shaft.  The opto is powered up with 5V and gnd from the C11 B.O.B.  The micro-switch is connected in series with the SIG wire from the opto and I stand ready to connect it to the B.O.B., pin #12.

I verified that the opto operates as shown in the spec sheet ie: sensor blocked .16v, sensor open 4.9v which is backward from the example given above by mc.

What’s the preferred method of hookup re: sensor/disc block/unblock, pull up/pull down.  I know, I know it’s real simple but my almost 65 yr. old brain confuses itself very easily.

(http://i57.photobucket.com/albums/g227/DBAviation/OptoSpecs.jpg)

(http://i57.photobucket.com/albums/g227/DBAviation/C11Inputs.jpg)
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: mc on November 07, 2012, 08:20:44 PM
Whether you use pull-up or pull-down won't make that much of a difference in terms of operation, the main thing is syncing the microswitch to ensure it switches well before the opto switches. Personally I'd aim to have the microswitch switch when the opto is about quarter (1/8th of a turn) of the way into it's untriggered half of the disc. That way the switch should be firmly activated by the time the opto triggers.

If you use pull-down on the BOB, you need to ensure the microswitch closes when the opto is blocked (at near 0V), so that when the opto is unblocked, it pulls the BOB pin up to near 5V.
Or if you use pull-up on the BOB, you need to ensure the microswitch closes when the opto is unblocked (at 5V), so the opto can pull the BOB pin down when it becomes blocked.

Either way will work, it's just that the microswitch trigger point/adjustment may make one way easier than the other.
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: DICKEYBIRD on November 08, 2012, 09:47:25 AM
Thanks for the clarification mc, much appreciated!
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: mc on November 09, 2012, 06:46:27 AM
No problem.
I'm glad it clarified things, as the only thing it done was confuse me when typing it!
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Hood on November 09, 2012, 05:09:15 PM
Maybe I am missing something but is there a reason using this method would be more accurate than just using an opto alone?
Index homing from an encoder and captured in hardware I can see being more accurate but doing it this way I cant.
Hood
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: DICKEYBIRD on November 09, 2012, 05:40:06 PM
Maybe I am missing something but is there a reason using this method would be more accurate than just using an opto alone?
I hope it does Hood.  Lotta wasted effort if not.  A "normal" homing opto reads the axis movement directly and would be pretty accurate depending on how good it is I suppose but I want to try it at the stepper to take advantage of the the reduction.

The way I'm looking at it, a lathe's X axis homing should be as perfect and repeatable as possible.  I figured with the ballscrew pitch, the belt reduction and motor/controller's half stepping the resolution should be very good.  The microswitch is adjusted to switch the opto in just before the end of the axis' travel and the opto will switch the B.O.B. then.  

Admittedly, I haven't set up the Mach homing config on any machine yet and there may be a land mine in the software that prevents it but I was thinking this should work OK, yes?
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: mc on November 09, 2012, 07:39:22 PM
It should increase accuracy, however whether it's noticeable when you take into account other factors such as any backlash/flex/temperature change, is another matter.

Out of curiosity, I'll run through some theoretical figures for the sensor I use, which has a worst case repeatability of 0.03mm.
Now direct on axis, as per my lathe, that's a potential error of 0.03mm, or 0.06mm diameter on a lathe X-axis.

Now I'll assume a lathe with a 5mm pitch screw, and the sensor mounted at 25mm from center.
The total circumference is 157mm (I'm rounding for simplicity hear!), of which 0.03mm is 0.019% of rotational travel.
Now as 1 turn is 5mm, we simply take 0.019% of 5mm, which gives us possible repeatability of 0.00095mm, or 0.002mm on a lathes X-axis.
Even if the sensor is mounted at 12.5mm from centre, repeatability is theoretically 0.002mm.

And having just run through those figures, I'm adding that when I redo my x-axis!
Off course the sensor Dickeybird is using, is of unknown spec, so his figures may vary.
Title: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Fastest1 on November 10, 2012, 07:50:54 AM
I hope the explanation helped Hood as it just confused me more. You are going to use the micro and the opto together? Since Mach backs off the switch after the trigger I just don't see the benefit. You make a statement in an above post "a normal opto homing routine would read the axis directly". It knows the direction and IF no steps were lost, it knows where it is. I am in the process of connecting 3 OPB94051W for my switches. I expect repeatability to be better than .0005. Homing speed will have as much effect as anything. You will have to leave the homing speed constant or the overtravel will be different for each speed.
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: DICKEYBIRD on November 10, 2012, 09:59:37 AM
Sorry for the communications gap...not one of my strongest areas.

The opto I chose has onboard electronics that outputs a voltage when it's triggered by the disc slot.  It pulses once per rev of the stepper motor when the axis is moving but the signal doesn't get through to the B.O.B. until the NO microswitch closes near the end of the axis' travel.  At that time the pulse triggers Mach to do its normal homing stop & reversal (I hope.)

I may be wrong but (hopefully) should find out today.  I'm off of work and have all day to play in the shop.  Unfortunately one tiny little wrong move in the shower this morning triggered a back spasm.  I'm waiting for breakfast and a pain pill to stabilize so I can go out to the shop and ignore the "Do not operate machinery" warning on the pill bottle.  Some people have dinner & a movie; I have breakfast and a pain pill. ;D

(I know, I know...I'm fully aware of the dangers of pain pill usage.  I only have to do this every couple months or so.)
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Hood on November 10, 2012, 12:22:24 PM
mc that sounds a rather poor repeatability you have there, maybe they are just giving  a large figure to be on the safe side. Would be interesting if you could test it out, I suspect you will get much better than the quoted number.
The Optek OPB917B that I used doesnt have any figures for repeatability in the data sheet but I and at least one other person (Bertho Bowman sp?) tested this and it is very small. I tested on a stepper driven Bridgeport and used glass scales and a DRO to test, Bertho, I think, used a rig with a micrometer to test. Repeatabilty for me was under 0.005mm (smallest measurement I had) and Bertho had repeatability of less than  0.001mm.
Now my thoughts on asking about where the benefit would be were based on this and also the fact you are both using stepper based systems. Theoretical resolution of your stepper system is (assume you have 10microstep drives)  1/800 = 0.00125mm but as microsteps are not accurate then really we can only say you are 0 +- 0.00125mm. In conclusion I would say there is no benefit to using the opto in the way mentioned as repeatability of the opto is better than the resolution you can expect.
Hood

Edit, thought you had 2:1 gearing but reading again it seems not so your theoretical resolution is double the above numbers, ie 0 +- 0.0025.
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Dan13 on November 10, 2012, 12:58:40 PM
The secret with photo sensors' repeatability is their aperture size - the smaller the better.

Dan
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Hood on November 10, 2012, 01:31:31 PM
Dan that is supposedly the case but the OPB917B is not particularly small or at least I dont think it is.
Hood
Title: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Fastest1 on November 10, 2012, 01:48:08 PM
Interesting to say the least. I now at least understand how you are thinking it will work. Not doubting. Btw, you got your point across fine, it is my ability to understand it that is the problem. I am still trying to figure out why it would be better. Theoretically the coupler could come loose at the same time as hitting the micro switch therefore triggering the opto circuit mounted on the stepper. The encoder ring would turn and indicate the correct position but would not have moved the table, right? I know the circumstances above are a little far fetched but the combo of the pain pills and breakfast has me thinking that way! I don't abuse that stuff but if something hurts, I got some in the medicine cabinet.
Title: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Fastest1 on November 10, 2012, 01:49:03 PM
I was kidding about the pain pills.
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: mc on November 10, 2012, 07:34:57 PM
Hood, certainly when I tested mine, I couldn't measure any noticeable variation with a 0.01mm dial gauge, however the issue with these sensors is they can be affected by temperature and ambient light. There's certainly no harm in doing your best to try and improve accuracy.

I'm looking to upgrade mine to a closed loop stepper system (debating between Leadshine HBS, or dynomotion), hence the question on your thread a couple weeks back about weight, and I'd like to imporve homing accuracy at the same time.
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Hood on November 11, 2012, 04:46:24 AM
Stepper systems have a big benefit of ease of setup and easier tuning but you have to be satisfied with their performance constraints.
Personally I would not look at steppers for a lathe or mill  whether they are traditional or closed loop as they all suffer from the same thing, speed increases and torque drops away rapidly.
Cost is obviously a big factor in people choosing a stepper system but I suspect as you move towards these closed loop stepper systems the price gap narrows quite a bit.

Regarding temp differences with the optos I think Bertho did tests with regards to temp and found it not to be of concern, but take that with a pinch of salt as it is just from my memory, I will have to see if I can find his article.
Hood


Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Dan13 on November 11, 2012, 02:00:02 PM
Here's the link to Bertho's test:

http://www.vinland.com/Opto-Interrupter.html

The machine components expansion would be much more of a factor than the photosensor thermal deviations.

Dan
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Hood on November 11, 2012, 02:51:30 PM
Thanks Dan, thats the one :)
Hood
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: mc on November 11, 2012, 05:51:02 PM
The leadshine closed loop stepper system can be bought new a lot cheaper than a servo system, plus the steppers have the benefit of having more low speed torque than an equivalently sized servo.
For example the Leadshine HBS57 with the smallest closed loop stepper motor produces 0.9Nm at stall, and still supplies 0.5Nm at 1300RPM
The servo you've fitted to your connect, which is a similar size, is 0.17Nm, so to get the same torque at stall, you need to run a 5:1 ratio, meaning it peaks out at 900RPM, or if you gear at 2:1 you get 0.34Nm and 2250RPM.
Now for something with only 5" travel, that speed is pointless, as even with the 2.5mm pitch screw, it's only 50 turns end to end.

The servo with gearing could theoretically get you more accuracy, however will it be any better than a direct coupled 4000step/rev encoder?
It's all a case of understanding the tradeoffs, which I obviously spend too much time doing!


Interesting stuff about the opto repeatability.
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Hood on November 12, 2012, 02:38:14 PM
Quote
The leadshine closed loop stepper system can be bought new a lot cheaper than a servo system, plus the steppers have the benefit of having more low speed torque than an equivalently sized servo.

Not sure how much the leadshine stuff is but I would reckon on £300 plus for motor and drive? Regarding the torque, not quite true as I will talk about later.

Quote
For example the Leadshine HBS57 with the smallest closed loop stepper motor produces 0.9Nm at stall, and still supplies 0.5Nm at 1300RPM
The servo you've fitted to your connect, which is a similar size, is 0.17Nm, so to get the same torque at stall, you need to run a 5:1 ratio, meaning it peaks out at 900RPM, or if you gear at 2:1 you get 0.34Nm and 2250RPM.
Now for something with only 5" travel, that speed is pointless, as even with the 2.5mm pitch screw, it's only 50 turns end to end.

That is a common mistake when people compare servos and steppers.
The units quoted for both are the same (Nm usually) but a big difference in what they actually refer to. Steppers it is Holding Torque, ie torque at a standstill. Servos there are two values, Continuous and Peak. Continuous means exactly what it says on the tin but Peak is usually 2 or 3 times greater and can be used for short bursts, exactly what you want on a machine tool  as you need a quick burst to get you moving, once on the move the torque requirement drops away hugely. So Servos can provide that extra for very fast acceleration which is of great benefit on a mill or lathe.
 You said that to get the same torque as your 0.9Nm stepper I would need to gear 5:1, that is not the case, I would get 0.96Nm by gearing 2:1 as the peak of my motor is 0.48Nm. Also note that my servo is quite a bit smaller than the stepper you are talking about, the stepper weighs in at 0.75Kg, the servo 0.5Kg, so ½  as much weight again in the stepper.

Ok so lets  compare another,  heres a link to a servo on eBay ( yes second hand but still a nice price BTW ;) ) http://www.ebay.co.uk/itm/Samsung-servo-drive-CSDJ-01BX2-with-a-motor-of-CSMT-01BB1ABT3-or-CSMT-01BB1ANT3-/180947522668?pt=LH_DefaultDomain_0&hash=item2a2150146c
It weighs in again at 0.5Kg but is only rated 3000rpm. Torque  is over 0.3Nm cont and over 0.9 Nm Peak, see torque curve below. Compare that to your stepper, again pic below, quite a difference which you will see most noticeably in the difference in acceleration between the two. Yes the stepper looks like it has more torque but again if you look at peak then its not the case and again peak is there for the acceleration and the continuous keeps you on the move.
Gear that servo 2:1 and the difference is even more.

Quote
The servo with gearing could theoretically get you more accuracy, however will it be any better than a direct coupled 4000step/rev encoder?
It's all a case of understanding the tradeoffs, which I obviously spend too much time doing!

Encoders are usually 2000 or 2500 count so 8 or 10000 pulses per rev , usually it is easy to achieve a following error of less than 20 counts and 20mS.
One other very nice thing about ultra modern AC servo technology is there is no tuning, its done on the fly and is adjusted in mS to take account of varying loads, your stepper system will likely use similar technology however.
Another thing I like about AC servo drives of this type, they take mains in so no messing about with power supplies as the drive has an appropriately sized one internally.

Now everyone to their own and steppers do have their place with me, on the coil winding machine I built. It doesnt require fast accelerations, in fact it wants the opposite so the thin wires dont snap but for a machine tool I personally would not go back to a stepper.
Obviously these are my own personal feelings on the stepper/servo debate and I am sure you and others will think very differently.



Hood
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Hood on November 12, 2012, 03:49:45 PM
Ok here is a nice comparison from real life facts and figures.
 My Bridgeport had steppers and I could achieve 2200mm/min rapids at 120mm/s/s accel. I could increase the rapids to 2500mm/min but accel had to drop down to 40mm/s/s so the former is a much better compromise.
Fitted some servos to it, same gearing etc only difference was servos instead of steppers. I could easily get 6,000mm/min at an acceleration of 1200mm/s/s. Could have got a lot more acceleration if I had fitted active shunts buit hat was more than ample for a Bridgeport.
So that’s almost a threefold increase on rapids and almost tenfold on accel yet the specs of the motors if going by torque would suggest that to not be possible hence why comparing a servo and stepper on torque is not a good idea.
Stepper was 6.4Nm
Servo was  3Nm cont

Hood
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: mc on November 12, 2012, 05:15:35 PM
How do you manage to find all the figures for servos?
The reason I used the 0.17nm, was that was the only figure google threw up.
I understand the cont/peak ratings, it's just for alot of servos the figures are not easy to find, more so if you're looking at older motors.

Cost wise, the HBS57 (smaller of the two closed loop drivers) with the bigger stepper option (2Nm) is £180 from Zapp. The larger HBS86 with 8Nm steppers are £250 or £265 if you want the one that can accept AC or DC power.
The big issue with my Conect is the x-axis motor is mounted at the rear, so unless I do some major modifications, I'm severly limited for space.
Using a HBS57 with the smaller 0.9Nm motor, I can fit a proper bearing block and still direct mount the motor, all with minimal control box changes.
I did figure out a way to mount a bigger motor, but it's a lot of extra work for power which I won't need. The hardest job I want to do is part-off, and the original 0.69Nm managed through 3/4" steel with a chipped 3.2mm insert, so the 0.9Nm should work perfectly.


For the Matchmaker, I'm currently swaying towards steppers with high voltage drivers, and closing the loop using a K-flop with Kanalog and encoders, purely for cost reasons. I can get all the parts excluding the K-flop/kanalog (which I'm planning on using anyway) for the cost of one new servo.
I know I could go secondhand for servos, but unless I can pick up suitable servos for a good price, without much hassle, I'd rather go with the limitations of steppers and upgrading later when I've got more money.
Plus, by using the high voltage drivers, upgrading to servos later will involve minimal wiring changes.
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: RICH on November 12, 2012, 06:43:17 PM
Quote
limitations of steppers and upgrading later when I've got more money

Maybe waite to get what you really want and in the long run you'll save money. The reason I stay with steppers is because
I have 5 stepper drives and frankly they satisfy my need.

RICH
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Hood on November 13, 2012, 12:10:18 AM
Easy enough to find the torque values, just find the manual for the motor/drive and its usually all there, in fact most motors have it on their label.
Price is definitely a big drawback to servos, especially in the UK but if going with steppers I personally dont see any real advantage to trying to close the loop. If you lose position with a stepper it is because you are pushing it beyond its limitations and if that is the case then you need to either lower your expectations or get better sized motors/drives.
Reading the info on the closed loop steppers it seems you would get better resolution but their is still the issue that pushing it too hard will stall it. Ok same could be said for servos, push them too hard and you will trip the drive on following error or overcurrent but servos are much more forgiving than steppers due to their high peak values.
 My Conect had the stepper at the front originally but I shifted it to the back to allow more travel and room. Dont know how yours was set up but the bearings in mine were pathetic, the motor bearings were used to take up the play in one direction and a thrust for the other.

Hood
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: mc on November 13, 2012, 01:23:27 PM
Rich, that is an option, however I could probably do with getting it running sooner rather than later. The Matchmaker is going to be one of three bigger projects fighting for money, with the main priority currently being to improve the Conect as it's the one that's actually started making money, but I've got a few jobs where having the Matchmaker running would help alot. Plus if I get it running, it means I can sell my Harrison mill to fund the next project.

Hood, the only thing I found while trying to search for manuals, were sites selling the motors with minimal information.
Anyway, I've just dug out my notes for the Conect, and with the existing set-up, I've got about 135mm of room behind the cross-slide to fit motor, mount and coupler, unless I start cutting big holes in the cabinet.
And yes, mine has the same hopeless bearing set-up, which I think is the reason behind having to continually tweak tool offsets, and why it's top of my list to upgrade.

I wouldn't mind a second hand servo for the spindle if you happen to know of any, that you aren't wanting for yourself...
Title: Re: Accuracy of Homing Devices? Pro's and Con's of Different Sensors
Post by: Hood on November 13, 2012, 02:43:28 PM
Look at the manuafacturers sites and you should get plenty info on motors/drives etc, sometimes they take a wee bit of digging to find them though.

Sounds like your conect may have less room than mine, I was thinking mine was more like 200mm but would have to look tomorrow to be sure. As said mine originally had the stepper mounted on the front but I decided to mount to the rear to give me more travel.

Afraid I dont have any motors/drives spare, sold one recently to a guy for a wee Boxford HMC, it was the same motor and drive I have put on the Conects spindle except the one I sold had a brake on the motor.
Hood