I am helping a friend, Dale Grover, to retrofit his Emco EMCOturn120P lathe 
with new controls.  On our lathe we have what is considered the "older style" 
8-position tool turret which is driven by a 24V DC BLDC motor.  There is also a 
position encoder on the turret that reports the 8 tool positions in gray code.  
Dale developed a nice Arduino Nano based hardware board that uses the Ti 
LMD18245 Full-Bridge Motor Driver to drive the motor and to drop current when 
the motor backs against the pawl.  He also wrote the Arduino code (called a 
Sketch in arduino speak) to drive the turret.

The operation is, you issue a tool change in Linuxcnc (ie, M6 T1), it sends 
that request along with the tool number via the USB port to the Arduino.  The 
Arduino reads the turret encoder, drives the motor to change the tool if 
necessary, and returns the same tool number as an indication of success.  
Linuxcnc receives the tool-changed success and Bob’s your uncle.

Since we have 1-8 physical tool positions on this turret we map tool numbers 
9-16, 17-24, 25-32, etc., etc., back to physical request for tool 1-8 
(essentially mod-8).  That way you can set up a tool table for different jobs.  
i.e.,  job #2 uses tool numbers 9-16.  You load those tools in the turret: tool 
9 in position 1, tool 10 in position 2, and so on.  The component will map the 
tool request back to physical positions 1-8.  Tool 0 request (no tool) is 
ignored.

I suspect this solution may work with the newer style Emco turret as well, but 
I don’t have one to try.  I am fairly sure it wouldn’t take much modification 
in any case.  

Anyway, we are making this solution open source so have at it - if you care.  
All the files are currently located here: 
http://bgp.nu/~tom/pub/toolerator3000/ <http://bgp.nu/~tom/pub/toolerator3000/>

Files there are:
PDF viewable schematic of controller board:  mstc_schematic.pdf
PDF viewable board layout:  mstc_pcb.pdf
KiCAD schematic and board layout files:  mstcPCBFiles.zip
Linuxcnc userspace component source code:   toolerator3000.comp
Arduino sketch source code:  Toolerator3000.ino
A brief readme for installation: README.txt

At some point I may post this same info in the Linuxcnc forums and add the info 
and files to the wiki.

I’d also like to thank Peter Jensen (www.tubeclock.com) who essentially rewrote 
my initial lame attempt at the component (Toolerator3000.comp).  My name is on 
it as the “author” but that is only to protect his innocence ;-)

-Tom

------------------------------------------------------------------------------
_______________________________________________
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users

Reply via email to