Been learning a lot about EMC watching Iggy's progress. It turns out there's a lot of knowledge about this on RCM. The discussions about desirability of tachs for EMC and latency problems make me glad I use a dedicated real time Galil motion controller. These cards can go cheap on eBay (can also go high). So, is anybody using a Galil card with EMC?
I'm also an I/O hog and use a 96 I/O card that hooks up to opto 22 isolated boards.
These also can go cheap (or high) on eBay. I've seen Linux drivers for this card on their CD. Same question, anybody using large digital I/O cards with EMC?
In short, I'm interested in EMC software but I'm not willing to give up on top end hardware.
Karl, the more I use EMC, the more it "grows on me", it looks like very well thought out piece of software, a lot of reliability related and safety related things are put in very carefully, and a lot of high performance related ideas are in it.
EMC is at linuxcnc.org and they have a forum. To date, all my questions were answered adequately.
As you know, I am not very knowledgeable myself, but the more I use it, the more I am impressed. (same applies to Jon's PPMC board)
As for tachs, I am not pretending to be an expert by any means, but it would seem that there is some benefit to them, as the drives close the velocity loop and help run things smoothly _even in case_ of software delays.
It took a while, but a light finally came on for me regarding this tach business. If I understand correctly, the system you're building runs the PID loop on the PC. The Galil, and similar industrial motion controllers, run the loop entirely onboard, and the loop update rate is very fast (faster than the response of the motor by a couple orders of magnitude) and independent of any processes that may be running on the PC.
I can see now that the tach feedback may be desirable if the update rate of your system is relatively slow and/or unpredictable.
Karl - I'm curious about how your systems run. What sort of program is running on the Galil card and what data is the PC passing to it?
I can see the tach helping when you don't have a dedicated motion controller. In standard mode, Galil runs the PID loop at 3K Hz. on the old cards. The new generation is over 10K Hz with a high speed option available. With a 50,000 ct. or more encoder, I'm sure there's no need for velocity or tach. mode on the servos unless you're doing something like a wire EDM to millions accuracy and feeds of .0x IPM.
Camsoft is the host software I use. It passes Galil motion commands to the card and reads back position and I/O information. Also reads a nearly unlimited amount of additional I/O. The host includes the logic control and operator interface. Camsoft is really a motion control and logic programming language or large set of macro commands written in VB6 and C++ with a few assembler routines. Its a bit complex to learn and extremely powerful.
Its also expensive, there would be a market for a EMC that could make full use of a galil card. But, I think this would be almost a total rewrite of EMC.
Tachometer feedback makes sense when your position measure is noisy, lacks resolution, just plain isn't available on the motor, is on the other side of some mechanism from the motor, or when your control electronics are pure analog. It also makes sense in the system that is posited here, i.e. with an outer controller that samples slowly and is remote from the inner loop (which is on the IMHO-misnamed servo motor "drive" in this case).
In fact, current technology for brushless servo motor "drives" is to use an encoder on the motor both for "tach" and for sinusoidal commutation. The one brand that I've worked with has a DSP on board that does some moderately heavy lifting, and has a full PID controller built in.
I did an analysis years ago, because an old experienced analog guy and I were in a fit of mutual frustration and incomprehension over a decision I was trying to make to leave the tach off a motor and just use a Really Good Encoder on the motor instead. The upshot of that was that _if_ it really is a good enough encoder _and if_ the controller is sampling often enough, then using a tach is entirely redundant.
(For some reason as a kid engineer I never fell into the trap of dissing the old guys -- maybe it's because I was lured into engineering by an uncle. Disagree with them, yes. Cross them, even to the extent of sneaking in methods that they had adamantly refused to consider, yes. But diss them, never -- I always listened to their advise with respect, and made sure that if I _was_ going against the grain that I had gone over my reasoning quite thoroughly, including going over all their objections twice or more.).
Karl Townsend wrote: So, is anybody using a Galil card with EMC? As far as I know, no. The whole idea of EMC is to move the servo loop into the PC. The Galil does the servo loop in the DSP processor on the card.
There is an EMC driver for the Vigilant (I think) I/O board.
Well, how do you define "top end"? Does that require a DSP processor on the board?
I think my PPMC is certainly an industrial-grade product. It doesn't make 96 I/O points easy, though, if you really need that much.
The PC handles the positioning loop, PID tuning, following error checking, etc. In the system Iggy is using, his velocity servo amps are doing the velocity and torque loops. But, with a 1 ms servo period (1 KHz) and a 10 us timing jitter, then that contributes about 1 % velocity jitter, the quantizing of the encoder is often worse than that.
Do you know that it was originally developed at NIST (National Institute of Standards and Technology) -- used to be NBS (National Bureau of Standards). They developed it and kept it open source for quite a while, before releasing it to the public for future development.
Yes -- but it was developed in particular by Ballistics Research Lab -- for other things than drawing parts for machine tools. :-)
It was used regularly where I used to work -- at an Army R&D lab. And for that, it was excellent.
I've not tried it for drawing parts, and have no idea how good or bad it is for that.
EMC stands for "Extensible Machine Control" and was designed so it could be adapted to new machines as they appeared. IIRC, it was used to control the "hexapod" machine -- with a really weird coordinate system. :-)
In case you don't know what hexapod is -- try picturing this:
Three rigid anchor points forming a triangle.
From each point a telescoping arm leading to the bottom of a powered spindle, and another leading to the top of the same spindle. (A total of six arms or legs).
The head is moved by shortening or lengthening these arms to move the business end of the spindle through whatever path was needed to make the workpiece, and the other end to tilt the spindle so the milling cutter could take on whatever angle was best for that cut.
Obviously -- the anchor points of the arms need to be *very* rigid, and the length control needs to be very strong and precise.
Though I haven't tried it, EMC2 is supposed to work with "Classicladder" soft PLC ladder logic programming. And IIRC, this can use Modbus among other I/O possibilities.
I use EMC2 with an Anything I/O board, this is a board with a FPGA (IIRC) that can be configured for about anything. There is an EMC2 configuration to use it for a 4 axis servo control board with some left over I/O points. The configuration includes some counters for the encoders so you don't miss anything between updates, I think Jon Elson's boards also use hardware counters, not depending on the PC to read every transition.
The tachometer feedback isn't required but it can have advantages. My lathe came with a non-working Anilam Crusader ML control, the tachometers were already connected to the working servo amps. The lathe uses encoders coupled directly to the ball screws, if a belt breaks I get a following error. One advantage of the tachometers is that they were already tuned to the amps, this made it pretty easy to get EMC2 parameters tuned in, I used just some P gain and a little I to handle offsets that seem to change with temperature, etc..
Another advantage I found with tachometers is they help keep the system stable even if it has backlash. My mill uses an Anilam Crusader II control, a future EMC2 conversion project, with tachometer feedback to the drives and has Anilam digital readout scales mounted on the table. I love this setup because it controls right off of table position, no need for lead screw error mapping or anything like that. When I first got the mill it needed some shims to get rid of table backlash, the ball screw would move about a half turn before it took up the backlash between the table and ballscrew. Without tach feedback it would have operated as smooth as a jack hammer, with the tach feedback if it was a half thou out of position the motor would turn slowly at a constant speed and remove the error, if the error was a whole thousandth, it would move pretty quick to remove the error, beyond that was too fast for me to notice. I figure if it could stabilize the system with perhaps 0.1" backlash, it should help with more normal maybe
0.001" backlash. I'm not sure if it would help but if I have to replace the Anilam DRO scales I would like to get something with a higher resolution, my lathe has 12,700 counts per inch, the mill has 2,540 counts per inch, I'd like to have maybe 2uM resolution for the mill also.
At work we have automatic tire balancers, around 10 or 11 balancers check the balance on around 25,000 tires every day. These balancers use a PC with a Galil motion control board. The Galil board they use goes in an ISA slot, it's getting difficult to find a compatible PC these days with ISA slots, when the PC quits working. We've been using Industrial PC's with an ISA backplane to replace the old PC's when they go out. I guess that's one disadvantage to something like the Galil board, when their interface become obsolete the upgrade can be expensive.
I run my lathe with a ~$35 PIII 800Mhz that I got from eBay, with shipping I have around $75 in it. I haven't done latency testing on it or anything, all I know is that it seems to work great.
Im paying $500 for industrial pc boards..mostly Intel. Any idea of what you guys are giving for them?
One could not be a successful Leftwinger without realizing that, in contrast to the popular conception supported by newspapers and mothers of Leftwingers, a goodly number of Leftwingers are not only narrow-minded and dull, but also just stupid. Gunner Asch