CNC build: Grizzley G0704 LinuxCNC controlled with a Mesa 7i76e
Stepper motors & Drivers
X & Y Axis steppers & Drivers:
NEMA23 570oz/in 5A 3/8” Dual Shaft Stepper Motor (KL23H2100-50-4B)
1.8° /200 Steps Per Rev.
https://www.automationtechnologiesinc.com/products-page/nema-23/nema-23-three_eighths-inch-dual-shaft-with-a-flat-570-oz-in
http://www.automationtechnologiesinc.com/wp-content/uploads/downloads/2012/02/KL23H2100-50-4BT.pdf
5.0 amps 50.6 volts
KL-5056D Driver(s)
Note: I use a 48 volt supply, as cncshopmill on youtube had two of these go out on him with 50volts.
Z Axis steppers:
NEMA34 Stepper Motor – 906 oz in 6.1A Single Shaft (KL34H295-43-8A)
1.8° /200 Steps Per Rev.
https://www.automationtechnologiesinc.com/products-page/nema-34/nema34-stepper-motor-%E2%80%93-906-oz-in-6-1-amp-single-shaft-kl34h295-43-8a
http://www.automationtechnologiesinc.com/wp-content/uploads/downloads/2012/01/KL34H295-43-8A.pdf
6.1 amps 58.1 volts
Driver KL-8070D
So now i need to configure the INI file for linuxcnc. PCW of Mesa electronics helped me out greatly by providing some sample configuration files for the 7i76e controller board, to which I am modifying in attempts to match my G0704's hardwear as best as possible. I searched around the internet for predefined settings for my drivers and steppers and didn't find much, but I'll add things here as i find things that influnced some choices, but ultimately ill arrive to my own values through testing:
this one isn't for certain based on my stepper driver, but at least its close to my mill so it gave me some numbers to start off from.
https://www.youtube.com/watch?v=yWqFEjEg0dc
I am most open to any information that might help refine these settings and as I work I will update the blog to reflect such files and settings.
I know that the drivers have dip switches that you select the number of steps per revolution. Currently I have gotten my G0704 to operate in scale at 2000 steps per revolution configured on the steppers dip switches and having my INI file altered to work proportionally to that and how many rotations it takes to move one unit of measure (mm). I have no idea if 2000 is optimal, but at least it is moving 10mm when i ask it to move 10mm, so I head over to linuxcnc on freenet to discuss and here is what transpired (I am computer_barf):
(09:57:27 AM) Computer_barf: are steppers bound by a certain number of steps per rev or is that more of a driver thing?
(09:58:39 AM) Computer_barf: currently I have my steps per rev set to 2000, with my driver's dip switches set to that
(10:01:59 AM) malcom2073: They have a certain number of steps per revolution, that's how they're built
(10:02:09 AM) malcom2073: the number dependson the stepper, but most motion control steppers are 200 steps per rev
(10:02:12 AM) skunkworks: normal steppers are 200 full steps per rev. So you have 10X microstepping.
(10:02:14 AM) Roguish: Computer_baf: it's both. http://homepage.cs.uiowa.edu/~jones/step/
(10:02:20 AM) pcw_home: 1.8 degree motors have 50 poles and 200 full steps (this is determined by the motor design)
(10:02:22 AM) pcw_home: you can have an arbitrarily high number of fractional steps per whole step
(10:02:53 AM) pcw_home: though > say 32 you get into diminishing returns
(10:05:52 AM) Computer_barf: Ok so what I get from that is that I probably shouldn't have my driver set to 2000 steps and I should instead switch the dip switches to have it configured for 200, then i would also need to alter
(10:06:25 AM) Computer_barf: my ini's scale to reflect that, in context to my c7 ballscrews mm/rev
(10:06:54 AM) pcw_home: no I would set it for say 6400 steps (32 u steps)
(10:07:04 AM) pcw_home: full stepping is nasty
(10:07:56 AM) pcw_home: lots of vibration and likelihood of resonance stalls
(10:08:31 AM) skunkworks: well - software stepping? That may limit your ustepping - may have to balance what you can do.
(10:09:33 AM) Computer_barf: ahh. ok , I will do that, PCW, so i guess there is a certain number of microsteps per step and thats why you end up with the bigger number?
(10:09:43 AM) pcw_home: this is hardware (though you need to check your drives minimum step length and space as this may also limit the maximum ustep ratio you can use)
(10:13:06 AM) pcw_home: yes think of a compass needle with a magnet pulling it around in a circle (the compass needle is the step motor rotor)
(10:13:07 AM) pcw_home: the ustep ratio is determines the angular step size of the magnet (full steps are 90 degrees)
(10:15:16 AM) pcw_home: note that the compass needle torque vs displacement does not change, just the angular step size of the external field
(10:18:01 AM) pcw_home: and just like the compass with a 90 degree step in the field, with a full step (1.8 degrees),
(10:18:03 AM) pcw_home: the step motor rotor will jump to the next position and then overshoot and oscillate
(10:18:14 AM) pcw_home: (ring)
(10:20:05 AM) pcw_home: so the main advantage of large ustep ratios is that they are smoother and dont tend to excite
(10:20:06 AM) pcw_home: vibrations and possible resonances that can lead to step loss or stalls
These guys are of course, geniuses, and I don't really always understand what they are saying when they first say it. So here it is so that I may digest it over time. For the moment, I'll go with PCW's advise of trying out 6400 steps (32 u steps), and calculating my C7 ballscrews rotations per unit of measure in accordance, and setting the scale in my INI respectively to that.
So on my KL-5056D , I set my dip switches accordingly:
(1)off(2)on(3)on(4)off(5)off(6)on(7)off(8)on
This is to set the steps to 6400 and the amperage to 4.9 amps
So now I must configure my linux CNC ini file to reflect such.
I have discovered that if I do not place a MAX_LINEAR_VELOCITY setting in the [TRAJ] section things hardly move at all. So I place that in that section at a setting equal to the highest MAX_VELOCITY amoung the axis settings, ie:
MAX_LINEAR_VELOCITY = 80
So for each axis I modified the settings as so:
MAX_VELOCITY = 80
MAX_LINEAR_VELOCITY = 80
MAX_ACCELERATION = 300
# Set Stepgen max 20% higher than the axis
STEPGEN_MAX_VEL = 84
STEPGEN_MAX_ACC = 360
BACKLASH = 0.000
# drivers set to 6400 steps/rev
# C7 ballscrews move 5mm per revolution
# therefore 1280 scale should make it move 1mm
SCALE = 1280
These settings seem to be working OK, with the mill moving at acceptable speeds for what I imagine my usage will be. I am jogging currently with a maximum 4800mm/min or 188.97 in/min. When I set my MAX_VELOCITY settings faster I start getting errors. In previous attempts Ive seen my mill move at faster speeds than it is operating at now, but as of current I am unlikely to need it to move that fast, so I only plan on exploring this if I really need to or maybe just for shit's and giggles when I have less important matters pending. Here is some interesting info that was discussed on freenet pertaining to this:
(11:20:55 AM) roycroft: just keep running it faster until it gets pulled over and issued a citation
(11:22:09 AM) pcw_home: you can also trade off accel for velocity
(11:23:07 AM) pcw_home: That is you can use more accel if you limit the velocity since step motors have much more torque available for accel at lower speeds
(11:30:09 AM) alex4nder: accel is going to be more useful while machining anyway
on headroom:
(11:09:51 AM) pcw_home: Computer_barf you need to set the stepgen maxvel so you have say 20% headroom
(11:31:28 AM) pcw_home: headroom can also be limited by steplength and stepspace settings
nema 23 stepper motor is a stepper motor with a 2.3 x 2.3 inch faceplate. It is suitable for 3d printer, robot arm, cnc machine,etc. In low-speed applications, the stepper motor can be driven at the desired speed without missing a single step.
ReplyDeletesee more at oyostepper.com.