- Configuring LinuxCNC
- Basic Configuration
- Mesa, Linuxcnc with step direction servo's for axis and analog servo spindle.
Mesa, Linuxcnc with step direction servo's for axis and analog servo spindle.
- mjones@welfab.ca
- Offline
- Premium Member
Less
More
- Posts: 80
- Thank you received: 3
12 Nov 2024 23:04 #314351
by mjones@welfab.ca
Replied by mjones@welfab.ca on topic Mesa, Linuxcnc with step direction servo's for axis and analog servo spindle.
This is where my lack of experience with linuxcnc hurts me. I started my hal with the configurator. But I new a guy that had the same machine and it was running, but he went with analog axis servos. Alot of code I copied and pasted changing addressing where I needed to, It took quite a bit before I could get it to open in linuxcnc with out errors. I use a step config to make a basic profile and look at it and it looks very different. But as I said it only allows parport addressing. I think now that I have drivers and motors not on machine but connected to linuxcnc, I will probably need to make a basic configuration and play with that until the motors drive as needed, at least then I will know I have the addressing correct. From there I will have to figure out how to blend the files. Problem it is not a simple file.Tool changers, mux switches with hecti decimal and all sorts. Hell right now I can't get the spindle to turn and that is the one think that is exactly the same as the machine that I copied the file from. Pinout, addressing, hal file all the same but it just sits there laughing at me. That I am sure is somehow an address issue, but if I have linuxcnc running and the machine in run state, if I turn the spindle it errors with a joint to position follow or something like that so it is reading the encoder.but i don't think it should be joint 2. Any ways I digress. Tomorrow is another day.
Thanks for input, it is always appreciated.
Thanks for input, it is always appreciated.
Please Log in or Create an account to join the conversation.
12 Nov 2024 23:20 #314352
by PCW
Replied by PCW on topic Mesa, Linuxcnc with step direction servo's for axis and analog servo spindle.
Stepconf will not help to make a Mesa step/dir configuration,
you need to use pncconf (or mesact) for that
you need to use pncconf (or mesact) for that
Please Log in or Create an account to join the conversation.
- mjones@welfab.ca
- Offline
- Premium Member
Less
More
- Posts: 80
- Thank you received: 3
13 Nov 2024 14:41 #314379
by mjones@welfab.ca
Replied by mjones@welfab.ca on topic Mesa, Linuxcnc with step direction servo's for axis and analog servo spindle.
This is what my hal shows for one of my axis servos, should be stp/dir. Does this look like a step/dir or analog code.
#*******************
# AXIS X JOINT 0
#*******************
setp pid.x.Pgain [JOINT_0]P
setp pid.x.Igain [JOINT_0]I
setp pid.x.Dgain [JOINT_0]D
setp pid.x.bias [JOINT_0]BIAS
setp pid.x.FF0 [JOINT_0]FF0
setp pid.x.FF1 [JOINT_0]FF1
setp pid.x.FF2 [JOINT_0]FF2
setp pid.x.deadband [JOINT_0]DEADBAND
setp pid.x.maxoutput [JOINT_0]MAX_OUTPUT
setp pid.x.error-previous-target true
# This setting is to limit bogus stepgen
# velocity corrections caused by position
# feedback sample time jitter.
setp pid.x.maxerror 0.000500
net x-index-enable <=> pid.x.index-enable
net x-enable => pid.x.enable
net x-pos-cmd => pid.x.command
net x-pos-fb => pid.x.feedback
net x-output <= pid.x.output
# ---PWM Generator signals/setup---
setp hm2_7i76e.0.7i77.0.3.analogout1-scalemax [JOINT_0]OUTPUT_SCALE
setp hm2_7i76e.0.7i77.0.3.analogout1-minlim [JOINT_0]OUTPUT_MIN_LIMIT
setp hm2_7i76e.0.7i77.0.3.analogout1-maxlim [JOINT_0]OUTPUT_MAX_LIMIT
net x-output => hm2_7i76e.0.7i77.0.3.analogout0
net x-pos-cmd joint.0.motor-pos-cmd
net x-enable joint.0.amp-enable-out
# enable _all_ sserial pwmgens
net x-enable hm2_7i76e.0.7i77.0.3.analogena
# ---Encoder feedback signals/setup---
#setp hm2_7i76e.0.encoder.01.counter-mode 0
#setp hm2_7i76e.0.encoder.01.filter 1
#setp hm2_7i76e.0.encoder.01.index-invert 0
#setp hm2_7i76e.0.encoder.01.index-mask 0
#setp hm2_7i76e.0.encoder.01.index-mask-invert 0
#setp hm2_7i76e.0.encoder.01.scale [JOINT_0]ENCODER_SCALE
net x-pos-fb <= hm2_7i76e.0.encoder.01.position
net x-vel-fb <= hm2_7i76e.0.encoder.01.velocity
net x-pos-fb => joint.0.motor-pos-fb
net x-index-enable joint.0.index-enable <=> hm2_7i76e.0.encoder.01.index-enable
net x-pos-rawcounts <= hm2_7i76e.0.encoder.01.rawcounts
# ---setup home / limit switch signals---
net x-home-sw => joint.0.home-sw-in
net x-neg-limit => joint.0.neg-lim-sw-in
net x-pos-limit => joint.0.pos-lim-sw-in
#*******************
# AXIS X JOINT 0
#*******************
setp pid.x.Pgain [JOINT_0]P
setp pid.x.Igain [JOINT_0]I
setp pid.x.Dgain [JOINT_0]D
setp pid.x.bias [JOINT_0]BIAS
setp pid.x.FF0 [JOINT_0]FF0
setp pid.x.FF1 [JOINT_0]FF1
setp pid.x.FF2 [JOINT_0]FF2
setp pid.x.deadband [JOINT_0]DEADBAND
setp pid.x.maxoutput [JOINT_0]MAX_OUTPUT
setp pid.x.error-previous-target true
# This setting is to limit bogus stepgen
# velocity corrections caused by position
# feedback sample time jitter.
setp pid.x.maxerror 0.000500
net x-index-enable <=> pid.x.index-enable
net x-enable => pid.x.enable
net x-pos-cmd => pid.x.command
net x-pos-fb => pid.x.feedback
net x-output <= pid.x.output
# ---PWM Generator signals/setup---
setp hm2_7i76e.0.7i77.0.3.analogout1-scalemax [JOINT_0]OUTPUT_SCALE
setp hm2_7i76e.0.7i77.0.3.analogout1-minlim [JOINT_0]OUTPUT_MIN_LIMIT
setp hm2_7i76e.0.7i77.0.3.analogout1-maxlim [JOINT_0]OUTPUT_MAX_LIMIT
net x-output => hm2_7i76e.0.7i77.0.3.analogout0
net x-pos-cmd joint.0.motor-pos-cmd
net x-enable joint.0.amp-enable-out
# enable _all_ sserial pwmgens
net x-enable hm2_7i76e.0.7i77.0.3.analogena
# ---Encoder feedback signals/setup---
#setp hm2_7i76e.0.encoder.01.counter-mode 0
#setp hm2_7i76e.0.encoder.01.filter 1
#setp hm2_7i76e.0.encoder.01.index-invert 0
#setp hm2_7i76e.0.encoder.01.index-mask 0
#setp hm2_7i76e.0.encoder.01.index-mask-invert 0
#setp hm2_7i76e.0.encoder.01.scale [JOINT_0]ENCODER_SCALE
net x-pos-fb <= hm2_7i76e.0.encoder.01.position
net x-vel-fb <= hm2_7i76e.0.encoder.01.velocity
net x-pos-fb => joint.0.motor-pos-fb
net x-index-enable joint.0.index-enable <=> hm2_7i76e.0.encoder.01.index-enable
net x-pos-rawcounts <= hm2_7i76e.0.encoder.01.rawcounts
# ---setup home / limit switch signals---
net x-home-sw => joint.0.home-sw-in
net x-neg-limit => joint.0.neg-lim-sw-in
net x-pos-limit => joint.0.pos-lim-sw-in
Please Log in or Create an account to join the conversation.
13 Nov 2024 16:00 #314386
by PCW
Replied by PCW on topic Mesa, Linuxcnc with step direction servo's for axis and analog servo spindle.
That's analog servo (7I77) setup
if you make a (different name!) pncconf configuration for a 7I76E
it will make a step/dir setup as an example
if you make a (different name!) pncconf configuration for a 7I76E
it will make a step/dir setup as an example
Please Log in or Create an account to join the conversation.
- mjones@welfab.ca
- Offline
- Premium Member
Less
More
- Posts: 80
- Thank you received: 3
13 Nov 2024 23:22 #314410
by mjones@welfab.ca
Replied by mjones@welfab.ca on topic Mesa, Linuxcnc with step direction servo's for axis and analog servo spindle.
I have a couple questions about analog vs the step/dir formats.
First, obviously what is better for accuracy, and speed?.
Second, do you still have to tune the driver to the motor when you use analog? because I find it hard to tune the motor to the driver, and I have read a few things on here about tuning the analog system in linuxcnc and it seems doable.
The reason I ask this is because from what I am reading, in analog the linuxcnc controls the strength and force of the motor. and if that is the case, giving the tools that linuxcnc gives for that, then that may be the better way to go if what I think is true.
First, obviously what is better for accuracy, and speed?.
Second, do you still have to tune the driver to the motor when you use analog? because I find it hard to tune the motor to the driver, and I have read a few things on here about tuning the analog system in linuxcnc and it seems doable.
The reason I ask this is because from what I am reading, in analog the linuxcnc controls the strength and force of the motor. and if that is the case, giving the tools that linuxcnc gives for that, then that may be the better way to go if what I think is true.
Please Log in or Create an account to join the conversation.
14 Nov 2024 00:03 - 14 Nov 2024 00:06 #314411
by PCW
Replied by PCW on topic Mesa, Linuxcnc with step direction servo's for axis and analog servo spindle.
It really depends on your existing drives.
Typically analog is used when retrofitting systems with existing analog drives
If your existing drives can do step/dir, that's usually easier to setup.
Analog drives most typically work in velocity mode and have local velocity
feedback. In this case the analog voltage is a velocity command.
When you say the analog output controls strength/force, this would typically be
called torque mode and some analog drives work in that mode, but velocity mode
is much more common.
In either case any time you have a servo motor, you may need to tune the
system for best performance. (simple step motor systems do not need tuning)
Typically analog is used when retrofitting systems with existing analog drives
If your existing drives can do step/dir, that's usually easier to setup.
Analog drives most typically work in velocity mode and have local velocity
feedback. In this case the analog voltage is a velocity command.
When you say the analog output controls strength/force, this would typically be
called torque mode and some analog drives work in that mode, but velocity mode
is much more common.
In either case any time you have a servo motor, you may need to tune the
system for best performance. (simple step motor systems do not need tuning)
Last edit: 14 Nov 2024 00:06 by PCW.
Please Log in or Create an account to join the conversation.
- mjones@welfab.ca
- Offline
- Premium Member
Less
More
- Posts: 80
- Thank you received: 3
14 Nov 2024 00:24 #314412
by mjones@welfab.ca
Replied by mjones@welfab.ca on topic Mesa, Linuxcnc with step direction servo's for axis and analog servo spindle.
Ok to take it further. I am retrofitting an old superslant lathe. All axis motors hare being replaced (and drive) the drives will work either way analog or step/dir.. The spindle because of the motor size and cost to replacing I am keeping the way it is.. I have a gantry mill I built that uses (and I apologize for saying on this forum) mach3 in step/direction and tuning the driver to the motor is a nightmare unless you pay 4 times the price for the American drives with decent tuning software. So, and it hasn't been confirmed yet, if analog means that linuxcnc does the tuning, and not the driver that needs to be tuned, than this could solve a big head ache for me. But only if this is true For many years my head has been in step/direction, but I'm thinking I may be wrong in that.
Someone with more experience in both would know right off what is better over all and for what reasons.
Any thought to help me figure crap out would help.
Someone with more experience in both would know right off what is better over all and for what reasons.
Any thought to help me figure crap out would help.
Please Log in or Create an account to join the conversation.
14 Nov 2024 16:40 #314467
by PCW
Replied by PCW on topic Mesa, Linuxcnc with step direction servo's for axis and analog servo spindle.
Analog control drives need some tuning also (to match the load inertia)
This is basically true of all servo drives (though of course some have much
better tuning software or even good autotune capability)
This is basically true of all servo drives (though of course some have much
better tuning software or even good autotune capability)
Please Log in or Create an account to join the conversation.
- Configuring LinuxCNC
- Basic Configuration
- Mesa, Linuxcnc with step direction servo's for axis and analog servo spindle.
Time to create page: 0.090 seconds