DSPRelated.com
Forums

V.34 demodulation

Started by Vito July 19, 2008
Hallo everybody,
I am just starting a C++ project about V.34 fax demodulation and
decoding on PC.

In all my previous DSP projects I had an analog front-end which
provided me the baseband samples, or I could recovery them in some
other tricky way (e.g. FFT in narrow-band OFDM systems). Anyway, all
my processing ever took place at baseband. In this case, on the
contrary, my input is a digitalized pass-band waveform which I have to
demodulate.

Here comes my question. My input waveform is sampled at 8 kHz, but the
symbol rate for V.34 is in the range 2400..3429 Hz. Thus my baseband
signal would have just 2 or 3 samples for each symbol, according to
the selected symbol rate. Does this mean that no pulse shaping is
possible? (I didn't find any on the specs). What should I then
actually expect at baseband as the output of the demodulator? Just a
train of rect pulses? I can hardly imagine how such a signal could be
still significant after LPF, given such a limited sampling rate... but
this is just a feeling of mine, maybe I am missing something because
of my inexperience in the field of telephone line modems. That's why
I'm asking...

By the way, does anyone have any suggestion on the demodulator
structure for this kind of signal? Should I go for a software PLL of
rather try to recover the signal envelope through some other
techinque?

Thanks

Vito

Vito wrote:

> Hallo everybody, > I am just starting a C++ project about V.34 fax demodulation and > decoding on PC. > > In all my previous DSP projects I had an analog front-end which > provided me the baseband samples, or I could recovery them in some > other tricky way (e.g. FFT in narrow-band OFDM systems). Anyway, all > my processing ever took place at baseband. In this case, on the > contrary, my input is a digitalized pass-band waveform which I have to > demodulate. > > Here comes my question. My input waveform is sampled at 8 kHz, but the > symbol rate for V.34 is in the range 2400..3429 Hz. Thus my baseband > signal would have just 2 or 3 samples for each symbol, according to > the selected symbol rate. Does this mean that no pulse shaping is > possible? (I didn't find any on the specs). What should I then > actually expect at baseband as the output of the demodulator? Just a > train of rect pulses? I can hardly imagine how such a signal could be > still significant after LPF, given such a limited sampling rate... but > this is just a feeling of mine, maybe I am missing something because > of my inexperience in the field of telephone line modems. That's why > I'm asking... > > By the way, does anyone have any suggestion on the demodulator > structure for this kind of signal? Should I go for a software PLL of > rather try to recover the signal envelope through some other > techinque?
First thing to do is resampling the incoming data to the sample rate which is synchronized to the symbol rate. The two samples per symbol is sufficient; having more samples per symbol is better if you can afford the computation. Vladimir Vassilevsky DSP and Mixed Signal Design Consultant http://www.abvolt.com
On 19 Lug, 18:53, Vladimir Vassilevsky <antispam_bo...@hotmail.com>
wrote:
> Vito wrote: > > Hallo everybody, > > I am just starting a C++ project about V.34 fax demodulation and > > decoding on PC. > > > In all my previous DSP projects I had an analog front-end which > > provided me the baseband samples, or I could recovery them in some > > other tricky way (e.g. FFT in narrow-band OFDM systems). Anyway, all > > my processing ever took place at baseband. In this case, on the > > contrary, my input is a digitalized pass-band waveform which I have to > > demodulate. > > > Here comes my question. My input waveform is sampled at 8 kHz, but the > > symbol rate for V.34 is in the range 2400..3429 Hz. Thus my baseband > > signal would have just 2 or 3 samples for each symbol, according to > > the selected symbol rate. Does this mean that no pulse shaping is > > possible? (I didn't find any on the specs). What should I then > > actually expect at baseband as the output of the demodulator? Just a > > train of rect pulses? I can hardly imagine how such a signal could be > > still significant after LPF, given such a limited sampling rate... but > > this is just a feeling of mine, maybe I am missing something because > > of my inexperience in the field of telephone line modems. That's why > > I'm asking... > > > By the way, does anyone have any suggestion on the demodulator > > structure for this kind of signal? Should I go for a software PLL of > > rather try to recover the signal envelope through some other > > techinque? > > First thing to do is resampling the incoming data to the sample rate > which is synchronized to the symbol rate. The two samples per symbol is > sufficient; having more samples per symbol is better if you can afford > the computation. > > Vladimir Vassilevsky > DSP and Mixed Signal Design Consultanthttp://www.abvolt.com
That's a good starting point! :-) Thanks. But given your suggestion I have two questions: 1) I know that resampling is basically quite affordable when the ratio between the new and old sampling frequencies is a ratio of "small" numbers. For example, if SR=2400 Hz I would resample at 4800 Hz, which is 3/5 of the original sampling frequency, in order to get 2 samples/ symbol. I see no problem in that. But what if I have SR=3429 Hz? I mean, this looks quite more expensive, as I should oversample in principle up to 3429*8000 = 27.432 MHz! So, I don't see why such "odd" values of symbol rate were included in the V.34 specs (altough not mandatory). Does anyone know? 2) Just assume I got 2 samples per symbol on both I and Q. May I simply average them in order to get my detected constellation point? Thanks Vito

Vito wrote:
> On 19 Lug, 18:53, Vladimir Vassilevsky <antispam_bo...@hotmail.com> > wrote: > >>Vito wrote: >> >>>Hallo everybody, >>>I am just starting a C++ project about V.34 fax demodulation and >>>decoding on PC. >> >>>In all my previous DSP projects I had an analog front-end which >>>provided me the baseband samples, or I could recovery them in some >>>other tricky way (e.g. FFT in narrow-band OFDM systems). Anyway, all >>>my processing ever took place at baseband. In this case, on the >>>contrary, my input is a digitalized pass-band waveform which I have to >>>demodulate. >> >>>Here comes my question. My input waveform is sampled at 8 kHz, but the >>>symbol rate for V.34 is in the range 2400..3429 Hz. Thus my baseband >>>signal would have just 2 or 3 samples for each symbol, according to >>>the selected symbol rate. Does this mean that no pulse shaping is >>>possible? (I didn't find any on the specs). What should I then >>>actually expect at baseband as the output of the demodulator? Just a >>>train of rect pulses? I can hardly imagine how such a signal could be >>>still significant after LPF, given such a limited sampling rate... but >>>this is just a feeling of mine, maybe I am missing something because >>>of my inexperience in the field of telephone line modems. That's why >>>I'm asking... >> >>>By the way, does anyone have any suggestion on the demodulator >>>structure for this kind of signal? Should I go for a software PLL of >>>rather try to recover the signal envelope through some other >>>techinque? >> >>First thing to do is resampling the incoming data to the sample rate >>which is synchronized to the symbol rate. The two samples per symbol is >>sufficient; having more samples per symbol is better if you can afford >>the computation.
> That's a good starting point! :-)
Now drop the project and forget about it.
> Thanks. > But given your suggestion I have two questions: > 1) I know that resampling is basically quite affordable when the ratio > between the new and old sampling frequencies is a ratio of "small" > numbers.
That doesn't matter. The sampling should be synchronized to the incoming signal.
> For example, if SR=2400 Hz I would resample at 4800 Hz, which > is 3/5 of the original sampling frequency, in order to get 2 samples/ > symbol. I see no problem in that. But what if I have SR=3429 Hz? I > mean, this looks quite more expensive, as I should oversample in > principle up to 3429*8000 = 27.432 MHz! So, I don't see why such "odd" > values of symbol rate were included in the V.34 specs (altough not > mandatory). Does anyone know?
Polynomial interpolation.
> 2) Just assume I got 2 samples per symbol on both I and Q. May I > simply average them in order to get my detected constellation point?
You can do anything. However it is not going to work. Vladimir Vassilevsky DSP and Mixed Signal Design Consultant http://www.abvolt.com
On 19 Lug, 21:12, Vladimir Vassilevsky <antispam_bo...@hotmail.com>
wrote:
> Vito wrote: > > On 19 Lug, 18:53, Vladimir Vassilevsky <antispam_bo...@hotmail.com> > > wrote: > > >>Vito wrote: > > >>>Hallo everybody, > >>>I am just starting a C++ project about V.34 fax demodulation and > >>>decoding on PC. > > >>>In all my previous DSP projects I had an analog front-end which > >>>provided me the baseband samples, or I could recovery them in some > >>>other tricky way (e.g. FFT in narrow-band OFDM systems). Anyway, all > >>>my processing ever took place at baseband. In this case, on the > >>>contrary, my input is a digitalized pass-band waveform which I have to > >>>demodulate. > > >>>Here comes my question. My input waveform is sampled at 8 kHz, but the > >>>symbol rate for V.34 is in the range 2400..3429 Hz. Thus my baseband > >>>signal would have just 2 or 3 samples for each symbol, according to > >>>the selected symbol rate. Does this mean that no pulse shaping is > >>>possible? (I didn't find any on the specs). What should I then > >>>actually expect at baseband as the output of the demodulator? Just a > >>>train of rect pulses? I can hardly imagine how such a signal could be > >>>still significant after LPF, given such a limited sampling rate... but > >>>this is just a feeling of mine, maybe I am missing something because > >>>of my inexperience in the field of telephone line modems. That's why > >>>I'm asking... > > >>>By the way, does anyone have any suggestion on the demodulator > >>>structure for this kind of signal? Should I go for a software PLL of > >>>rather try to recover the signal envelope through some other > >>>techinque? > > >>First thing to do is resampling the incoming data to the sample rate > >>which is synchronized to the symbol rate. The two samples per symbol is > >>sufficient; having more samples per symbol is better if you can afford > >>the computation. > > That's a good starting point! :-) > > Now drop the project and forget about it. > > > Thanks. > > But given your suggestion I have two questions: > > 1) I know that resampling is basically quite affordable when the ratio > > between the new and old sampling frequencies is a ratio of "small" > > numbers. > > That doesn't matter. The sampling should be synchronized to the incoming > signal. > > > For example, if SR=2400 Hz I would resample at 4800 Hz, which > > is 3/5 of the original sampling frequency, in order to get 2 samples/ > > symbol. I see no problem in that. But what if I have SR=3429 Hz? I > > mean, this looks quite more expensive, as I should oversample in > > principle up to 3429*8000 = 27.432 MHz! So, I don't see why such "odd" > > values of symbol rate were included in the V.34 specs (altough not > > mandatory). Does anyone know? > > Polynomial interpolation.
That's another way to look at it, but I would say the amount of processing won't be much less. Maybe there's a bug in my way of thinking it. Forget it, I can easily check on text books.
> > 2) Just assume I got 2 samples per symbol on both I and Q. May I > > simply average them in order to get my detected constellation point? > > You can do anything. &#4294967295;However it is not going to work.
Of course not, without any equalization algorithm, AGC and all that stuff. I know it ain't that easy :-) Sorry, my question was actually not accurate. I meant: how should I treat my 2 samples/symbol in order to achieve one single IQ value for later processing? Or maybe you are thinking about using a fractionally spaced equalizer? Sorry if I am bothering you with trivial topics. Thanks Vito
On Sat, 19 Jul 2008 13:44:07 -0700 (PDT), Vito
<v.dantona@googlemail.com> wrote:

