LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

synchronize multiple devices (NI PCI-6733 and NI PCI-6031E )

Hello,

 

I am trying to synchronize multiple devices. I am using NI PCI-6733 to generate analog signals and NI PCI-6031E along with SCXI 1531 signal conditioning system to acquire the input analog signal. I found the third example in (Help»Find Examples»Hardware Input and > Output» DAQmx» Synchronization» Multi-Device) very close to our application.

 

First of all, I have physically installed the RTSI bus cable successfully, and configured it in MAX as well. However, I am facing a problem in setting up the synchronization tasks (Error -200452). Please refer to the attached figure. We are using NI PCI-6733 to generate analog signals and NI PCI-6031E via SCXI 1531 to acquire signals. What is the proper "Reference Clock Source" and "Reference Clock Rate" should I use please? I have tried all possible clock sources from Dev1/RTSI0-RTSI7 to Dev2/RTSI0-RTSI7 and all others, none of them works. Furthermore, I have changed the clock rate from 1e8 to 1e6 and also down to 1e3, but yet nothing seems right. I need your help please.

 

Thank you very much

0 Kudos
Message 1 of 13
(3,297 Views)

The Sync VI in your post, is that something you've written? The error code being thrown here means that there's a property node attribute in use that is not supported by the DAQ device. Essentially this means that it's not an issue you can correct by changing the value of an input.

Product Support Engineer
National Instruments
0 Kudos
Message 2 of 13
(3,283 Views)

I was able to find the Sync VI. I notice, however, that on this example there's a requirements list on the bottom right edge of the example finder. Are you sure you're meeting these requirements?

Product Support Engineer
National Instruments
0 Kudos
Message 3 of 13
(3,282 Views)

Hi JamesD

 

Thank you very much for taking time to answer my request. You are totally right, I am not meeting the example hardware requirements.

 

However, I have understood that there are two types of synchronization approaches (i.e., multi-functions and multi-devices). Multi-functions synchronization approaches is used to synchronize two or more channels (input/output) in one single device. Fortunately, NI PCI-6031E has 64 AI and 2 AO channels. Thus, I implemented this approach as shown in the attached figure (one AI and one AO from NI-6031E). The good thing is that the VI runs without errors, however, I could not see any generated signal. Could you please help?

 

Many thanks for your help and support.

 

Bahdoor

0 Kudos
Message 4 of 13
(3,266 Views)

Are you trying to read your generated signal written to A0?  If so, you don't have that data being read anywhere. You will need to add a read function send that data to an indicator.  If you are refering to AI, I would test that channel in MAX and make sure it is still recieving signal.

 

 

0 Kudos
Message 5 of 13
(3,254 Views)

Hi Allie F

 

Thank you very much for your advice. The problem was solved by setting the input signal to RSE mode (see Figure 1). However, four more issues have been appeared.

 

FIRST:

Attached Figure 2 shows the AI/AO signals, the red signal shows the AO and the white is AI. As clearly seen, the AI did not fully synchronize with the AO. Further, it has a weird response (becoming constant) after few milliseconds.

 

SECOND:

The physical AO channel does not show any generated single. I have checked the AI and AO physical channels and they are not damaged or malfunctioning!!!

 

THRID:

When I try to run the VI one more time, the AI is always zero; it is simply not acquiring any signal. That might be there is no signal output from AO channel.

 

FOUTHR:

How can one add delay to the signals (e.g., delay AI acquisition few milliseconds)?

 

I need your help, please..

Thank you very much

 

Download All
0 Kudos
Message 6 of 13
(3,240 Views)

Just to experiment, can you try and run that Example VI you refered to in your first post? See if your AI acquires data accurately?  If this one works, compare the two VIs' code and see where the differences lie.  Also, in this example "Multi-Device Synch AI and AO-Multi rate- Trig Skew Correction.vi" they utilize a trig delay property node. This may do the delay you're looking for.

 

Maybe also increase your samples to read. What it looks like is happening is the waveform is written to AO, but AI doesn't have enough samples to read. When AI hits it's last recieved value it's going to keep repeating it. Try different samples to read values.

 

Another idea, try continuous samples instead of finite samples.

 

Let me know if any of that leads to new information.

 

Allie

 

 

 

0 Kudos
Message 7 of 13
(3,225 Views)

Actually, what I think is happening is that the AO task is clearing before it is done generating, and therefore its outputting the last value that was on that line.  Try using the DAQmx Wait Until Task Done.vi to prevent this.

 

Hope that helps!

 

Allie 

0 Kudos
Message 8 of 13
(3,218 Views)

Hi Allie,

 

I have added the DAQmx Wait Until Task Done.vi. It is working now as expected, the generated and acquired signals are synchronized.  

 

Thank you very much for your time and support.

 

Bahadur

0 Kudos
Message 9 of 13
(3,202 Views)

Hi Again Allie;

 

I would like to thank you for your continues support and help. Currently, I am working on developing a VI for multi-functions synchronization with single sample using NI PCI-6031E, as seen in the attached figure. I have noticed that the input signal frequency is keeping changing (decreasing) after few minutes from VI execution. The VI stops working when this frequency change is detected by “Finished Late? [i-1]”, is there any way to keep the frequency constant with time? I have also used “While loop” with "Wait.vi" and "Wait until next ms.vi", but, unfortunately, I got the same problem. Your help is highly appreciated.

 

Thank you very much for your time.

Kind Regards

Bahadur

0 Kudos
Message 10 of 13
(3,175 Views)