Help! Lost GCODE data points? (not lost steps) Messed up milling

Good luck.

I also had a similar problem when my x,y,z end stop switch controller lines were disconnected. I figured it shouldn’t matter because I wasn’t using any end stop switches but the machine would randomly glitch out until I connected the end stop wires to each other ( as if I were connecting them to a switch) and I think there was also a machine control setting for normally open or normally closed end stop switches. That still doesn’t make any sense to me, but it worked. This was on my small milling machine with a flashcut cnc controller. Just tossing out things I’ve come across. I hope you get it figured out.

Thanks. I’ll listen to any suggestions.

In my case this isn’t a likely option since I have dual endstop switches, normally closed switches, and my Z min input is connected to my touch plate sensor for probing the workpiece top surface and after I probe I connect my clip that attaches to the bit during probing directly to the touch plate while milling so that if I have a brain fart and Home Z.

Status update…

Still chasing demons… and regressing…

So I have been running laps on the MPCNC… I created a toolpath that is an octagon that is the full size of my MPCNC bed. I disconnected the spindle motor and I let the thing just do the toolpath 50 times and listened.

Every so often you would hear a stutter. Lost step.

I was using V510 so I switched back to V509. Same.

I looked at my power supply for the steppers. It is a 12V 15A supply but I switched to a 12V 20A ATX supply just to see. No change.

I swapped both the RAMPS board and the mega2560 including all the DRV8825 drivers. No change.

I cleaned everything. EMT pipes, bearing surfaces. No chips, dust, boogers. No change.

I checked how freely things moved… hm… not great… at one point when trying to reduce chatter I tightened things. So I backed off until things were pretty easy to move. No change.

I flashed the mega2560 with GRBL 1.1 and figured out how to clone X and Y axis. No change.

So its not the firmware.
It may still be RAMPS/mega2560 in some strange manner.
My next test is going to be to drive the MPCNC using an UNO with a CNC shield. Thats what drives my current Acro Laser Engraver reliably. I ordered another CNC shield because I really don’t want to mess with my engraver and I have spare Uno around and the CNC shield is like $10 so as soon as that arrives I will report back.

After that test I have one more theory that I dread…

I have a suspicion that my bearings are total crap and may be locking up internally due to the ingress of dirt. I only noticed about half way through my build that the “double rubber sealed” bearings actually had gaps around the seals in places… I noticed when I saw light RIGHT THROUGH a bearing I picked up… through both seals, past the race and out the other side… confidence low… OK, I don’t have a SUSPICION my bearings are total crap, I KNOW they are total crap, but I figured by the time they caused issues I would have used the MPCNC to build a full metal CNC of some form…

In hindsight I should have stopped, ordered new bearings and redid the whole thing… This theory also fits as to why things seem to be getting worse, especially after milling a bunch of aluminum…

Nope… not frustrating at all.

I can’t offer any help. But I’m reading and I hope you can figure it out.

Brave man @jeffeb3

Today was major progress day…

Lets call it a “learning” day…

I learned that the set screws (grub screws) in all XY stepper motors should be tight… I was doing more debugging and at some point when the steppers were enabled but motionless I discovered I could move the one end of the X axis still… Closer inspection showed one set screw missing and the second apparently loose. Ouch. So there is a real good debug technique for loose GT2 pulleys… enable the steppers and see if anything will move…

An interesting sidenote that threw me off the trail was that it was the OTHER stepper that was making all the noise when I was running… again hindsight is 20-20. Of course it is… the loose end doesn’t move, the driven end keeps going, skews the axis, binds, the stepper misses steps…

The moral is don’t always look at where the noise comes from for the problem…

I was pretty excited by this discovery but I still decided to have it do 50 laps without the spindle running. Every so often I could still hear what sounded like a step issue… without the spindle you can hear what the steppers are doing pretty clearly. Thats another good debug technique… disable the spindle, send it a toolpath (I chose one the full size of my bed) and listen… and have it do that toolpath 50 times! Min would hiccup every 10 laps or so…

