On Fri, Mar 21, 2008 at 01:46:24PM -0400, Patrick Ferrick wrote: > Apparently, a PLC (either hardware or software based) is > traditiuonally used for such purposes. It seems to me, though, that a > plc + ladder logic programming is capable mainly of sensing switches > and turning on and off relays...which is great if you have a > toolchanger that only needs to be told _when_ to change tools and > _what_ tool to use, but not how to physically spin steppers to > accomplish this. I would really like to be able to take advantage of > the kinematics etc. that EMC provides to move the extra steppers, but > it's looking like I might have to create a "semi-smart" toolchanger > that can be commanded with HAL+ClassicLadder.
If you use HAL+ClassicLadder you have a lot of options not available on a generic PLC. For instance imagine a turret that you want to turn to one of four positions. Set a mux4's inputs to the preset positions. Feed the mux's output to a stepgen. Set stepgen's accel limit, velocity limit, and scale to match your motor. Suddenly you can move the motor smoothly to one of four preset positions. If you use a comparator block to compare that stepgen's commanded and feedback positions, you know when it gets there. A little synchronization with ladder and you have a tool turret. Note this scheme gives you positional control of the stepper. This means you probably need some way to "home" the turret, which would most easily be done by starting up with it already in a certain position. If you don't want to worry about that, you can use stepgen in velocity mode instead of position, and use ladder to coordinate that it turns until a certain feedback happens. Maybe after that feedback happens, it has to do another thing to lock into place. Another sensor could verify the lock before EMC gets the signal that the tool change is complete, and continues. There are so many possibilities. By putting together these simple building blocks you can do whatever your hardware requires. If you don't have the "block" you need, you can pretty easily add it. Chris ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users