Closed Loop Motor Setup
-
@Toastinator said in Closed Loop Motor Setup:
During Prints there is a Continuous Layer Shift Indicating to me that Moves are not Finishing before starting the Next.
That usually means that one of the last two T values is too low for your driver. Low cost step servo drivers are often very slow to respond to direction changes. The manual you linked to did not specify the required timings, other than 200kHz maximum step pulse frequency.
-
@dc42 Thanks! I have Tried Numbers Varying up 500.
T5:5:50:250 And So On, How High is TOO High? 1000? 10000?
I Will keep Playing with Timing Keep Checking back
Edit: The Stupid Manual is not much of a manual. I saw the Step Pulse Frequency, But not Direction Setup time and Hold Times
-
@Toastinator said in Closed Loop Motor Setup:
@dc42 Thanks! I have Tried Numbers Varying up 500.
T5:5:50:250 And So On, How High is TOO High? 1000? 10000?
I Will keep Playing with Timing Keep Checking back
T2.5:2.5:50:50 should probably be high enough.
PS which Duet do you have, and how have you connected the drivers to it?
-
Just Tried T2.5:2.5:50:50 Timing and It still Does the Same thing. Im wondering if this is a CoreXY Related Issue.
Im using a Duet 3 6HC, Duet 3 Expansion 3HC and 2 - Duet 3 Expansion 1XD Boards
The Motors are Connected by a "Differential Connection"After Homing X and Y, X and Y Move Toward Center, When Y Finishes. X Continues Toward Center But now Z Starts Lifting Before getting to Center.
-
Can you use M122 B# to check that your mainboard and all expansion boards are updated as well?
-
I wonder what this means from the manual;
13 Pulse command filtering time Unit: 50us Range: 0~600 Default: 60 The larger the value, the smoother the motor runs and the noise, but the position tracking lag time also increases.
50 microseconds times 60 is 3 milliseconds which is a LONG time.
The mention of "the position tracking lag time also increases" makes me think this thing might be accumulating a bunch of input pulses before starting to move the motor depending on whatever it's gains are set to.
But that would make these motors completely unsuitable for CNC or 3D printer applications, so I just don't know.
-
Yes, They all Report Back. I Had to Down Grade Firmware too 3.3Beta1 Because Using 3.3Beta2 Was Causing the Temperature of my Thermocouples to not read anymore.
Good Catch, If these Motors end up being Unusable. Would you or anyone else have a Suitable Option for Replacement? I Thought the Default 60 Meant 60us, Not 50us x 60.
-
How about trying some square motion starting very slowly and getting faster and faster and make sure only one axis moves at a time?
I don't know the size of your machine or where the origin is, but something like this: (Made-up GCODE, you'll need to make real code)
G0 X0 Y0 Z10 G1 X300 F50 G1 Y300 G1 X0 G1 Y0 G1 X300 F100 G1 Y300 G1 X0 G1 Y0 G1 X300 F150 G1 Y300 G1 X0 G1 Y0 G1 X300 F200 G1 Y300 G1 X0 G1 Y0 G1 X300 F250 G1 Y300 G1 X0 G1 Y0
-
Ill give it a shot. Im also Checking into a way of Modifying that setting from 60 to somthing Much Lower. Should that be Lowered to 1? to = 50us
I don't see that as an option. A 3d Printer that can only Print square Objects! lol
-
I'm interested in seeing if when you move very slowly that only one axis moves at time and (maybe) when yo move faster, it's not waiting for the move to complete and starting the next move due to "the position tracking lag..." mentioned above.
That would indicate it's more likely the drives and not a Duet firmware thing.
-
@alankilian Thanks for your help, I really appreciate it!
Alright, Heres what happened.
I Had to change the Speed because the original was moving at 0.5mm Per second. I did Pick Ridiculous Speed Numbers To see what would happen, and the Speed Remained CONSTANT the entire time suggesting the Speed is Controlled by the External Driver?G90 G0 X0 Y0 Z10 G1 X300 F3000 G1 Y300 G1 X0 G1 Y0 G1 X300 F5000 G1 Y300 G1 X0 G1 Y0 G1 X300 F10000 <- Here is where it said the Print was Finished. G1 Y300 G1 X0 G1 Y0 G1 X300 F15000 G1 Y300 G1 X0 G1 Y0 G1 X300 F20000 G1 Y300 G1 X0 G1 Y0
Edit: The External Driver Doesn't Fully Control the Speed, But Perhaps the Maximum Speed? When Requesting a Low Speed Like 50, it Moved at 0.5mm Per second. But at 3000, It was moving more like 50mm Per Second.
-
This post is deleted! -
I Just Got the Software to Modify the Settings Built in to the Closed Loop Stepper.
Will change the Motors back and Get back Tomorrow with the Findings
My First Attempt will change the Timing:
13 Pulse command filtering time Unit: 50us Range: 0~600 Default: 60 <- Will Change to 1 = 50us The larger the value, the smoother the motor runs and the noise, but the position tracking lag time also increases.
-
Alright Here's what I Found. I was able to use the Software to Communicate with the Drives. Changed the Setting to be MUCH Lower. Also Tried Changing these to act like Regular Stepper Motors. But Nothing I Changed Would Work.
Here's My Options:
1 - I need to Find a way to make EVERY Move Wait for An End Stop to be activated before moving to the next (Seems Slow and Unreasonable) So Im Ditching These Motors Unfortunately.
2 - Find another Nema 23 Closed Loop Motor that WILL Work with Duet 3 1XD.
3 - Continue to Rip Hair out until Bald.
Would Prefer #2 at this Point. Cost is not Much Of an issue. Any Suggestions would be awesome!
-
Well, we don't really know what the problem is with these motor-drivers yet, so I'm reluctant to try any other suggestion.
As an experiment (if you're still willing to experiment) set the drivers for open-loop mode and see how they perform.
- Do they finish the moves as expected?
Can you try slow movements and see if they complete the move at the same time?
What is your microstepping value on the drives?
Do you have steps-per-mm set right?- If you move 20mm, does the axis actually move 20mm?
Laqst one: WHY do you need closed-loop control?
- What are you trying to get out of a closed-loop system that you don't get from an open-loop system?
-
@alankilian Great Questions,
Currently Only the X+Y are using these Motors. I Think this Might work if I also Had All 3 Z Motors using the same Motor as well. (Maybe add the same Delay to all Motors Canceling out any issues?)
With the Software, I Changed the Parameters, Saved them and Read them again to make sure it was saved. After changing the Parameters. It doesn't seam like anything actually changed.
I changed them to Open-Loop Mode and it did not change its behavior at all. Slow Movements Repeated the same Issue.
Micro stepping was turned off. Full Steps Only. The Steps Per mm was also Set correctly, 20mm Was Moved 20mm.
Last, Closed Loop was More of a "Want" Then a "Necessity". I Changed these Motors Out just now for Nema 23 Steppers. I Purchased 2 Duet 3 1XD Boards for Closed Loop, and I was Hoping to Utilize them.
Didn't Think I would have a hard time getting them setup
-
These motors are US$100 for me, so I don't really want to invest US$200 to see if I can figure out what's going on.
Where are you located?
If you are interested, would you send me these motors/drivers and I'll hook them to a logic analyzer and see if I can make them work for you and then send them back?
If you're too far away i understand.
-
Sure I don't mind. They will be sitting around Collecting Dust Otherwise. Do you want me to Send 1 Or Both?
The Software they Gave to Change the Parameters:
ESS ProtunerIm Located in Baltimore, Maryland.
Let me know if you need anything else with them, PM me with the details.
-
OK, moving to PM.
-
@Toastinator I have one drive up and running.
I can read and write the internal motor-controller parameters and (sometimes) they survive a power-cycle.
I am driving the motor from an Arduino so I can precisely control the step pulse count and timing.
I'm capturing data using a Saleae Logic 16 probe so I can see the step pulses and the encoder output as a measure of motor angle.
I'm using a 2000 Count-per-revolution encoder and looking at one phase so I get 500 pulses-per-revolution captured.
I'm seeing things that looks pretty good, but it might be good to get some feedback on what others think.
- I'm seeing about 70 step pulses at the beginning of a move before the motor shaft moves. (That's 2.x step at 0.9 degrees-per-step) It seems like this is acceptable for 3D printing.
- I see in the neighborhood of 16 encoder pulses at the end of a move after the step signals complete before the motor stops. This is about 12 degrees (13 steps) which seems like a LOT and I would think would cause printing problems.
I'll update so I can capture both encoder signals to see if the motor is oscillating around at the end of a move or if it's actually decelerating and continuing to move in the same direction.
As it stands, I'm not sure these will work for printer drivers (yet)
Setup:
Beginning of move:
End of move: