LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

ni6281

Hi everyone, 

I'd like to send a signal in a water pipe system and the signals will be converted to wave signals by transducers. At the end of water pipe I have another transreceiver that it will read signals and I'll be sampling them at range of 200Khz. There were some inconvenience:

1-)Memory allocation 

2-)Syncronization problem with transmitting and receiving part

 

The problem with memory allocation might be solved with using producer-consumer structure as you could see in the attached file. However, this program is only saving 1 second of data into one file. I want to improve that to up to 1 minute. I added a control to wait function but this time it's creating file according to my control but writing the datas only in 1 sec. Could you guys help me on that? 

 

As for the second part, I would like to send my own function as a signal so I plan to use mathscript structure. However, the issue with this part is that I need to syncronize it with receiver part and they should have a same clock. I also need to see the time difference between the signal that's transmitted and it's received. 

 

Any suggestions? 

Mecit

0 Kudos
Message 1 of 4
(3,003 Views)

Few concerns on the code?

 what is the pupose of "Folder Name Sequencer Loop"  really looping concept is required for creating a path?

Create Queue with Proper Name

Better to use Wait until next milli second instead of wait

You can use Loop iteration  value for file name instead Shift register

you can use single stop button for stopping both loops

 

 

 

 

----------------------------------------------------------------------------------------------------------------
Palanivel Thiruvenkadam | பழனிவேல் திருவெங்கடம்
LabVIEW™ Champion |Certified LabVIEW™ Architect |Certified TestStand Developer

Kidlin's Law -If you can write the problem down clearly then the matter is half solved.
-----------------------------------------------------------------------------------------------------------------
0 Kudos
Message 2 of 4
(2,977 Views)

I have modified to the following version. I have got a problem with this one, I can't use the dt_TR points as the sampling points. I wanna have a plot of syncronized time for both receiver and sending side so that I can see the time difference between the first signal send and first signal received. 

Do we have similar examples that I can follow? 

0 Kudos
Message 3 of 4
(2,926 Views)

Hello agungor,

 

Briefly looking at your code and application. I think the documents below may possibly help.

 

Synchronization Explained - http://www.ni.com/white-paper/11369/en/

 

Getting Started with DAQmx: Synchronization in NI-DAQmx - http://www.ni.com/tutorial/5471/en/

 

One thing that I did notice is that in your code you use the DAQ assistant. While it might be simple to set up things using that VI, I would suggest that if you need more explicit functionality like timing and sync you might fare better with DAQmx VIs.

 

Also be sure to check out the shipping examples in the NI example finder which talks about timing and sync functions and methods.

JY
Application Engineer, RF and Communications
National Instruments
0 Kudos
Message 4 of 4
(2,887 Views)