Motion Control and Motor Drives

cancel
Showing results for 
Search instead for 
Did you mean: 

fast scanning and counting with piezo stage and PCI 7344

Hi,

 

I'm programming a 3-axis piezo stage to do fast scanning (128x128 points in ~ 5 seconds) with a PCI-7344. The contour trajectory can only be updated every 10 ms, so it is too slow for my application. Due to synchronization constraints I need hardware scanning synchronized with some internal clock instead of software scanning using a set velocity and accelleration. I am considering using one of the PWM outputs (40 kHz max) of the Digital I/O port to synchronize my counting card with the motion card, but I can't find a way to make the x-axis do hardware scanning quickly and in sync with the PWM clock. Any ideas? Thanks a bunch,

 

Daaf

 

An addition: if I could get a hardware sine output with specified frequency, offset and amplitude synchronized with the PWM clock that would do the trick already. A sawtooth or rounded sawtooth would be even better. Thanks

Message Edited by Daaf on 02-24-2009 11:35 AM
0 Kudos
Message 1 of 10
(4,943 Views)

Daaf,

 

the PWM output is just a static output that can be adjusted in software only. A typical usecase for these outputs is setting the intensity of a laser or limiting the current of a servo drive (some drives support this feature). You can't use these outputs for any synchronization tasks.

 

In fact my answer to your question is almost the same as in this thread, that I have answered yesterday: You are probably using the wrong hardware for your task. As mentioned in the other thread, SoftMotion could be a good solution, but maybe also a multifunction DAQ board with analog outputs and synchronized digital outputs could do the job if open loop control is enough for your application. Otherwise an FPGA-based solution is probably the best option for you.

 

Kind regards,

Jochen Klier

National Instruments

 

Message Edited by Jochen on 02-25-2009 08:51 AM
Message 2 of 10
(4,931 Views)

Hi Daaf, Jochen,

 

It seems that we are now already two with the same problem.  😞

 

I have spent the last 6 months to test all possible ideas, to fasten this motion functions. I have established that Jochen is right about chosen hardware. So long as you are satisfied with on-board PID control is card functioning O.K. As soon as you decide to implement some of your own things, card becomes a bad selection.

 

I have come to some control algorithms that can fasten motion control for individual tasks under certain conditions. But this is still not that what is should be.

 

Because I have spent too much time in developing the rest of the hardware in the whole system, I am thinking to upgrade my system with FPGA card (not to change motion controller card with FPGA).

 

Jochen, if I decide to upgrade my system with PCI-7833R card, will I be still able to use motion functions? As example: I have been thinking that I would read encoder inputs with FPGA card and saving them in global variable. For example A-channel of encoder would be saved in variable A, etc.. These variables would be than an input into “read encoder position” function. "Read encoder poition function" would run on the host computer inside my individual control tasks. Will communication between FPGA card and processor on the host computer run faster in this case?

 

Daaf, if you want you can contact me. Perhaps we can share our experience with this equipment, join the powers, and together find some solutions for our problems. As I see we are both working with the same family of motion controllers and piezo stages?

 

Regards,

Gregor

  

0 Kudos
Message 3 of 10
(4,910 Views)

Gregor,

 

the NI-Motion API works only with NI 73xx boards. If you want to use an R-Series board, I strongly recommend using the NI SoftMotion Development module. Otherwise you will have to implement the complete control algorithm on the FPGA by your own.

If you want to run the control algorithm on your PC (should be a real-time system then), you don't need an FPGA board at all, but a multifunction data acquisition board with analog and digital I/Os and counter inputs for your encoder signals.

 

Regards,

Jochen

Message 4 of 10
(4,907 Views)

Jochen,

 

Can you recommend some multifunction data acquisition board? I am controlling piezo stage with 5 axis. There are 80 digital inputs/utputs

and one analog input in my system.

 

Tnx,

Gregor

0 Kudos
Message 5 of 10
(4,903 Views)

Gregor,

 

