Machsupport Forum

Mach Discussion => General Mach Discussion => Topic started by: bazza on January 23, 2010, 11:12:37 PM

Title: strange step loss.
Post by: bazza on January 23, 2010, 11:12:37 PM
I have constructed a new mill and have come across a strange problem. My z drive has been losing steps. It was losing them in the negative way and the bit just gets deeper. I tried slowing the drive down. I am running at 300mm per min with an acc of 6.8. still the same. I swapped a motor from my y to the z. Still the same. Now if I swap the wiring on the z, so it is set up to run the opposite direction then set motor outputs to be "dir low active" unchecked. I then loose steps on the up stroke. So I wrote some code, g01 z0, g01 z-30, g01 z-35, g01 z-30, g01 z-35 etc till I had 100 up and 100 down movements. Then went back to zero and was within .002mm so no lost steps. I cant see it being a motor problem as I changed it. I cant see it being a mechanical problem as when its wired in reverse then sent fwd with software the step loss follows the software. What am I missing. I am using a dell laptop d610 that is exclusively for the mill. The motor tests are great. I am using univelop 4/5 axis drivers. The particular code that is giving me problems is a converted jpeg, so there is tons of minute z movement.There's a total of 30,000 lines of code. About 50% of the lines have a z directive in them. After the program runs the z drive is out by about 6mm or some 3700 steps. Some of this movement is smaller than my resolution. I presume that if the command is less than the resolution then there is just no movement. I also presume that mach keeps tally of the numbers though and still calculates them into the next line. Is that correct? What should I try next?
Many thanks Bazza.
Title: Re: strange step loss.
Post by: Mattw on January 24, 2010, 12:09:55 AM
hmmmmm, I'm probably one of the least qualified folks here, but I think you may be onto something with your diagnosis.  Is your program making relative movements or absolute?  If you are making relative movements in increments smaller than your resolution, I can see how you'd accumulate errors.  Can you set up your code to make  moves to absolute positions?  Just a thought.
Title: Re: strange step loss.
Post by: bazza on January 24, 2010, 12:19:18 AM
I have tried both, one is better than the other. Can someone explain the difference between the 2 and its accumulated effect
Thanks Bazza
Title: Re: strange step loss.
Post by: Hood on January 24, 2010, 03:35:36 AM
What do you have the Pulse width and Dir Prechange set to? Try 5 for each if you have it lower or even give Sherline mode a try.
Hood
Title: Re: strange step loss.
Post by: Cartierusm on January 24, 2010, 03:46:33 AM
I'm no expert but I remember some people have problems with laptops not giving out a consistent 5V, that may be something to check.

Also what do you mean converted jpg? I use CAD/CAM to generate G-code but never heard of jpg, as that's a picture file? Please explain, always looking to learn something new.
Title: Re: strange step loss.
Post by: BClemens on January 24, 2010, 07:11:55 AM
Bazza is referring to a raster to vector conversion....

Bazza, I have a question... If you remove the motor drive from Z, does the spindle drop or is it sprung upward to neutralize its weight?

And are you using stepper motors?
Title: Re: strange step loss.
Post by: ger21 on January 24, 2010, 08:53:27 AM
Set your accel to 2 or 3 and see if it still loses steps.
Title: Re: strange step loss.
Post by: hollydog on January 24, 2010, 09:41:31 AM
Hello bazza, sounds like the same trouble as I am having, see engraving at an angle. Await third control board setup.
Title: Re: strange step loss.
Post by: bazza on January 24, 2010, 01:30:07 PM
Ok to answer a few questions. Yes I am using stepper. Without the motor attached to the z it does not drop.It is however easier to turn the screw down than up. I tried with a heap of rubber bands on it to support it with no effect. I then discounted that as being a problem as when I reversed the motor wiring and software direction, the step losses followed the software and lost its steps on the upstroke. I will reduce the acc and try that. I think I did already try it at 1 with no effect but will try again.I am running pulses at 5, I will try sherline mode. Whats the difference with sherline mode?
Bazza
Title: Re: strange step loss.
Post by: Hood on January 24, 2010, 01:38:40 PM
Whats the difference with sherline mode?
Bazza

