Fanuc 12 bit binary spindle control
14 Oct 2017 08:42 #100343
by johnmc1
Fanuc 12 bit binary spindle control was created by johnmc1
Good Day All
I seeking information on using Linuxcnc to control the Fanuc dc spindle fitted to a Matsuura milling machine,which I am about to refit with Linuxcnc.
The Fanuc DC spindle control is model A20B-0005-0372/14F.
The spindle control requires a 12 bit binary signal that is then converted by a D/A converter to a analog 0 to 10v signal.
There is also a forward and reverse signal for direction.
Please advice on the following possible solutions ..
Try and tap a analog signal into the control and by pass the DAC module.
Convert the Linuxcnc analog signal to a 12 bit binary signal as per fanuc.
Replace the spindle drive.
Thanks in advance .
john
I seeking information on using Linuxcnc to control the Fanuc dc spindle fitted to a Matsuura milling machine,which I am about to refit with Linuxcnc.
The Fanuc DC spindle control is model A20B-0005-0372/14F.
The spindle control requires a 12 bit binary signal that is then converted by a D/A converter to a analog 0 to 10v signal.
There is also a forward and reverse signal for direction.
Please advice on the following possible solutions ..
Try and tap a analog signal into the control and by pass the DAC module.
Convert the Linuxcnc analog signal to a 12 bit binary signal as per fanuc.
Replace the spindle drive.
Thanks in advance .
john
Please Log in or Create an account to join the conversation.
14 Oct 2017 14:13 #100349
by PCW
Replied by PCW on topic Fanuc 12 bit binary spindle control
What voltage are the bits? could you just use parallel port bits
(or whatever output bits you have) to drive it?
(or whatever output bits you have) to drive it?
Please Log in or Create an account to join the conversation.
15 Oct 2017 04:18 #100365
by johnmc1
Replied by johnmc1 on topic Fanuc 12 bit binary spindle control
Thanks for your reply
The bits are tied to ground to become active,also
I would be able to use free output bits, with free M codes for speed control
john
The bits are tied to ground to become active,also
I would be able to use free output bits, with free M codes for speed control
john
Please Log in or Create an account to join the conversation.
19 Oct 2017 14:05 #100551
by andypugh
Replied by andypugh on topic Fanuc 12 bit binary spindle control
Might be a job for an arduino nano.
But, you should be able to do it with output bits and the "bitslice" HAL component.
linuxcnc.org/docs/2.7/html/man/man9/bitslice.9.html
But, you should be able to do it with output bits and the "bitslice" HAL component.
linuxcnc.org/docs/2.7/html/man/man9/bitslice.9.html
Please Log in or Create an account to join the conversation.
20 Oct 2017 21:47 #100598
by johnmc1
Replied by johnmc1 on topic Fanuc 12 bit binary spindle control
Thanks for your reply,
The bitslice hal component I do not understand how it would be implemented.
What I need is a method in Hal,to change the linuxcnc S command to a 12bit digital signal for Fanuc spindle control.
The arduino nano is method that has possibilties.
john
The bitslice hal component I do not understand how it would be implemented.
What I need is a method in Hal,to change the linuxcnc S command to a 12bit digital signal for Fanuc spindle control.
The arduino nano is method that has possibilties.
john
Please Log in or Create an account to join the conversation.
21 Oct 2017 02:26 #100600
by andypugh
Replied by andypugh on topic Fanuc 12 bit binary spindle control
Is this 12-bit digital signal sent as 12 parallel bits or a serial stream?
Please Log in or Create an account to join the conversation.
21 Oct 2017 04:51 #100605
by johnmc1
Replied by johnmc1 on topic Fanuc 12 bit binary spindle control
The 12-bit signal is sent as 12 parallel- bits .
I also believe that fanuc spindle drive holds the signal for about 8 seconds before it can update and that,
12, low bits equals maximum speed, while 1, low bit equals minimum speed.
john
I also believe that fanuc spindle drive holds the signal for about 8 seconds before it can update and that,
12, low bits equals maximum speed, while 1, low bit equals minimum speed.
john
Please Log in or Create an account to join the conversation.
21 Oct 2017 11:24 - 21 Oct 2017 11:25 #100608
by andypugh
Replied by andypugh on topic Fanuc 12 bit binary spindle control
That last part (all zero for max) is a bit awkward.
Time for a custom component.
linuxcnc.org/docs/2.7/html/hal/comp.html
Time for a custom component.
linuxcnc.org/docs/2.7/html/hal/comp.html
component fanucspindle "convert spindle speed to 12 parallel bits";
pin in float max-speed = 1000 "maximum spindle speed";
pin in float spindle-speed "spindle speed command";
pin out bit bits-##[12] "output bits";
function _;
author "andypugh";
license "GPL"; // indicates GPL v2 or later
;;
#include <rtapi_math.h>
FUNCTION(_){
int speed;
int i;
if (spindle_speed < max_speed * 0.0004) {
speed = 1;
} else if (spindle_speed > max_speed * 0.9995) {
speed = 0;
} else {
speed = fabs((spindle_speed / max_speed)) * 4095;
}
for (i = 0; i < 12; i++){
bits(i) = speed & 0x001;
speed = speed >> 1;
}
}
Last edit: 21 Oct 2017 11:25 by andypugh.
Please Log in or Create an account to join the conversation.
22 Oct 2017 12:08 #100627
by johnmc1
Replied by johnmc1 on topic Fanuc 12 bit binary spindle control
Good Day Andy.
Many thanks for your Custom component.
It will take a while for me to digest the component .
To muddy the waters even further, the spindle gear box ratios as per Matsuura manual.
H speed 0.903 to 1
L speed 0.198 to 1
Can this be allowed for in the custom component,
or is the gearbox ratios attended to in Hal
john
Many thanks for your Custom component.
It will take a while for me to digest the component .
To muddy the waters even further, the spindle gear box ratios as per Matsuura manual.
H speed 0.903 to 1
L speed 0.198 to 1
Can this be allowed for in the custom component,
or is the gearbox ratios attended to in Hal
john
Please Log in or Create an account to join the conversation.
22 Oct 2017 12:45 #100630
by andypugh
Replied by andypugh on topic Fanuc 12 bit binary spindle control
Is it an electronically-controlled gearbox?
I have a HAL component that I use on my 2-speed + VFD lathe which controls the electronic clutches for me. And I have another system on my mill which works out what gear is engaged on the manually-operated gearbox.
I have a HAL component that I use on my 2-speed + VFD lathe which controls the electronic clutches for me. And I have another system on my mill which works out what gear is engaged on the manually-operated gearbox.
Please Log in or Create an account to join the conversation.
Time to create page: 0.143 seconds