11-06-2014 12:14 PM
GNU Radio has a neat feature that allows you to "tag" a certain sample in your data stream that can be used to flag or signal action in future processing steps. For example, within an array of data, I could look for a certain marker/sequence/code, and then place a 'tag' on that sample as a hint for a later processing stage.
To my knowledge, there is no explicit analog of this in LabView, but I've been thinking about how you might be able to do something similar. The only idea I had was to create an entirely separate array, say of booleans, that was the same size as my data stream...but that necessitates having to carry around this other array. Saving a smaller array of indexes of certain events could work, but doesn't really seem like an elegant solution, and could be trouble if I'm purging parts of the data stream as I go.
Anyway...has anyone thought about this at all? I suppose it's not really a USRP thing as much as it is a programing methodolgy. I know there probably aren't many gnuradio users here (I'm only begin to dabble in GR myself), but was hoping maybe some of the NI application wizards who see on both sides of the wall might have some ideas.
Thanks!
---
Brandon
11-06-2014 12:51 PM
Just occured to me that you could do this with an array of clusters. One element in the cluster would be your tag (string, boolean, whatever) and the other you IQ pair. Implementing this currently would require you to index each element of your fetch, build a cluster element, then array up all those elements again. Doable...but have to "index down" then "build back up" the array adds a bunch of overhead.
Or...maybe you could take the polymorphic cluster data type from the Fetch.vi currently, and somehow add your own tag to that. That might be more efficient.
Here's an even better idea! (Erik, are you out there! 🙂 ).....Could a future version of the driver just include a cluster element for a "tag"? Currently it's what...complex sample, t0, and dt....right? Add us a tag element!!!
---
Brandon
11-06-2014 01:05 PM
11-06-2014 01:18 PM
Yup! I'll give it a try!
---
BC