LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

trigger event. 2 data streams.

Hi I am on a very steep learning curve with labview. has been fun so far.

 

Here is what I am trying to do

 

I have a 9237 4 channel full/half bridge daq device. and on each of these channels there is a load cell.

I also Have a 4 antenna UHF RFID reader that is running via a serial connection to labview.

 

I would like to attach measurements on the load cells to the rfid tag id number each time a individual tag passes near the load cell

 

It seems to me that because I can Identifie load cell 1 which is in proximaty to antenna 1, load cell 2 which is in proximity to antenna 2 ect... I should be able to take measurements off load cell 1( for example) and attach it to the rfid tag # that is in the feild during the event.

Right now what I have is 2 seperate incoming data streams

The load cells are a fairly simple configuration with a weigh bin.

The RFID data comes in useing RS 232. The reader is clicking on and off every 50 ms and if there is a tag in any of the antenna feilds it will send the Id back to a serial string looking like this as a example "0100000340" , where the first 2 digits identify which antenna feild the tag is in and the remaining numbers are the actual ID number.  

 

What I am struggleing with is the best way to combine these data sets. I have looked a little bit at diadem and it seems to be that it may work because of the large amounts of data that will be generated. But when it comes to actually putting weight data together with a individual rfid tag will it work for this or does this type of event management need to be done in labview?

 

 

Suggestions  and insite would be greatly appreciated.

 

One other challenge with this is that the system will need to take fairly frequent measurements 24 hrs a day and as such will likely have large amounts of data each day

But at the end of the day it would not be necessay to keep all the data except the summary of what the total weight is that is attached to each tag.

 

 

 

 

Regards JB.

 

My apologies if my explanation is garbage. haha!

 

 

 

 

 

0 Kudos
Message 1 of 7
(2,856 Views)

Diadem may be a good way to go (great with large data sets). I'm not sure I completely understand what you're asking, but I'll answer best I can. If your data can be broken up, associating it with a cluster is a good idea. If it can't be, you're going to have to associate it by attaching time stamps or some other meta-data. You can also have parallel arrays whose indicies are associated. As far as managing large data sets. You're going to have to load the data into a file at some point. 

 

Hope that helps! Let me know if I haven't properly addressed your question.

0 Kudos
Message 2 of 7
(2,830 Views)

Yeah I think you have a pretty good handle of what I am getting at.

I am a little unclear as to what you mean by breaking up the data.

Let me see if I can explain a little more clear what I am getting at.

Lets say that there is a group of 10 race horses and each of these race horses eat from bins containing oats.

Under these bins are load cells that weighs the oats in each bin. In front of the bin is a RFID reader that will read a tag everytime the horse goes to eat from the bin.

Combining the data from the RFID reader with the load cell measurements I should be able to tell which horse eats when and how much it eats.

The challenge is that I need to be taking measurements fairly frequently in order to make sure that it is accurate. (Lots of data.) But what I am struggling to understand is the best way to trigger a event every time a horse walks up to a bin, and in a ideal world to be able to graph that out real time so that at anytime in the day I could look and see that horse "x" has eaten 10 lb so far today. Oh yeah and any one of the horses could eat randomly from anyone of the bins.

Someone on another chat said "its one thing to collect mounds and mounds of data but in means stink in it can't be organized." hahaha.

 

Thanks

 

JB

 

Smiley Happy

0 Kudos
Message 3 of 7
(2,817 Views)

I'd say you have two approaches generally to handling that sort of data organization. One is to cut the data as it comes in based on the triggering of inputs or some sort of timing. You then correlate a set of data in a cluster and store it. This would supply you with very well organized "chunky" data. The other option is to read the data continuously and use some sort of time stamping system to keep track of events. If you were using waveforms you'd be able to use the t0 to store the initial time. I don't know much about Diadem, but doing this in LabVIEW would almost certainly require some programming beyond just placing down a few VIs. I am not aware of anything in LabVIEW which does this by default.

 

My personal preference is to time stamp all the data so you can reorganize it however you want later, but that's certainly not the only way to go.

 

In terms of triggering, are you meaning you want to do hardware triggering or software triggering? It sounds like you want to do software triggering in which case we may have some VIs that could help. If you felt like managing it yourself you could just write a quick VI that looks for local maxima or whatever method you'd like to use.

0 Kudos
Message 4 of 7
(2,804 Views)

Yeah I am thinking that I could use a software trigger to get labview to attach the incoming weight data to the tag that is in the read feild.

The only thing about this though is that I do need to be able to audit that data in order to make sure that as the weight in a bin gets less that 95 % of it is attributed to the presence of a tag in the feild. I need to know if there was food disappearing in the absence of a tag.

 

I guess my main question is still how to read the data.

 

In my world I would like to be able to bring up the data for horse 'XYZ' and see a graph or a number (numeric bar chart perhaps?)

How would I do this If I time stamp?

 

What did you mean by the data being chunky in a cluster?

 

 

Thanks I appreciate the guidance!

 

JB

 

Smiley Happy

 

0 Kudos
Message 5 of 7
(2,790 Views)

No problem! I'm going to simplify the next explination in case you need more detail. A cluster is a data structure in LabVIEW which provides the ability to group or "cluster" data together. It creates what would be analogous to a "struct" in C++. This allows you to simultanously store and pass groupings of dissimilary data types together. It is different from an array in that arrays require all data in the array to be of the same type. If you "chunk" your data into clusters, you're sorting it based on event. An event happens, a cluster is created, data is stored in the cluster, the cluster is kept independently (possibly in an array of clusters which are sorted by some other method) and is accessed independently.

 

The other option is to keep one continuous string of data and keep track of events via meta data. An event happens and the meta data tag is generated and added to a list (for instance, at 2:30pm 7/1/2011, Event X happened and lasted for 31 seconds). This meta data then allows you to dynamically access your large unsorted data set and pull out meaningful data. Honestly, it almost sounds like you might look into building a legitimate database. I'm partial to MySQL because it's free and easy to use.

 

Databases like MySQL (and if you want to access it in LabVIEW, the Database Connectivity Toolkit as a wrapper) allow you to query for information like "Data for horse 'X'". Unfortunately all of these decision are very design oriented and no one can make them for you (unless you hire someone to develop the application for you). I can tell you the advantages and disadvantages of doing things certain ways, but ultimately many of these decisions are arbitrary based on your own personal preferences (although everyone under the sun will tell you they know the RIGHT way to do something and any other way is ridiculous). There are obviously "better" choices in some cases, but a lot is going to be what makes sense to you as the developer. As I said earlier, I'm partial to continuous data with meta-data tags telling you when events are and what data is associated.

 

As far as how to read the data, I'm guessing you mean from the primary data set being read in by your devices? That's very data-type dependent. Unfortunately the questions you're asking are mostly rather general (which makes them difficult to answer). Let me know if I'm not answering them to your satisfaction and, if possible, narrow them down a bit so I can be more specific.

0 Kudos
Message 6 of 7
(2,779 Views)

Woops! Posted that under the wrong login, it was still me.

0 Kudos
Message 7 of 7
(2,775 Views)