As sanity check I’m trying a simple flowgraph in GRC with a QAM
mod/demod:
Vector Source ==> Throttle ==> QAM Mod ==> QAM Demod ==> Unpacked to
Packed
==> File Sink
The parameters in the mod/demod are as default. I also have a File Sink
before the mod.
In the output I see first a bunch of zeros, then a bunch of random
numbers
and after 20 or so bytes I get a sequence with the same period as the
original one, but different numbers. I suppose this is a problem of
phase
sync.
What’s the right way to simulate a simple mod/demod? How do I add sync
between mod and demod?
original one, but different numbers. I suppose this is a problem of phase
sync.
What’s the right way to simulate a simple mod/demod? How do I add sync
between mod and demod?
Thanks,
Fabin
It sounds like you’re comparing bytes in the two files. First thing
that I’d check is that the two files aren’t offset from each other by
a few bits so that the bytes don’t line up in the same way.
If that’s not the problem then email me the grc file and I’ll have a
look.
It’s not just an offset problem. Even though in the output file, there
is a
delayed sequence, it doesn’t have the right bits. As it has exactly the
same period it leads me to believe that it’s just a problem of phase
sync.
I figured out the problem. There were two things I wasn’t taking into
account:
The modulator reads bits in MSB order, which means that I should
pack
them the same way.
There is a bit framing problem (can be solved using packet
encoder/decoder). Checked converting both sequences to bits (8 per
number)
and realizing one’s a shifted version of the other.