On Thu, 2008-07-03 at 00:21 -0400, Olivier Henley wrote:
> Hi to all,
> 
> My question is concerning motor controllers. For my own good reasons, I don't
> want to buy a commercial controller, but design it myself using material,
> information I found in scientific literature and, of course, internet.
> 
> With all the design propositions I studied, I need confirmations about a
> roadmap, I believe, possible. Let's say a dc drive.
> 
> EMC2 offering real-time capabilities (real-time kernel), can it send PWM 
> (pulse
> width modulation) to a H-bridge drive using PWMgen, receive counts from a quad
> encoder and calculate a PID controller to modify the next outgoing PWM. One
> channel of output (PWM), one channel of input (encoder) and compensation
> calculations (PID) in pc.
> 
> What about cpu overload, how many axes do you think a recent pc could handle
> this way, what about latency, does the communication protocol between the pc
> and the controller is critical?
> 
> If this configuration is possible, I think the controller becomes much easier 
> to
> build. A H-bridge, an analogue current limiter (shunt resistor), filtering
> and/or isolation of signals, and if I don't forget a main feature, that's 
> about
> it...
> 
> Last question. What would be the best tool to handle the quad encoder input
> signal? Is there a pretty close HAL setup I should look at to hack in case my
> setup would be viable?
> 
> Thanks in advance,
> 
> Olivier H.

EMC2 has most of what need, built in. It translates motion commands
(g-code) into axis (joint actually,) outputs with the option of
modifying the output based on feed-back. EMC2 has a quadrature encoder
input module as well as a PWM output module that uses the parallel port.
EMC's structure is described here:

http://wiki.linuxcnc.org/cgi-bin/emcinfo.pl?EMC_Components

In this diagram:

http://wiki.linuxcnc.org/uploads/EMC_Control_LG.gif

everything except the encoder, motor, power amp and limit switches is in
EMC.

A simple example is here:

http://emergent.unpythonic.net/projects/01142347802

You can get reasonable performance in a larger machine by just scaling
this system up. For high speeds and/or high resolution the parallel port
will not be able to keep up, so a parallel port or PCI/ISA based
controller with fast encoder counters and signal generators can be used,
but the basics are the same. See here for hardware that works with EMC:

http://wiki.linuxcnc.org/cgi-bin/emcinfo.pl?EMC2_Supported_Hardware

The above is over simplified, but may help get you started.

-- 
Kirk Wallace (California, USA
http://www.wallacecompany.com/machine_shop/ 
Hardinge HNC/EMC CNC lathe,
Bridgeport mill conversion, doing XY now,
Zubal lathe conversion pending
Craftsman AA 109 restoration
Shizuoka ST-N/EMC CNC)


-------------------------------------------------------------------------
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08
_______________________________________________
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users

Reply via email to