08-06-2007 04:23 AM
We are trying to solve the following problem with the help of a NI PCI-5421 signal generator with 256 MB of onboard memory:
- the NI PCI-5421 is used to generate an analogue input signal in order to control a piezo–driven fast-tool-servo
- the fast-tool-servo is used in a CNC-lathe for turning of microstructures
- the rotary encoder of the CNC-lathe is generating around 18.000 trigger-signal per revolution
- for each trigger, the signal generator should output a new voltage
- the voltages are encoded as 16 Bit values
- the microstructure structure which should be turned consists of ~3.000 tracks
According to our calculations, the amount of memory required is:
18.000 trigger * 3.000 tracks * 16 bit = 864.000.000 bit = ~103MB
As a start we used the following configuration for the signal generator:
arbitrary sequence mode (NIFGEN_VAL_OUTPUT_SEQ)
with burst trigger mode (NIFGEN_VAL_BURST)
For each input value a new waveform was created using niFgen_createWaveformI16. All waveform were then combined to an arbitrary sequence (niFgen_configureArbSequence).
The first problem we encountered was that each waveform requires a minimum of 8 samples to be used in burst trigger mode. Therefore we have reduced the number of triggers to stay within the memory limitations:
4.000 trigger * 3.000 tracks * 16 bit * 8 samples = 1.536.000.000 Bit = ~184MB.
For small test vectors (e.g. 4000 triggers, 10 tracks) the systems reacted as we had planned: for each (software-trigger) the signal generator emitted the right voltage level.
As we tried
bigger test vectors (>400.000 waveforms) the memory used by the test
application rose to >2GB after running niFgen_createWaveformI16 and
completely froze the computer. Without creating the waveforms the memory used
by the application stayed within our calculations.
Is there a possibility to store such large sequences on the NI PCI-5421?
How much memory is really used while generating sequences on the signal
generator and can we somehow read out the amount of onboard memory which is
currently used?
Would it be possible if we used another mode of the signal generator (e.g. script mode) to react to the trigger signals?
Or could the sequence be divided into multiple smaller sequences which fit into the onboard memory? (the problem with this solution would be that we cannot stop the process to upload a new sequence as we need a continuous output)
We hope that you could help us finding a solution to our problem.
Regards,
B. Sc. Lars Schönemann
Stiftung Institut
für Werkstofftechnik
Hauptabteilung Fertigungstechnik
Laboratory
for Precision Machining (LFM)
Badgasteiner Str.2
D-28359
Tel.:
++49-(0)421-218-9400
Fax: ++49-(0)421-218-9441
Email: lars@informatik.uni-bremen.de
Web: http://www.iwt-bremen.de/ft/
08-06-2007 10:04 AM
08-08-2007 07:40 AM
08-08-2007 09:54 AM
08-08-2007
10:56 AM
- last edited on
01-10-2008
11:14 AM
by
Support
Hi Lars,
Here are some more resources to help you get started on scripting....
Video webcast:
http://zone.ni.com/wv/app/doc/p/id/wv-64
App Note:
http://zone.ni.com/devzone/cda/tut/p/id/5534
Regards,
08-09-2007 05:23 AM
08-09-2007 10:45 AM
08-09-2007 11:27 AM
08-27-2007 03:54 AM - edited 08-27-2007 03:54 AM
Hello
again,
I tried to solve my problem in script-mode, however there I encountered new problems.
As one single script would be way to memory extensive, I tried the following:
This works for a couple of times, but eventually I will get the following error-message:
27.08.2007 10:40:55: Space available: 6464
27.08.2007 10:40:55: write next: DAQmx Error -200311 occurred:
You cannot write data outside the boundaries of your waveform.
For testing purposes I used the following sizes:
Initial Block: 80.000 samples
Reload Blocks: 6.400 samples
The size of the subsets is not a problem as the sample rate is pretty low. Therefore I do not get an underflow-error.
I hope you can help me with this.
Regards,
Message Edited by SysEngineer on 08-27-2007 03:55 AM
08-27-2007 05:29 AM