11-22-2006 09:09 AM
Hi Simon,
The lockups *might* be attributable to the command string issued in Default Instrument Setup.vi. I saw this last month, and have a newer version that eliminates code for setting up a GPIB service request (this code was carried over from an older driver). See if this helps... The Wait for Acquisition Complete rapidly queries a register, and having the service request set up seems to cause some interference and a possible lockup. This newer version of Default Instrument Setup.vi. is part of the next rev of the driver.
Your Fetch Waveform_modified VI is similar to a example that I plan to create called "Transfer data" that simply reads back the data and does not perform any setup or trigger operations. Note that if you do not change any scope settings, the call to Get Descriptor can be pulled outside of the loop, since the vertical offset and vertical gain won't change... Also notice that Horizontal Offset is returned by Get Descriptor!
Best Regards,
Alan
11-22-2006 10:06 AM - edited 11-22-2006 10:06 AM
Message Edited by svif on 11-22-2006 10:08 AM
11-22-2006 11:06 AM
11-23-2006 02:01 AM
Thaks for your reply
The communication seems to work better with the new string in defalut setup.
The new Get Descriptor needs an additional subvi called "lcwave decode trigtime".
There is one problem with my current program (attached). In the program I fetch waveforms as fast as the loop can run, check if the "n" fetched waveform is the same as the "n-1", if not it is added to a total waveform. After the loop I divide by the total number of waveforms to get an average waveform.
This is not running quite as fast as I would have thought. When setting the scope on 1mys/division and 1ns/point = 10000points and a trigger at 200 Hz, it takes 5 seconds to run through 200 waveforms (eg 40Hz acquire rate). The odd thing is that the "bad waveform" number (the counts where two acquired waveforms are identical) is 160, indicating that a total of 160 times the same waveform has been acquired twice. This seems odd since the total number of loops in 5 seconds is 360 which is much lower than the number of measurements on the scope, which should be 1000.
Can I reduce the number of points with a write? For instance stay at 1mys/division but set 5ns/point or something like that?
That would speed up the vi loop and also reduce the communication load - and it would be points enough for my propose.
Sorry for all the questions, it seems like I could really use a detailed manual.
Simon