Hi Casey, considering the filters should have a fixed length and hence delay, you should be able to calculate the sample delay in both paths (I /assume/ the 30Hz filter highly decimates, so you might need to do that separately). Now, you could just be implementing your own FM demod using the quadrature demod block, or you could be using GNU Radio's premade FM demod (which contains filters and preemphasis); depending on that you'd have only 1 additional sample of delay, or delay depending on the parameters of the FM demodulation. Then compensate for that by adding a "delay" block in the left path.
The point is that normally, GNU Radio probably won't call Phase comparator's work() until there's input on both input streams -- but the first item coming out of a filter doesn't contain the "same" information as the first sample going into it -- hence, filters have group/phase delays (rejoice, for linear phase filters, that delay is half the filter length -- pretty intuitive, I think, considering linear phase filters are symmetric (or antisymmetric), and low passes typically have their max(abs(tap)) in the middle). Greetings, Marcus On 07/20/2015 05:38 PM, Casey Flach wrote: > Hello, > > I am trying to process a VOR signal. My blocks look like the following. > > Source > v > Resample > v > ______ Demod AM __________ > v v > Filter 30 Hz Filter 9960 Hz > | v > | Demod FM > | v > | Filter 30 Hz > |__________ ___________| > | | > v v > Phase Comparator > > The problem is that by the time both sample streams get to the Phase > Comparator the streams are out of sync because the right side has more > to process and GNURadio blocks are asynchronous. I have tried adding a > block to generate a tag before the "Demod AM" block and making the Phase > Comparator wait to process until it receives the tag on both streams, > but that appears to not work. In the Phase Comparator I'm basically > calling "Consume(0, 0); Consume(1, 0);" until I receive both tags. > > Does anyone know of a better way to try to sync up the sample streams? > > Thank You. >
_______________________________________________ Discuss-gnuradio mailing list [email protected] https://lists.gnu.org/mailman/listinfo/discuss-gnuradio