Some drives require a very wide pulse, Sherline mode give you that, 40us if I remember correctly.

Hood
Title: Re: strange step loss.
Post by: bazza on January 24, 2010, 01:42:00 PM
Hollydog, I read your posts on engraving at an angle. Tell me was your original 2 boards usb or parallel?
Bazza.
Title: Re: strange step loss.
Post by: bazza on January 25, 2010, 05:16:32 PM
So some more info. I have tried sherline mode, I have tried running drives at 250mm per min with acc of 1. Still the same. I have repeated it over and over and the amount of lost steps are near enough to be exactly the same. So I tried swapping z and y drives by pin selection. Exactly the same. This counts out my mill. I tried adjusting the voltage to the first buffer chip on the parallel port input. I tried it at 5v. 4.5v. 4v. 3.5v and 3 volts. By doing this I would be varying the required input high signal. If the problem was that the computer was not always sending a good enough signal the amount of lost steps would change as the hysteresis of the Schmidt buffer chip changed. However the discrepancy was exactly the same.So I have to figure its in Mach3. Or still in the computer. Any ideas?
Bazza
Title: Re: strange step loss.
Post by: Hood on January 25, 2010, 05:26:42 PM
Do you have a desktop you can try instead of the laptop?
Hood
Title: Re: strange step loss.
Post by: bazza on January 25, 2010, 05:33:24 PM
Unfortunately not. I do have a motherboard and a couple of ods and ends that I might try and cobble together.
Bazza
Title: Re: strange step loss.
Post by: bazza on January 26, 2010, 02:07:24 PM
I still haven't been able to try with a desktop. I ran the road runner program 5 times. The end result was a discrepancy in the x and y movements. Each run ended up with the exact same discrepancy about 0.3mm ,+- the variables of my home switches (about 0.002mm). I am thinking that the next step for me is to get a smooth stepper and run from usb. With my motor test, there is a perfectly straight line, except for an odd bump of 1/8 inch. However on the far right hand side, just visible before the far edge of the box there is an occasional large spike. Maybe 1/2 inch above and below the line. The test comes back as a pass but maybe I am on to something here. Does the smooth stepper require the same sort of computer control from mach, or is it more like a standard setup where the computers processor just sends out standard usb serial info for the smooth stepper to decode.
Bazza
Title: Re: strange step loss.
Post by: Hood on January 26, 2010, 02:31:20 PM
Mach does the trajectory planning and tells the SS what to do, its kind of similar when using the PP except Mach tells the driver what to do.
With the SS your computer doesnt have to worry about using the driver so its less stress on the computer and also as the SS does the pulsing so a computer that has issues with pulses is no problem with the SS.
 There are still a few niggles with the SS but for the most part it works well and most are getting worked on so hopefully it will be out of Beta soon.
Hood
Title: Re: strange step loss.
Post by: hollydog on January 26, 2010, 03:27:54 PM
Hello Bazza,
               Yes you are thinking the same as we the only way to run mach3 is with usb and the smooth stepper also the C25 board, when trying with a labtop and smoothstepper system it really sounded right on and correct. So have ordered both items, looking at the info there is some very clever filters etc. in the circuitry. Although there is probley thousands of machine working satisfactory on parrel mine will not so again waiting for the postman.
Title: Re: strange step loss.
Post by: Mattw on January 26, 2010, 04:31:24 PM
I know lots of folks run the SS with great success, but it was a problem for me.  Every time one of my motor starters pulled in, the SS would drop out.  Too much electrical noise I guess.
Title: Re: strange step loss..
Post by: mattgee on February 19, 2010, 10:30:45 AM
You have a voltage problem. Start adjusting the voltage on your driver board and you will see Your step loss Increase or decrease. You will have to find a happy middle point.