Another 7i76 Spindle Setup Question
I've used PnCConf to configure a 5i25/7i76 setup for a lathe on Version 2.5.5 of Linuxcnc. It's all gone well, so a big thanks to Mesa and those who develop/support Linuxcnc.
I have configured the spindle drive using the TB4 spindle output to control a ABB VFD, and the TB3 encoder input to read a spindle encoder. Reading a few other posts, I've managed to get spindle enable, direction, and speed sort of working, and would be thankful if someone could run a critical eye over the following settings, and let me know where I've messed it up. Note that the maximum rpm of the spindle motor is currently set at 1465rpm, and the encoder is quadrature 1024ppr.
Cheers, Steve.
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
So, I assume I've messed something up.
Cheers, Steve
PS. The spindle count now increments by a value of 1 every revolution of the spindle, I'm guessing that's what it is expected to do?
Please Log in or Create an account to join the conversation.
Can you measure the actual control voltage to work out if the problem is what LinuxCNC is doing, or with what the VFD does in response?but spindle speed drops to 0rpm when the Spindle Override slider is at 28%. (This could be a separate VFD issue.)
quote] When running the spindle in reverse in Manual Control, the + button slows the spindle down, and the - button speeds it up.[/quote]You probably need to link the motion.spindle-speed-out-abs variant of the HAL pin to the VFD. (If you haven't already)
Yes, that is what you need for spindle-synched motion.PS. The spindle count now increments by a value of 1 every revolution of the spindle, I'm guessing that's what it is expected to do?
Please Log in or Create an account to join the conversation.
I'm still not sure I've got the Output Info limit and scale values in the spindle motor configuration correct. I've tried a few combinations of: -10, 10, 1450, 0, 10, 1450, and eventually returned to -1450, 1450, 1450, as it seems to work best.
Cheers, Steve
Please Log in or Create an account to join the conversation.
However, I still have a weird problem when running the spindle in reverse. It's as if the 0 to 10 volts output from the Mesa card is linear, but reversed. You call for slow speed, and you get fast, you call for high, and you get slow. Checking the voltage output from TB4 SP OUT (wiper) while using Midi control gives the following result.
M3 (forward rotation) S500 - 3.4v and 480rpm, S1000 - 6.8v and 1020rpm. Speed control. All good here.
M4 (reverse rotation) S500 - 6.5v and 1000rpm, S1000 - 3.1v and 440rpm. Speed control, but reversed.
The above results were with the spindle motor configuration Output Info limit and scale values set at -1450, 1450, 1450. Trying a number of different values has not helped.
Any observations or suggestions on my problem would be gratefully received.
Cheers, Steve
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
However, I still have a weird problem when running the spindle in reverse. It's as if the 0 to 10 volts output from the Mesa card is linear, but reversed. You call for slow speed, and you get fast, you call for high, and you get slow.
There are 4 possible HAL pins to use for spindle speed command:
motion.spindle−speed−out Desired spindle speed in rotations per minute
motion.spindle−speed−out−abs Desired spindle speed in rotations per minute, always positive regardless of spindle direction.
motion.spindle−speed−out−rps Desired spindle speed in rotations per second
motion.spindle−speed−out−rps−abs Desired spindle speed in rotations per second, always positive regardless of spindle direction.
( linuxcnc.org/docs/2.7/html/man/man9/motion.9.html )
You need to ensure that your HAL file uses one of the *-abs pins if you are using a 7i76.
Please Log in or Create an account to join the conversation.
I've dived into the
The below text is the spindle section from the original HAL file before I started editing it. I am going to keep fiddling with it, but if anyone could point out the bleeding obvious to me it would be greatly appreciated.
Time for a quad-shot espresso,
Steve
# SPINDLE S
#*******************
# ---digital potentionmeter output signals/setup---
setp hm2_5i25.0.7i76.0.0.spinout-minlim [SPINDLE_9]OUTPUT_MIN_LIMIT
setp hm2_5i25.0.7i76.0.0.spinout-maxlim [SPINDLE_9]OUTPUT_MAX_LIMIT
setp hm2_5i25.0.7i76.0.0.spinout-scalemax [SPINDLE_9]OUTPUT_SCALE
net spindle-vel-cmd => hm2_5i25.0.7i76.0.0.spinout
net machine-is-enabled => hm2_5i25.0.7i76.0.0.spinena
net spindle-ccw => hm2_5i25.0.7i76.0.0.spindir
# ---Encoder feedback signals/setup---
setp hm2_5i25.0.encoder.00.counter-mode 0
setp hm2_5i25.0.encoder.00.filter 1
setp hm2_5i25.0.encoder.00.index-invert 0
setp hm2_5i25.0.encoder.00.index-mask 0
setp hm2_5i25.0.encoder.00.index-mask-invert 0
setp hm2_5i25.0.encoder.00.scale [SPINDLE_9]ENCODER_SCALE
net spindle-revs <= hm2_5i25.0.encoder.00.position
net spindle-vel-fb <= hm2_5i25.0.encoder.00.velocity
net spindle-index-enable <=> hm2_5i25.0.encoder.00.index-enable
# ---setup spindle control signals---
net spindle-vel-cmd-rps <= motion.spindle-speed-out-rps
net spindle-vel-cmd <= motion.spindle-speed-out
net spindle-on <= motion.spindle-on
net spindle-cw <= motion.spindle-forward
net spindle-ccw <= motion.spindle-reverse
net spindle-brake <= motion.spindle-brake
net spindle-revs => motion.spindle-revs
net spindle-at-speed => motion.spindle-at-speed
net spindle-vel-fb => motion.spindle-speed-in
net spindle-index-enable <=> motion.spindle-index-enable
# ---Setup spindle at speed signals---
sets spindle-at-speed true
Please Log in or Create an account to join the conversation.
net spindle-vel-cmd-rps <= motion.spindle-speed-out-rps net spindle-vel-cmd <= motion.spindle-speed-out net spindle-on <= motion.spindle-on net spindle-cw <= motion.spindle-forward net spindle-ccw <= motion.spindle-reverse net spindle-brake <= motion.spindle-brake net spindle-revs => motion.spindle-revs net spindle-at-speed => motion.spindle-at-speed net spindle-vel-fb => motion.spindle-speed-in net spindle-index-enable <=> motion.spindle-index-enable
This block sets up all the spindle _signals_. You probably don't actually use all of them.
Somewhere else in the HAL file, in a section you haven't shown, is likely to be the part that links the spindle-vel-cmd signal to the 7i76 analogue output.
I expect that all you need to do is to change the single line:
net spindle-vel-cmd <= motion.spindle-speed-out
net spindle-vel-cmd <= motion.spindle-speed-out-abs
Please Log in or Create an account to join the conversation.