So then I went back to looking at my general assembly and just feeling how things moved… long story short, I had things too tight still. I was getting binding… My gut says this is in part a result of using EMT and the dimensions of EMT not being as perfect as say 1" stainless tubing… I think I would have gone a different route in hindsight and used better quality tubing…

There was a third demon I hadn’t mentioned that I also seem to have resolved… communication errors.
At some point I started getting Repetier errors sending via USB which is why I switched to SD card for GCODE printing (and the fact that using SD card removes the PC requirement for long jobs). WHile sending jobs I would get
Communication timeout - reset send buffer block
This started after I “cleaned up” my MPCNC after getting it actually working. I installed cable chains and put all the wires in them and immediately started getting communication errors. The areas I suspected were:
Shared stepper power and arduino power.
Spindle electrical noise.
PWM to spindle 0-10V noise through converter I made (ESTLCAM Schematic)
Changed arduino power, no change
Rerouted spindle wires mostly outside the cable chain to move away from other wires, no change.
Disconnected PWM to 0-10V converter and used spindle POT for speed control (i.e. zero connection between spindle and arduino), no change.

Eventually I ran the job with no spindle running. Success. OK, narrowed it down to spindle induced noise. So I took some metal braided shielding and ran the spindle wires inside that and put the spindle sires back inside the cable chain. So far so good. I don’t even have the shield grounded at this point. Just shielding the spindle power wires was enough to solve that one.

Running a few wood jobs to verify everything is reliable with PWM to 0-10V interface to control spindle speed and so far things are looking promising…

Time… and aluminum… will tell…

2 Likes

Sigh… @vicious1 I appreciate your optimism marking it as a solution but apparently its premature…

There is lots of good debugging info in the above… but I still have lost steps.

I generated a giant square spiral toolpath and had it do it 50 times. Started off pretty decent but every so often you could still hear that faint thunk of a stepper that isn’t happy…

X & Y are free moving… no binding… bearings don’t feel bad… (yet). DRV8825 vref checked, all about .83v

Things got worse with time it seemed. Thermal? I could hold my thumb on the DRV8825 heat sinks for seconds so didn’t seem bad. Put a blower on the controller anyway. With blower they were literally cool to touch. Still having issues. One or two thumps per bed length.

I suspected maybe I have bad DRV8825 drivers or some issue related to DRV8825 so I replaced them with A4988 drivers for X and Y just to see. Didn’t sound right then I realized oh yeah, the Marlin firmware has a whole timing section related to the drivers… so I recompiled (V510) with A4988 set for X Y X2 Y2 E0 E1 (dual endstop setup) and still say issues… actually worse.

Yes, I checked, all grub screws tight still… :slight_smile:

I am going to park this for a while and ponder things… I have a spare CNC shield coming in and I decided to blow the bolts and order an SKR Pro V1.2 board (I went to buy from V1 but you are out of stock… argh…). Unless I have an amazing epiphany between now and when hardware arrives I am out of ideas.

In case you haven’t figured it out, my basement is like a Mouser or DigiKey warehouse of electronics… and growing…

1 Like

Just to be sure, what speeds are you running your tests at?

Oh man… @vicious1 ever have one of those panic moments when you think you just did something REALLY stupid in public… I had one of those when I read your reply… “am I really being that stupid that I am just pushing it faster than it should go???”

Phew… got home and checked…

I am doing the no load testing fast… but that’s not the issue…

I get missed steps when its running 500mm/min which is like 8.3mm/s
I get missed steps when it is homing, whatever the homing speed is…
I get missed steps when it is running flat out which I believe is set in the firmware at 50mm/second
#define DEFAULT_MAX_FEEDRATE { 50, 50, 15, 25 }
(I assume that’s what that is in the Configuration.h…)

So I don’t think its a speed issue unless I am misunderstanding something which is REALLY a possibility…

