LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Data reduction min, max

Hi,

            I’m trying to write a data acquisition program for our rolling mill. I’m new to labview and some of it’s methods are still causing me a bit of grief. I have a series of sensor producing 4-20 milliamp current loops. I get the raw data working fine. I’m using some of that data to drive a basic state machine which I want to use to control the data acquisition, reduction and then write the data to a oracle database. This program will run continuously so I need to only collect data when a bar is present and on a pass by pass basis. The attached vi uses two inputs to generate states 0 = idle, 1= new entry, 2 bar in mill, 3 bar finished write data, and then back to idle and so on. My question is how do I put the data into a array so that I can do some reductions like max speed and  mid pass load peak. Whatever I’ve tried  won’t work concurrently with the main while loop. Any help would be greatly appreciated.
0 Kudos
Message 1 of 4
(3,204 Views)
Hello,

I didn't understand everything. So I'm giving you some tips that maybe can help you out.

1 - If you wanna do those operations after the while it's stopped. You only have to wire the data to the while loop bondery. Automatically the output it's an array.

2 - If wanna  do it  inside de loop.  You  can use  shift  registers. initialize it. then inside the loop use build array. One input it's the current data and the other it's the left shift register.

See the vi made on labview 8.2.

PS: always say your labview version. So we can see if we can send you an example.
Software developer
www.mcm-electronics.com





PORTUGAL
0 Kudos
Message 2 of 4
(3,186 Views)
 

Hello,

I think Jorge makes some great suggestions. I, myself, am still a little unclear on the functionality you are seeking but if you simply mean to build an array of your data, I think Jorge steers you down the right path.

In addition, you might also consider taking a look at the following DevZone article. It describes programming techniques in LabVIEW for state machine design. Moreover, there's a State Machine Toolkit that will automatically generate LabVIEW code for any given state machine logic.

Good luck with your application.

Emilie Kopp | Applications Engineer | National Instruments

0 Kudos
Message 3 of 4
(3,175 Views)

Hi

Thanks for the replies. Sorry I've not made myself clear. I'm running version 8.2 What I want to do is this the various analogue input will be coming in continuously. That bit is working fine.  In a steel mill a piece of steel is passed back and forth through a mill to change it’s shape to whatever is required. I want to record data (max , average and whatnot) for each pass. I want to know how to make a while loop that will collect data for each pass. The vi I attached does the collection fine it also uses the input to work out when a pass starts and when it stop. I can’t work out how to add a data reduction function that will work simultaneously with the pass detection function. I can trigger the start but then it just loops and doesn’t stop. I can guess it’s something simply I missing here, but I’m missing it none the less.

PS I also need to be able to count the pluses coming from the latch vi to count the pass’s.

0 Kudos
Message 4 of 4
(3,145 Views)