Take the 2-minute tour ×
Signal Processing Stack Exchange is a question and answer site for practitioners of the art and science of signal, image and video processing. It's 100% free, no registration required.

For fun and work I've to implement a java based application that can Encode text or data to sound and transmit using PC's speaker and on the receiving side is a microphone with decoder software.

I was thinking of using FSK (syn or async or suggest) for the implementation:

Text (data) ---modulate---> 10khz-20khz audio carrier wave ---> Over the air transmission ---> microphone -> demodulate ---> Display text or data.

My main considerations are:

  • ~200bps bandwidth if not more
  • resilient to noise upto certain level
  • preferably 16khz - 20khz carrier wave with 44.1khz sampling (there's less noise in this area and its not really audible to older people and mics, speakers are cheap, readily available in laptops)
  • Not too complex coding logic.

What Modulation would work best with least coding efforts? Any recommendations on libraries/samples for achieving FSK/BFSK/PSK or DSSS using java?

share|improve this question
You could just use one of the old modem standards, e.g. V21 which was very simple, 300 baud, full duplex. There should be plenty of documentation and source code out there. You can shift the baseband up to 17 kHz using mixing if needed. –  Paul R Feb 1 '13 at 11:28
Careful with pushing the carrier frequency too high. Most commercial acoustic devices start to have frequency response characteristics that are not well defined as you approach 20Khz. For some devices, 16Khz may be a challenge. Is is acceptable for your scheme to have a parameter that sets the carrier frequency / band? –  user2718 Feb 1 '13 at 23:06
To add to @PaulR 's comment, you can take a spec like V21 and adapt it to match your chosen carrier frequency range. If you want to pursue that, I'm sure there is enough expertise on this site to help with the adaptation. –  user2718 Feb 1 '13 at 23:09
@PaulR Can you give me an example implementation in java? –  geeknizer Feb 3 '13 at 18:28
Sure - just give me a few days to write it for you... –  Paul R Feb 3 '13 at 19:51

1 Answer 1

This is actually a really tough problem because of the channel characteristics. Most computer speakers have fairly limited bandwidth, have significant non-linearities and the room acoustics are often time variant.

Life becomes A LOT easier if you can just run a cable from the headphone output of one PC into the line input of the other.

share|improve this answer
I've been working on a very similar communication scheme: audio fsk modulation/demodulation and I've just found a linux audio modem implementation using fsk. This sw can reach 300 and 1200 baud using the audio channel as commucation link between two pc and fsk. It could be a very good starting point (my implementation fairly reaches 200 baud in a noisy environment using frequencies around 500-4000 Hz for issues related to frequency response of pc audio devices). link –  Yozek Feb 2 '13 at 19:59
@Yozek can you point me to that source code? –  geeknizer Feb 3 '13 at 18:27
The url for the minimodem implementation is here: whence.com/minimodem/minimodem-0.16.1.tar.gz I'm still working on a personal simple implementation of AFSK in java and objective-C, but I'm having some troubles with ambiental/background noise and low transmission rate limit: about 100/200 baud (or bit/sec), not very much at all. But I don't know if the cause is a practical/physiological limitation or it's a my 'not so smart enough implementation' problem. I think the second one... –  Yozek Feb 3 '13 at 19:27

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.