You should easily be able to run 30mm/s (1800mm/min) with no load X and Y. So your gcode should say F1800 or less.

…Using all my parts. Any deviations change things.

Just running a test at 1000mm/min (my spiral) and I am hearing thunks on moves in all directions on both X and Y. RAMPS 1.4 (and 1.6) boards, DRV8825, 12V 15A power supply for steppers that reads 11.7V and doesn’t budge. Steppers are 84oz/in
image

And yes, fair comment, your hardware… I am both appreciative and astounded by your support for those of us that DIY…

In my defense… I have gone to your store multiple times when things were at low points to buy things like an “official” controller like the SKR or RAMBO and things were (are) out of stock… is this a supplier issue or is MPCNC too popular or what?

Another possibility is the steppers… having read a blog post about how the DRV8825 drives them and there being issues when the DRV tries to drive them during part of the phases at less than 12% of the supply voltage which given these are technically 3.06V steppers vs your recommended 64oz/in which are 4.2v steppers… it may be an issue with them being such a low voltage and the DRV8825 having issues properly driving them. More research required.

I am currently driving them off X Y E0 E1 on the RAMPS board. I may change them to X and Y and wire them in series which might give me another data point to look at in this mystery. In my head I am thinming I can do that without reflashing the controller so it would just be a matter of making the wire adapters. Which BTW brings up a question about the page Wiring the Steppers | V1 Engineering Inc
image
and
image
I believe the two pictures both work, but the second has stepper B secondary coil reverse polarity vs the first picture… I assume this may just change a direction which is undone by swapping the whole connector around or is one of them wrong…??

1 Like

All the things. Shipping, supplier, cash flow, covid, spring festival, xmas, etc. No worries I just have to add that stipulation in case I miss something.

I am really at a loss, check for broken parts? The last giant mystery we had around here was a fully broken tool mount that no one saw. Start swapping out bearings?

Because they’re on opposite sides of the axis, the motors need to rotate opposite of one another to move the ends in the same direction. I believe the polarity swap in the harness accomplishes that.

Normally the polarity swap is accomplished by simply rotating the molex connector 180 degrees which swaps BOTH coil polarities. That’s why I am thinking this may not be right in the diagram vs what I think is right in the sample wired adapter picture. I may be over thinking this but I think polarity and phase are important and if you change just the polarity of one winding then the phase of that winding will be wrong…

I think the series diagram should look like this with Winding 2 on Stepper B matching polarity with Winding 2 of Stepper A

I actually built two sets of adapters. First as per diagram … worked… today I made one as per the sample wired adapter also seemed to work… but when I say work… I don’t mean all my missing steps are gone… I just mean things seem to move properly when they are moving… so I was probably over thinking things above…

I am still getting intermittent missed steps… WAY WAY fewer than with the steppers on their own driver… but too many to reliably mill… (we are talking 1 or 2 missed steps on the length of the bed).

Of course that didn’t stop me from trying a cut… on aluminum no less… go big or go home… I went home in the end… It was actually not as bad as previous attempts. With very few missed steps it looked decent but I had some SERIOUS chatter (like serious enough to damage the end mill) primarily because I had my machine so loose trying to eliminate missed steps it was pretty much a sloppy mess… and once it got like 3mm deep in the aluminum then missed even one step it was trying to mill a 3mm depth of cut so that test went poorly. But it was fun to watch…

This is becoming a blog not a forum thread… oh well. Still learning…

And today I learned more… about my MPCNC and about my Laser Engraver… Laser engraver learning was related to this MPCNC issue…

My laser uses an UNO and a CNC Shield running GRBL. Already mentioned that I wanted to try the MPCNC “hardware” (frame, steppers etc) on a completely different controller. That’s why I ordered a spare CNC shield to go with my spare UNO (and the SKR pro). Couldn’t wait for that CNC shield to arrive… and with a CNC shield sitting there on my laser engraver… too tempting…

