PSK File transfer

Hello,

I’m trying to do a simple file transfer over PSK, but the text file I
get
on the output is garbled. I’ve got:

file source -> throttle -> psk(4) mod -> psk(4) demod -> pack K (8) bits
->
file sink

If I put in a file sink before the modulator, I see the message just
fine.

What am I missing?

Thanks,
Stephen A.
Undergraduate, Electrical Engineering
Missouri University of Science and Technology

On 03/26/2014 08:32 AM, Stephen A. wrote:

Hello,

I’m trying to do a simple file transfer over PSK, but the text file I
get on the output is garbled. I’ve got:

file source -> throttle -> psk(4) mod -> psk(4) demod -> pack K (8) bits
-> file sink

If I put in a file sink before the modulator, I see the message just fine.

Do you mean if you put a file sink before the modulator, you get the
correct message in the file sink after the packer?

PSK Demod is a complete demod chain, it estimates freq. offset, timing
etc. It’s probably not converging immediately, and then your signal is
bit-shifted.

M

Sorry that was unclear. If I put in a file sink before the modulator,
and
call that file tx, and the file on the output of the demodulator rx, tx
looks fine, but rx still looks like gunk.

Also, if I set the original file source to not repeat, my file sinks
produce no data. Obviously, if one is sending a message, it only needs
to
be sent once, not repeated.

Thanks,

Stephen A.
Undergraduate, Electrical Engineering
Missouri University of Science and Technology

On 03/26/2014 08:44 PM, Stephen A. wrote:

Sorry that was unclear. If I put in a file sink before the modulator,
and call that file tx, and the file on the output of the demodulator rx,
tx looks fine, but rx still looks like gunk.

Also, if I set the original file source to not repeat, my file sinks
produce no data. Obviously, if one is sending a message, it only needs
to be sent once, not repeated.

Wait, you’re saying:

File source -> throttle -> File sink

produces zero data when repeat is off? What about when removing the
throttle?

M

On 03/27/2014 01:42 AM, Stephen A. wrote:

I did some more searching on the google machine and found:
http://lists.gnu.org/archive/html/discuss-gnuradio/2012-04/msg00500.html

It’s like my setup, minus the throttle and the pack K bits, with the
addition of packets on either side of the modulator/demodulator. Ran the
new setup, and it gives me the correct file on the output, but when I
turn off “repeat” in the file source, I get no output.

Why is repeat magical, and why did I have to packetize my file before
sending? Shouldn’t it have just sent as a stream of bits without packets?

The packetizer adds a preamble, which helps the demod lock and, more
importantly, and as pointed out in my earlier response, it helps you
find the byte boundaries.

Repeat is not magical, but the demod is stateful, and therefore works
better if rx’ing more data.

TBH, I didn’t try this out, but I’ll call this a very educated guess :slight_smile:
For packetized data, you always need some kind of preamble.

Martin

On 03/27/2014 05:15 PM, Stephen A. wrote:

File source -> throttle -> file sink

produces no data if repeat is off, and the sent file is small. If the
sent file is large, it will produce some data, but not all of it.
Removing the throttle doesn’t seem to have an effect.

For example, I sent a file of 19758 bytes across, and received 16384
bytes on the output. My “small” file was 407 bytes, and I got 0 bytes on
the output.

Hm, that’s multiples of pages…
I see the same thing, though. When I switch off buffering, it’s better,
although the file doesn’t get propagated entirely. And the flow graph
doesn’t terminate on it’s own. Hmm…

Maybe a bug with file sink/source? Is the source for those blocks easy
to find?

Sure, in gr-blocks/lib/file_*.

I still maintain that repeat is magical.

OK, you got us. We have a genie written into the code that only comes
out when repeat is on.

M

I did some more searching on the google machine and found:
http://lists.gnu.org/archive/html/discuss-gnuradio/2012-04/msg00500.html

It’s like my setup, minus the throttle and the pack K bits, with the
addition of packets on either side of the modulator/demodulator. Ran the
new setup, and it gives me the correct file on the output, but when I
turn
off “repeat” in the file source, I get no output.

Why is repeat magical, and why did I have to packetize my file before
sending? Shouldn’t it have just sent as a stream of bits without
packets?

Thanks,

Stephen A.
Undergraduate, Electrical Engineering
Missouri University of Science and Technology

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs