Nilsson
Nilsson

Reputation: 11

Reading data from multiple sensors without repeating the code for each device

I have several pressure sensors in my setup and I read the data into labview. Is it possible to do this without writing the initialization code for each device seperately? It is exactly the same for each sensor...

Upvotes: 0

Views: 352

Answers (1)

SilentCloud
SilentCloud

Reputation: 1975

@Adrian already answered to your question but I'd like to provide some more details.

I'd suggest that you create a subVI. Basically, you will have a piece of code where you define inputs and outputs and how to manipulate them. Then you can re-use whenever you need (similar to a function in other programming languages). Here is the official NI guide, where you can find all you need.

Upvotes: 1

Related Questions