But… as mentioned in an earlier post, didn’t want to mess up my laser engraver… so I decided I would clean up the laser engraver up so I wouldn’t mess it up when I put things back… cleaned up all the wiring… labelled all the wiring… even decided that instead of running the two Y motors in parallel like I presently do I would wire in series because that really does seem better. Thought I should make sure it all worked before grabbing the CNC shield…

It failed… Y axis was skipping… (are you kidding me???) so that’s when I looked at the specs for my laser engraver steppers… I sort of slam steppers into things like all NEMA17 steppers are all the same because the screw holes line up… (OK, I know they aren’t all the same… but I usually only give it a little thought like do they have enough force???) Anyways, looked up my laser engraver steppers and they are 11.2v steppers… doh… two of those in series using a 12v supply… that’s not happening… built a nice one to two parallel adapter instead of series and all good… Everything looked great compared to the rats nest wiring I had cobbled together originall;y so that is a little progress… (one day it will get cable chains…)

Back to task at hand, MPCNC using “borrowed” CNC Shield on spare UNO and GRBL… (really I was most worried about reprogramming the UNO and getting all the GRBL settings back to normal for the laser engraver)

Still losing steps when running no load at 1000mm/min even with (apparently) really slow acceleration which seems to be the default in GRBL 0.9j… whatever… running along at speed I still hear the telltale thud every so often…

So now I know the problem exists with mega/RAMPS running various Marlin firmware using DRV8825 drivers and completely different UNO/CNC Shield running GRBL firmware…

Feeling the way things move along the axis seems not too bad… so at this point I am not thinking bearing (yet)…

Which leaves steppers… I am going to pour over the data sheet and specs for the steppers I am using to see if there is some bizarre timing or drive issue that needs a firmware tweak or something… or I may buy new steppers…

Yes I have told myself many times… would have been cheaper and easier to order a kit… :slight_smile:

I will followup when I have more info… sigh…

You can reverse the direction by flipping the polarity of one coil, or switching the order of the coils.

Reversing the whole plug reverses two coil polarities and reverses the order. 3 direction changes make one direction change.

Well, my MPCNC may not yet work the way I want, but in terms of what I am learning through this whole thing… TOTAL success!!!

I had an epiphany later today that hey, I never adjusted the A4988 drivers current settings… maybe thats why I am losing steps? So then I headed down another learning rabbit hole… discovering that some of my A4988 driver boards have a .1 ohm Rs and some have a .2 ohm Rs so the formula for current programming changes… Another reason to just buy a kit from V1 Engineering… Anyway… all my A4988 are now labelled so I know which are which… and after properly setting the current??? still missed steps.

I hope I never get tired of learning… if I do this will become a PITA.

Yesterday I did some further diagnostic work.
I removed the core. This leaves just the X and Y axis free to move on their own. Just two steppers and 10 bearings for each axis. I ran my spiral motion test and yup… still hearing missed steps…

Time to look at the bearings…

My gut was telling me right from assembly these were going to be an issue due to crap seals… but I never imagined how bad these bearings could be…

The picture is of the center bearing race from a brand new bearing (upper) and one that has probably run 30 hours on the MPCNC in total (lower) including all the testing once problems started. The spalling on the race is beyond imagination for a bearing that is really under a pretty light load for so few hours of use… And the way the race has deformed enevenly is also bizarre… like the metal was harder in one area than another or the bearing was run back and forthe in the same spot which it wasn’t… This was one of the core bearings in the X or Y direction so that was moving pretty decent distances during milling. Inches for sure which would have been full revolutions of the bearing.

So don’t cheap out on bearings like I did. Way not worth it.

Not ready to say this is the problem for sure until I have a working unit but this sure looks like a smoking gun…

Oh and I disassembled a few of the spare bearings I had left over. No grease in any of them to speak of. The two part cage wasn’t assembled properly in one of them. And all the seals are not seals…

Anyone need some bearings for fidget spinners? They would probably suck for that too.

Dang it looks like that one just missed the hardening step all together.