>On 19 Lug, 21:12, Vladimir Vassilevsky <antispam_bo...@hotmail.com> >wrote: >> Vito wrote: >> > On 19 Lug, 18:53, Vladimir Vassilevsky <antispam_bo...@hotmail.com> >> > wrote: >> >> >>Vito wrote: >> >> >>>Hallo everybody, >> >>>I am just starting a C++ project about V.34 fax demodulation and >> >>>decoding on PC. >> >> >>>In all my previous DSP projects I had an analog front-end which >> >>>provided me the baseband samples, or I could recovery them in some >> >>>other tricky way (e.g. FFT in narrow-band OFDM systems). Anyway, all >> >>>my processing ever took place at baseband. In this case, on the >> >>>contrary, my input is a digitalized pass-band waveform which I have to >> >>>demodulate. >> >> >>>Here comes my question. My input waveform is sampled at 8 kHz, but the >> >>>symbol rate for V.34 is in the range 2400..3429 Hz. Thus my baseband >> >>>signal would have just 2 or 3 samples for each symbol, according to >> >>>the selected symbol rate. Does this mean that no pulse shaping is >> >>>possible? (I didn't find any on the specs). What should I then >> >>>actually expect at baseband as the output of the demodulator? Just a >> >>>train of rect pulses? I can hardly imagine how such a signal could be >> >>>still significant after LPF, given such a limited sampling rate... but >> >>>this is just a feeling of mine, maybe I am missing something because >> >>>of my inexperience in the field of telephone line modems. That's why >> >>>I'm asking... >> >> >>>By the way, does anyone have any suggestion on the demodulator >> >>>structure for this kind of signal? Should I go for a software PLL of >> >>>rather try to recover the signal envelope through some other >> >>>techinque? >> >> >>First thing to do is resampling the incoming data to the sample rate >> >>which is synchronized to the symbol rate. The two samples per symbol is >> >>sufficient; having more samples per symbol is better if you can afford >> >>the computation. >> > That's a good starting point! :-) >> >> Now drop the project and forget about it. >> >> > Thanks. >> > But given your suggestion I have two questions: >> > 1) I know that resampling is basically quite affordable when the ratio >> > between the new and old sampling frequencies is a ratio of "small" >> > numbers. >> >> That doesn't matter. The sampling should be synchronized to the incoming >> signal. >> >> > For example, if SR=2400 Hz I would resample at 4800 Hz, which >> > is 3/5 of the original sampling frequency, in order to get 2 samples/ >> > symbol. I see no problem in that. But what if I have SR=3429 Hz? I >> > mean, this looks quite more expensive, as I should oversample in >> > principle up to 3429*8000 = 27.432 MHz! So, I don't see why such "odd" >> > values of symbol rate were included in the V.34 specs (altough not >> > mandatory). Does anyone know? >> >> Polynomial interpolation. > >That's another way to look at it, but I would say the amount of >processing won't be much less. >Maybe there's a bug in my way of thinking it. Forget it, I can easily >check on text books.
A Farrow filter or polyphase interpolator can be used to synchronize the samples to the symbol interval. It's never "trivial", but it can usually be managed reasonably well.
>> > 2) Just assume I got 2 samples per symbol on both I and Q. May I >> > simply average them in order to get my detected constellation point? >> >> You can do anything. &#4294967295;However it is not going to work. > >Of course not, without any equalization algorithm, AGC and all that >stuff. >I know it ain't that easy :-) > >Sorry, my question was actually not accurate. >I meant: how should I treat my 2 samples/symbol in order to achieve >one single IQ value for later processing? >Or maybe you are thinking about using a fractionally spaced equalizer?
I'm assuming you're planning to do the majority of the processing at baseband, in which case the pulse shaping filters can take 2 samples/symbol on the input and decimate it down to the symbol samples. This does still require that the symbol timing be acquired at the sampling prior to the pulse shaping filter. The EQ can then be T-spaced and follow the pulse-shaping filter.
>Sorry if I am bothering you with trivial topics. >Thanks
Those that are bothered can ignore the posts. You're on-topic for the group in my opinion. Eric Jacobsen Minister of Algorithms Abineau Communications http://www.ericjacobsen.org Blog: http://www.dsprelated.com/blogs-1/hf/Eric_Jacobsen.php
>>>>>>Hallo everybody, >>>>>>I am just starting a C++ project about V.34 fax demodulation and >>>>>>decoding on PC.
Get realistic. The full blown V.34 is no small project which is not for the individual hackers. AFAIK there are only few working realizations in the world. It is also covered by many intellectual property claims.
> I know it ain't that easy :-)
No, you don't know that yet.
> Sorry, my question was actually not accurate. > I meant: how should I treat my 2 samples/symbol in order to achieve > one single IQ value for later processing? > Or maybe you are thinking about using a fractionally spaced equalizer?
Two samples per symbol (one at the decision instant and the other one in between two symbols) are required for sync and equalizer. Vladimir Vassilevsky DSP and Mixed Signal Design Consultant http://www.abvolt.com
On 19 Lug, 23:23, Eric Jacobsen <eric.jacob...@ieee.org> wrote:
> On Sat, 19 Jul 2008 13:44:07 -0700 (PDT), Vito > > > > <v.dant...@googlemail.com> wrote: > >On 19 Lug, 21:12, Vladimir Vassilevsky <antispam_bo...@hotmail.com> > >wrote: > >> Vito wrote: > >> > On 19 Lug, 18:53, Vladimir Vassilevsky <antispam_bo...@hotmail.com> > >> > wrote: > > >> >>Vito wrote: > > >> >>>Hallo everybody, > >> >>>I am just starting a C++ project about V.34 fax demodulation and > >> >>>decoding on PC. > > >> >>>In all my previous DSP projects I had an analog front-end which > >> >>>provided me the baseband samples, or I could recovery them in some > >> >>>other tricky way (e.g. FFT in narrow-band OFDM systems). Anyway, all > >> >>>my processing ever took place at baseband. In this case, on the > >> >>>contrary, my input is a digitalized pass-band waveform which I have to > >> >>>demodulate. > > >> >>>Here comes my question. My input waveform is sampled at 8 kHz, but the > >> >>>symbol rate for V.34 is in the range 2400..3429 Hz. Thus my baseband > >> >>>signal would have just 2 or 3 samples for each symbol, according to > >> >>>the selected symbol rate. Does this mean that no pulse shaping is > >> >>>possible? (I didn't find any on the specs). What should I then > >> >>>actually expect at baseband as the output of the demodulator? Just a > >> >>>train of rect pulses? I can hardly imagine how such a signal could be > >> >>>still significant after LPF, given such a limited sampling rate... but > >> >>>this is just a feeling of mine, maybe I am missing something because > >> >>>of my inexperience in the field of telephone line modems. That's why > >> >>>I'm asking... > > >> >>>By the way, does anyone have any suggestion on the demodulator > >> >>>structure for this kind of signal? Should I go for a software PLL of > >> >>>rather try to recover the signal envelope through some other > >> >>>techinque? > > >> >>First thing to do is resampling the incoming data to the sample rate > >> >>which is synchronized to the symbol rate. The two samples per symbol is > >> >>sufficient; having more samples per symbol is better if you can afford > >> >>the computation. > >> > That's a good starting point! :-) > > >> Now drop the project and forget about it. > > >> > Thanks. > >> > But given your suggestion I have two questions: > >> > 1) I know that resampling is basically quite affordable when the ratio > >> > between the new and old sampling frequencies is a ratio of "small" > >> > numbers. > > >> That doesn't matter. The sampling should be synchronized to the incoming > >> signal. > > >> > For example, if SR=2400 Hz I would resample at 4800 Hz, which > >> > is 3/5 of the original sampling frequency, in order to get 2 samples/ > >> > symbol. I see no problem in that. But what if I have SR=3429 Hz? I > >> > mean, this looks quite more expensive, as I should oversample in > >> > principle up to 3429*8000 = 27.432 MHz! So, I don't see why such "odd" > >> > values of symbol rate were included in the V.34 specs (altough not > >> > mandatory). Does anyone know? > > >> Polynomial interpolation. > > >That's another way to look at it, but I would say the amount of > >processing won't be much less. > >Maybe there's a bug in my way of thinking it. Forget it, I can easily > >check on text books. > > A Farrow filter or polyphase interpolator can be used to synchronize > the samples to the symbol interval. &#4294967295; It's never "trivial", but it can > usually be managed reasonably well.
Thanks, I'll check out this Farrow filter.
> >> > 2) Just assume I got 2 samples per symbol on both I and Q. May I > >> > simply average them in order to get my detected constellation point? > > >> You can do anything. &#4294967295;However it is not going to work. > > >Of course not, without any equalization algorithm, AGC and all that > >stuff. > >I know it ain't that easy :-) > > >Sorry, my question was actually not accurate. > >I meant: how should I treat my 2 samples/symbol in order to achieve > >one single IQ value for later processing? > >Or maybe you are thinking about using a fractionally spaced equalizer? > > I'm assuming you're planning to do the majority of the processing at > baseband, in which case the pulse shaping filters can take 2 > samples/symbol on the input and decimate it down to the symbol > samples. &#4294967295; This does still require that the symbol timing be acquired > at the sampling prior to the pulse shaping filter. > > The EQ can then be T-spaced and follow the pulse-shaping filter.
You got the point... but my greatest doubt is how I should design the receive filter. I'm assuming the best choice is always having a matched filter, but I found no information about the TX shaping filter on the V.34 specification. Thanks Vito
On 20 Lug, 00:00, Vladimir Vassilevsky <antispam_bo...@hotmail.com>
wrote:
> >>>>>>Hallo everybody, > >>>>>>I am just starting a C++ project about V.34 fax demodulation and > >>>>>>decoding on PC. > > Get realistic. The full blown V.34 is no small project which is not for > the individual hackers. AFAIK there are only few working realizations in > the world. It is also covered by many intellectual property claims. > > > I know it ain't that easy :-) > > No, you don't know that yet.
I'm not underestimating it. I'm aware it's going to require a huge effort and I will ecounter much more serious issues than the ones I asked about. Anyway I don't have to implement a fully working modem, just offline fax decoding. Thanks for the support. BR Vito