Shop OBEX P1 Docs P2 Docs Learn Events
2M VHF FM Receiver — Parallax Forums

2M VHF FM Receiver

NeohdNeohd Posts: 5
edited 2011-12-19 10:14 in Propeller 1
Usually I never ask and always attempt to find my own information on the site or the web in general. I have come to a cross road and can not find any further details around what I seek. I have found some very basic explainations and it has helped alot, but I am stuck on a few things and hopefully someone can shed some light on this subject for me, or at least point me in the correct direction.

I am a HAM radio operator and very new to RF design and such. What my goal to do is to create a 2M VHF receiver that is fully controlled by a Propeller. I do not know radio design that much so I am a little bit limited, but I am very much eager to learn if pointed in the correct direction. I would like to create a receiver that will be able to receive the HAM band and a little bit outside of this using the PLL. Is this possible using the Propeller? Is the PLL that is built in to the Propeller capable of providing the control that I desire that other standalone PLL chips can provide, but still yet remain fully customizable?

What I have learned so far in FM radio receivers is very basic but interesting. I have realized that most FM receivers use an Intermediate Frequency(IF) to make the design of the IF Amplifier, FM demodulator and Audio Amplifier sections basic and are tuned specifally to the IF and make the design simpler. The part that I am confused on is how to control the selected or listening to frequency using the Propeller PLL or similar type of method.

I understand that my understanding is basic, but hopefully someone or the forum as a whole can help point me in the correct direction.

Any help is greatly appreciated and thank you in advance.

-73
-Neohd

Comments

  • Mike GreenMike Green Posts: 23,101
    edited 2011-12-13 12:17
    The PLL(s) built into the Propeller are too noisy for use in a transmitter. I believe it was PhiPi who has been working on a DSP receiver using the Propeller. It's not something I'd recommend for other than intellectual interest for a beginner. There are very good PLL chips that can be controlled by a Propeller and can produce a stable and clean enough signal for a good receiver or transmitter. You will probably be better off using other specialized chips for the receiver (and maybe transmitter). You can probably find construction articles in QST and QEX.
  • pedwardpedward Posts: 1,642
    edited 2011-12-13 12:20
    I became interested in the propeller for software defined radio as well. I am a HAM too (W0NKE) and was interested in making a full SDF using the prop.

    Some suggestions that could get you started:

    Research FM modulation so that you understand IF to AF conversion

    Research mixing

    Get the book "Basic Communications Electronics" ISBN 0-945053-24-X, it has a lot of really useful information in it.

    There is another problem you are going to run into, the counter speed. I know the data says 500Khz to 128Mhz, but all I've seen is that the counters run at main clock speed and can't run faster than main clock speed. You are dealing with a range of 144-148Mhz, so you can't directly generate that frequency. You will need an external oscillator for your primary detector, but you can generate the If and probably do the AF conversion in software.
  • Mike GreenMike Green Posts: 23,101
    edited 2011-12-13 12:24
    Here's a link to one of Phil's posts. Follow some of the other links in the post for more information.
  • ericballericball Posts: 774
    edited 2011-12-13 12:58
    pedward wrote: »
    ... but all I've seen is that the counters run at main clock speed and can't run faster than main clock speed.

    See PLL Modes of Operation in AN001, but in brief it works like this:
    You configure FRQA to generate a frequency between 4 and 8MHz ( 4MHz =< FRQA * CLKFREQ / 2^32 =< 8MHz ). This is then multiplied by 16, then divided using PLLDIV.

    Fout = Fnco * 2 ^ (PLLDIV - 3)
    Fnco = FRQA * CLKFREQ / 2^32
  • pedwardpedward Posts: 1,642
    edited 2011-12-13 13:10
    ericball wrote: »
    See PLL Modes of Operation in AN001, but in brief it works like this:
    You configure FRQA to generate a frequency between 4 and 8MHz ( 4MHz =< FRQA * CLKFREQ / 2^32 =< 8MHz ). This is then multiplied by 16, then divided using PLLDIV.

    Fout = Fnco * 2 ^ (PLLDIV - 3)
    Fnco = FRQA * CLKFREQ / 2^32

    I read that, but it wasn't clear whether it was the CTR or the main clock that was being used. It seemed to indicate the main clock oscillator was used for the PLL. I just felt the PLL section of the AN was a little obtuse (for that matter, the whole AN is a little brief and glosses over some really important stuff, like the theory of how each of the functions works). Also, it was a little unclear that the PLL applies only to the output pin and not to the timescale of the counter. Most other micros allow you to pick the clock source for the counter and coming from that paradigm, I had initially assumed the PLLDIV divided the CLKFREG * 16 down to the desired master clock frequency, then the accumulators worked as normal. It seems to me that would have actually been the better way to do it, then you can use the CTRs for timebases natively or getting a certain resolution for external events.

    Once I understand something completely, I'm really good and explaining it, but the counters are a little fuzzy to me still.

    Maybe I'll go at that AN again and just rewrite it to give complete understanding! :nerd:
  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2011-12-13 14:24
    Here's a thread that explores the possibilities in the two-meter band:

    I once tried generating RF at 146 MHz using just a counter in PLL mode. I was able to detect very strong birdies all up and down the band (and outside) due to the PLL's jitter. 'Definitely not recommended.

    For something simple to try, you could replace the crystal in Parallax's FM radio module with one of a higher frequency and see if it still works to pick up two-meter transmissions.

    -Phil (AD7YF)
  • pedwardpedward Posts: 1,642
    edited 2011-12-13 14:26
    Dumb question, but could the jitter be improved by using a quality external oscillator module? I have bunch of 16Mhz oscillators from another project.
  • jmgjmg Posts: 15,172
    edited 2011-12-13 14:27
    Neohd wrote: »
    I would like to create a receiver that will be able to receive the HAM band and a little bit outside of this using the PLL. Is this possible using the Propeller?

    Yes.
    Neohd wrote: »
    Is the PLL that is built in to the Propeller capable of providing the control that I desire that other standalone PLL chips can provide, but still yet remain fully customizable?

    No.

    You need a much better spec'd PLL for RF reception, than any Microcontroller built-in PLL, but the Prop can certainly control an external PLL Synthesis chip.
    You can easily work out the jitter effects, especially on FM.
    If you take a 150MHz ballpark, and add 1ps of jitter, that is ~22KHz of frequency change.

    Look at Analog Devices or Silabs ? and I think someone mentioned the Si570 has been used for this sort of work...
    For best purity, you would make your own VCO.
  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2011-12-13 14:47
    pedward wrote:
    Dumb question, but could the jitter be improved by using a quality external oscillator module? I have bunch of 16Mhz oscillators from another project.
    If you mean to drive the Prop's system clock, no. The jitter is not due to the system clock but to the counter's NCO output that drives the PLL, and it's mostly deterministic, being a function of frqx.

    -Phil
  • pedwardpedward Posts: 1,642
    edited 2011-12-13 16:00
    If you mean to drive the Prop's system clock, no. The jitter is not due to the system clock but to the counter's NCO output that drives the PLL, and it's mostly deterministic, being a function of frqx.

    -Phil

    I assume you are referencing the note in the AN001 that says any FRQx value that isn't a power of 2 will create jitter? That's what we are talking about?
  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2011-12-13 16:23
    Yep, that's what we're talking about. And you cannot get rid of it, once it's there, by filtering or any other means.

    -Phil
  • Cluso99Cluso99 Posts: 18,069
    edited 2011-12-13 18:04
    There is a lot of info about the Software Defined Radio. An Si570 is often used. This is easily driven by the prop. As Phil has suggested, demodulation could then be done by the prop but there is quite a bit of work to do and a lot already done by Phil. It would definately be a good project.

    Phil has another thread (link?) where Phil describes the demodulation process very clearly using the prop.

    The SDR does not use an IF, but instead demodulates down to values around 96KHz??? (the bandwidth of a pcs audio card) and the pc is left to filter out the audio. To me, the prop should be able to do both tasks from the work Phil has done, because the prop has multiple cores.

    Ray (VK2ZTZ)
  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2011-12-13 19:05
    One approach worth considering is to drive the Propeller from a 10.7 MHz crystal, if you can find one, and mix the 144 - 148 MHz RF down to that IF, for which plenty of transformers and filters exist. From there it should be easy to demodulate the FM in the Propeller using the counters, set up as I and Q mixers.

    -Phil
  • Toby SeckshundToby Seckshund Posts: 2,027
    edited 2011-12-14 02:58
    I have done some searches for FM demod by I and Q but have not found much more than yet more references to it. I am not awake enough to figure out whether the 10.7MHz clock planted right on the IF centre is a good thing or not.

    I haven't got any PC cards that go above 48KHz but I have dreamt about SDR. I have scrounged a bunch of old analog TV tuners to play with the I2C programming but the finest freq step with these is 50KHz, but I have an idea about chaining two of them with one on 50KHz steps and one on 62.5KHz steps to try for 2.5KHz difference (this would probably end up as the worlds best noise generator!).

    I have a 74HCT4046 here that I mean to try as Phil suggested as an external "jitter reducing flywheel" . I have tried to produce a 6.975MHz (I think) for a teletext problem and built a LC filter for it. I stuck it onto a spectrum analyzer, at work, and the jitter although reduced was still there as noise sidebands. Whilst it wouldn't have made any problems for the teletext I am sure it would have screwed up 2.5KHz deviation demod.

    Alan (ex G8LCU)
  • LeonLeon Posts: 7,620
    edited 2011-12-14 04:31
    The ARRL Handbook has lots of stuff on DSP techniques and SDRs. There is also the Softrock40 group:

    http://groups.yahoo.com/group/softrock40/

    They use simple I/Q mixers with sound cards and DSP on the PC, and some members have been using them for 2m reception with converters:

    http://groups.yahoo.com/group/softrock40/message/26580
  • NeohdNeohd Posts: 5
    edited 2011-12-14 10:23
    Well thank you for all the input this is greatly appreciated. I have to say I have been researching alot on this and found a few things that might be worthwhile into looking into. Since the jitter of the PLL might not be good for any reason, I believe the best way to tackle this will be a phased approach. I have come up with this idea based on alot of reading that I have been doing, so please correct me if you see something that is wrong or does not make sense or will not work. I figure that maybe the propeller can be used to do the FM demodulation that I believe I saw from Phil, I could be mistaken.

    I read that using a DDS for fine tuning of the frequency can be used especially since it will change its frequency faster. I could be wrong. Again still a learning thing. Does one have to use 10.7Mhz as the final IF?

    See my possible idea and let me know if you see something that will not work or just plain does not make any sense?

    Possible.png


    73
    -Neohd
    916 x 772 - 144K
  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2011-12-14 10:40
    You don't need to use a 10.7 MHz final IF, especially in your case where you have a double-conversion superhet going. Typically, a higher IF is desirable in single-conversion systems, because image rejection is much easier. But your images should get filtered out in the first IF.

    As far as the speed of fine tuning, a DDS will give you nearly instant QSY but, for small frequency changes, a PLL would probably do just as well.

    One thing I'm not sure about is how low a final IF you can use for FM, since you need some degree of bandwidth just to accommodate the modulation. IIRC, amateur FM is narrow-band, but I don't remember what the bandwidth is.

    -Phil

    Addendum: 'Just checked the spec sheet for my VX-2R HT. For NFM, the final IF is 450 KHz; for WFM, it's 1MHz.
  • NeohdNeohd Posts: 5
    edited 2011-12-14 11:37
    Phil,

    Thank you for the response. What should I do to filter out the first IF? Is the band pass filter not good enough or is it two wide? As far as narrow-band for HAM Radio operators, it is not widely used, amateurs in the US still operate primarily on wide band. The narrow-band 2013 FCC mandate that has come out is only for Public Safety and Industrial/Business use of the spectrum only. The Amateur Community maintains the spectrum they are allocated by the FCC, which you might already know. The bandwidth size for Wide and Narrow bands are 25kHz and 12.5kHz respectfully but this varies from Type 90 and Type 97(amateur) equipment, I don't know why probably stricter rules. I believe that broadcast WFM is about 200kHz in width. This is going from memory so hopefully this is correct. If these numbers are correct, then I believe that 455kHz is wide enough even for the wide band which is what I will primarily be listening to. The diagram I listed above can also be used for more than just the HAM bands in the 2M range.

    Do you have any suggestions that will improve upon this design, aside from what you might have already stated? I would like to create a further stage to filter when selecting Wide vs Narrow, but this is just a wish and might go further than I currently understand. I will improve upon the final IF and make it higher. Any suggestions on the FM demodulation? I did see someone mention that you think the Prop can perform this function? Or is this also better left off loaded to another specialty IC?

    73
    -Neohd

    Correction: I believe that I found the FM Demodulation I was asking about.
  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2011-12-14 11:48
    Compared with broadcast FM, amateur wideband FM is still NFM, so I think your 455 KHz final IF will work. Just make sure that your RF bandpass filter ahead of the first mixer excludes the image frequencies.

    The Propeller should be able to do any baseband filtering that's necessary on the I and Q demodulation products. See this thread:

    Scan down to post #6, once you've read the introductory material.

    -Phil
  • VIRANDVIRAND Posts: 656
    edited 2011-12-17 13:07
    I wonder if, since the counters NCO operate in the range 4 to 8 MHz,
    if the whole 144-148 band can be received if its mixed down to that range
    such as with a SA612 mixer being driven with a cut (modified) 16Mhz crystal
    in overtone mode. (16 x 9 overtone is 144, but re-cut it to be 140 or 152 ?).
    edit:I once did something just like that to listen to 6 meters on a 10 meter rig.

    On the forum a year or two ago, someone made an I+Q AM broadcast receiver in pure code,
    which worked well with an antenna wire connected to a resistor on two prop pins.
    But,
    I don't have an idea at the moment for demodulating the FM after transverting the whole band to 4Mhz.
  • Cluso99Cluso99 Posts: 18,069
    edited 2011-12-17 18:35
    I would certainly do a lot of research into the SDR and SoftRock radios. From the work done there and the work done by Phil, I would think that using the front ends that the SoftRock uses (filters and Si570) driven by the prop (this is easy) you could do the I&Q within the prop and that would give you an IF of around 96KHz (remember, with the Si570, you can in fact change the IF to a few hundred KHz if you wish) and then feed that again into the prop for I&Q demodulation to audio.

    Just remember, you have 8 cores running at 80MHz (or overclock depending of the pcb layout to 104MHz). Phil has done a fantastic job of explaining the I&Q demodulation including the maths.

    IMHO this is certainly worth a try with the prop.
  • NeohdNeohd Posts: 5
    edited 2011-12-19 09:06
    Thank you for the information everyone, it is greatly appreciated.

    Phil,

    I do have a question. I have been trying to read up on the Image Frequency and calculate it so I can properly filter it before the First Mixer stage. What I have found so far is Fi = 2Flo + Fc and Fi = 2Flo - Fc. Given the range that I plan on receiving in initially which is, 144Mhz - 148Mhz, will image frequency be a problem? From what I can gather it is a problem if the image frequency is very close to the First IF, is my understanding correct? Eventually I would like to expand on this design and broaden its frequency range if possible, but for now this is just my inital understanding.

    If my first IF is 10.7Mhz and my intended receive frequency is 21.4Mhz, then this particular frequency would be a problem with my receiver, is this understanding correct? If this is not correct, how does one properly filter prior to the first Mixer and prevent Image frequencies from interfering on such a broad range of frequencies?

    73
    -Neohd
  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2011-12-19 10:14
    In the range 144-148 MHz, with a 10.7 MHz first IF, your LO will cover either 133.3-137.3 MHz or 155.7-159.7 MHz. In the first case, the output of your mixer stage will be RF - LO and RF + LO. Let's say LO is set to 133.3 MHz. What values of RF yield 10.7 MHz? From the first equation,
    RF - 133.3 = 10.7, or RF = 144 MHz.

    From the second,
    RF + 133.3 = 10.7, so RF = -122.6, or 122.6 MHz inverted.

    That latter value is an image frequency and happens to be 2 * 133.3 - 144. At the high end of the band, the image frequency will be
    2 * 137.3 - 148 = 126.6 MHz.

    So the range of image frequencies that must be filtered out ahead of the mixer is 122.6 - 126.6 MHz. An LC bandpass filter constructed to pass 144 - 148 MHz should work, as would a tunable filter with a higher Q (i.e. a preselector).

    It should be obvious from this that the lower the IF, compared to the receive frequency range, the harder it will be to reject image frequencies, since they will be so close to the desired reception band.

    -Phil

    Addendum: The image frequency range, 122.6-126.6 MHz is in the aircraft band, where AM predominates. So, barring front-end overload, your FM detector should also provide some "image rejection" just on that basis.
Sign In or Register to comment.