for a reasonable recommendation I need some more information from you:

  1. What are the required voltage levels for your analog and digital I/Os?
  2. What's the maximum sampling for output frequency for the I/Os?
  3. Which type of signals do you need to generate on the DOs and how are the timing specs (e. g. pulse trains, PWM signals,...)
  4. How many digital lines do you need for which type of signals?
  5. What's the required resolution of the analog input?

Please add whatever application specific information might be useful.

 

Thanks,

Jochen

 

Message 6 of 10
(4,900 Views)

Hi Jochen,

 

I am controlling Piezo stage with 5 Axis. Each axis has:

 

- 2 outputs for STEP/DIRECTION signal (TTL + 5V/0V),

- 5 outputs for setting different axis modes (TTL +5V/0V),

- 1 output for enabling HOME switch (TTL +5V/0V),

 

- 3 inputs for encoder signal A,B,Index (TTL +5V/0V),

- 3 inputs for limit switches (TTL +5V/0V),

 

All together there are 70 axis specific I/O-s.

 

Another 10 digital I/O-s are used for switching ON/OFF some other actuators. They are working on TTL level (+5V/OV).

 

Analog input is used for monitoring a temperature over PT1000 based sensor. This input is not so important and I can change

it with some digital-temperature sensor.

 

Card should be in PCI format, because it is integrated in RT-PC desktop target. PC is connected in local network. Axis positions

are all the time transmitted over the network in form of UDP protocol. We have a fire-wire camera connected to this PC to.

 

If I summarize, PCI 7356 card would cover all my needs if it would allow me to implement my own control algorithms (such as fuzzy logic,

neural control techniques, genetic algorithms…).

 

And this would be it….

 

 

Tnx,

Gregor

0 Kudos
Message 7 of 10
(4,858 Views)

Gregor,

 

thank you for posting these specs. After reading them I think I have to revise my judgement. Using a DAQ board could be possible, but it would be very cumbersome. The reason for this is the fact, that your application requires a significant number of outputs that need independant hardware timing. With a DAQ board the digital I/O performance (sampling/output rate) should be enough for your application, but as the only option is to run all hardware timed input and output operations in a single I/O data stream, it will be quite difficult to implement the I/O handling for your axes.

 

So this brings me back to the proposed FPGA solution. I strongly recommend to implement all time critical parts of the application on the FPGA itself. At least you will have to run the step/direction output generation and the feedback signal reading and home switch monitoring on the board. The communication between the FPGA-board and the PC can be done through DMA transfers and/or with IRQ synchronisation. This is pretty fast (100 to 1000 times faster than the host to board communication with a 7356), but for precise I/O operations and higher velocities you still will need to run the I/O tasks on the board.

 

I recommend using a PCI-7813R that provides 160 digital I/Os, that can be operated independantly from each other with rates up to 40 MHz. This board comes with a 3M-Gate FPGA, which is capable of controlling at least 6 axes with closed loop control.

 

I hope that helps,

Jochen

 

 P. S.: As this board doesn't provide analog inputs, you should switch to a digital temperature sensor. This will be much cheaper than using a PCI-7833R.

Message Edited by Jochen on 03-02-2009 09:37 AM
Message 8 of 10
(4,855 Views)

Thanks Jochen. That would be it. I was thinking about same card. Can you just answer me two more questions?

 

If I have correctly understood, I need “Soft motion module” for programming recommended FPGA card. Is this module available under “academic license”? Does this module include functions for encoders and stepper outputs?

 

Thank you very much,

Gregor

0 Kudos
Message 9 of 10
(4,848 Views)

Gregor,

 

the answer is a big YES. The SoftMotion module is part of the academic site license and it comes with a step generator and encoder IP.  The SoftMotion module is not mandatory, but it makes a lot of things much easier. For steppers the step generator and the trajectory generator are the most important benefits. At the first glance SoftMotion code looks quite complex, but in fact it's not too hard to understand and it saves you a lot of development time.

 

Jochen

Message 10 of 10
(4,846 Views)