From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

Measurement Studio for .NET Languages

cancel
Showing results for 
Search instead for 
Did you mean: 

plot slowdown in "Synchronize Two AI Continuous" example

I am running the "canned" sync two AI continuous example

i have tried different combinations of samps/ch and rate

but after working normally for about 10 to 20 seconds
the plotting slows to a crawl
maybe an update every 10 seconds


then when I try to click the UI's acquisition switch to off,
the program appears to hang "NOT RESPONDING"
at this point, the synctwoAI.. process is 0% CPU and about 45MB
and the devenv.exe is 0% and 40MB..

all the other examples I have tried work great


i am running vb.net 2003 with studio 8.0
and PXI-6254 boards in a 1042 with MXI-4

thanks
Philip Newman
General Dynamics
Electric Boat
0 Kudos
Message 1 of 9
(4,159 Views)

Hello Philip,

I know that you have tried other examples, but specifically did you try another "DAQmx with UI" synchronization example?  Also, do you have C# available to try running this example?  I will see if I can reproduce this problem.

Let me know,

Laura

0 Kudos
Message 2 of 9
(4,140 Views)
".... did you try another "DAQmx with UI" synchronization example? "


I have tried SyncAIAOUsingDigTrigger. The error is attached. (error.zip)

I am using the BNC-2090 Jbox. I have a 1v square wave in PFI0/Trig1 and a 1v sinusoid in ai0.

I added a PXI-6259 to my 1042 to get an analog out channel.


Message Edited by serpos on 12-06-2005 07:32 AM

Philip Newman
General Dynamics
Electric Boat
0 Kudos
Message 3 of 9
(4,125 Views)
"....Also, do you have C# available to try running this example?"

I have tried the C# example and I observe the same behaviour.

Plot slowdown after 10800 samples.

I try to slide the acquisition switch to OFF and I get an hourglass forever
so I have to "endtask" in windows.

----------------------------

I noticed this "slowdown" three days ago.
Thinking it might be related to my studio  8 upgrade.
I uninstalled 8 and reinstalled 7.1.
Same problem so I ran the studio 8 setup over the existing 7.1 installation.
I never tried running the example before the studio 8 upgrade arrived.




Philip Newman
General Dynamics
Electric Boat
0 Kudos
Message 4 of 9
(4,122 Views)

Hello Philip,

The error message you attached seems more like it has to do with the trigger not being received than the problem you are experiencing with the other example. 

I have not been able to recreate the problem with the hardware that I have (no MXI currently).  I am interested in finding out at which function call the code freezes at.  Could you set breakpoints in the code for the acquisition switch to find out what particular line the freeze occurs at?  If it does not freeze in this portion of the code, check the StopAcquisition function. 

Thanks,

Laura

 

0 Kudos
Message 5 of 9
(4,105 Views)
In synchronizetwoAIContinuous example:

i am using M-series (PXI)
Dev1/ai0
Dev2/ai0
200 S/ch
1000Hz
Synch to "on"
Acquisition to "on"

i let it sample to 1200 samples then slide Acquisition to "OFF"
it takes 20-30 seconds for the Acq to stop
after 20-30 sec, the RX and TX lights on my MXI-4 turn off
and the Acq switch slides over to "OFF" position (seems to be normal)
since i did not let it sample to 10800 samples(where it slows down)

stepping thru...it appears to be the slave.dispose that takes ~10 to 20 sec to execute
master.dispose is less than a sec to execute

so i give it 30 seconds to stop Acq
now I slide the Acq back to "on" (I have not restarted the app at this point)

the slave window displays my waveform from  0 to 200 and quits [RX/TX are extinguished]
master chart control is blank with the x axis displaying 1000-1200 (where i stopped Acq on the first run)
so the master waveforn control was never reset

so now i try to slide ACQ to "off"

seems to hang forever

have to kill the window and do an "F5" to get the app to sample again



Philip Newman
General Dynamics
Electric Boat
0 Kudos
Message 6 of 9
(4,095 Views)
RE: Synchronization

FYI: The multidevice AIFiniteAcquisition works fine.
Philip Newman
General Dynamics
Electric Boat
0 Kudos
Message 7 of 9
(4,091 Views)

Hi Philip,

I was able to get some hardware and test this example program more thoroughly.  It turns out that I was able to see the slowdown and get the program to freeze just not for the exact same conditions as you.  Also, I can also get the behavior using simulated devices instead of hardware.  I did some troubleshooting on the program, but could not figure out exactly where the freeze is coming from.  I am going to see if I can get some more information on this.  In the meantime, can you take a look at one of the other synchronization examples and modify it?  Perhaps take this example:

C:\Program Files\National Instruments\MeasurementStudioVS2003\DotNET\Examples\DAQmx\Synchronization\Multi-Device\AIFiniteAcquisition

and modify it to be continuous?

Thanks,

Laura

 

0 Kudos
Message 8 of 9
(4,066 Views)

".........In the meantime, can you take a look at one of the other synchronization examples and modify it?  Perhaps take this example:

C:\Program Files\National Instruments\MeasurementStudioVS2003\DotNET\Examples\DAQmx\Synchronization\Multi-Device\AIFiniteAcquisition..."


ok
thanks

Philip Newman
General Dynamics
Electric Boat
0 Kudos
Message 9 of 9
(4,060 Views)