Signal Conditioning

cancel
Showing results for 
Search instead for 
Did you mean: 

Multiplexing Analog Signals

Hello NI Community,

 

I am a student at a technical college enrolled in an introductory Labview course. I am working on creating a weather station using the NI myDAQ unit, Labview and multiple analog sensors. I am trying to utilize a multiplexer to read four different analog signals from a single analog input port on the myDAQ unit. Within Labview I have created individual programs to recieve and interpret all of the individual analog signals, but am having trouble integrating the multiplexer and code for all analog devices. I have contemplated using a "sequence structure" or "timed sequence structure" to cycle through and read the different signals but have had no luck. To select which analog signal is read from the multiplexer, a three digit binary number is applied to the select pins of the multiplexer. I assume I would need to utilize the output daq assistant to select the channel? I am new to Labview and unsure what to try next. If there are any existing VI's that would apply to this application please let me know. This is my first post to the forums and appreciate everyones help and patience.

 

Respectfully,

Torrie W.

 

0 Kudos
Message 1 of 2
(5,765 Views)

Torrie W.,

 

Welcome to the Forum.

 

This post would probably be better suited to the Multifunction DAQ board or the main LabVIEW board.  Signal conditioning usually applies to amplification and and filtering. While multiplexing could fall into that category, your question is really about how to manage the issue in LabVIEW.

 

It is generally best to avoid the sequence structure. It defeats the inherent parallelism that the LV dataflow paradigm provides.

 

While the DAQ Assistant may be adequate for this application, take a bit of time to learn to use the regular DAQmx driver VIs. They are much more flexible and are not limited to the options provided by the configuration dialog.

 

I suggest that a state machine would be a better architecture. It is widely used and considered a best practice for many kinds of problems. You could have states to Initialize the Analog Input and Digital Output, Write to Digital Output, Read Analog Input, Analyze Signals, Save data to File, and Shutdown DAQ sessions. Other states mihg include an Idle state, a Wait state if a time delay is required, Error handling states, and so on.

 

Depending on your version of LabVIEW there will be examples, Design Patterns, or Sample Projects to get you started.

 

Lynn

 

Lynn

 

0 Kudos
Message 2 of 2
(5,756 Views)