Ham2Mon: A NBFM Multi-Channel Receiver Compatible with the RTL-SDR

A new piece of software called ham2mon by programmer Louis Brown (KD4HSO) has been released. This is a GNU Radio Linux based program that can be used with an RTL-SDR or other SDR that is compatible with GrOsmoSDR to demodulate and record narrow band FM audio from N channels (as many channels as your CPU can handle) within the current bandwidth. Although it is command line based, it comes with a simple Curses command line based GUI.

He writes that in future versions he hopes to incorporate gr-dsd to be able to demodulate and record P25 digital audio as well.

The ham2mon Curses GUI.
The ham2mon Curses GUI.

Louis has also uploaded a video to YouTube showing the software in action.



  1. Chris Sullivan

    To set up with rtl-sdr make sure that packages gnuradio and gr-osmocom are installed. I’ve found this command the best for invoking the program (so far).
    ./ham2mon.py -a “rtl” -n 4 -f 145E6 -r 1E6 -g 20 -s -40 -v 40 -b 16 -t 30 -w -m

    This command only writes to files (-w) and not to the audio device (-m). Modify as you wish. It boosts the volume (-v 40) to something closer to 0dB and writes 16 bit samples instead of the default of 8. With -v 0 and 8 bit samples the output was very lo-fi.

    On Ubuntu gnuradio package did not support Python 2 (which ham2mon is written in) so I converted it to Python 3. On Debian it worked under Python 2, although a Raspberry Pi 3B was not powerful enough to run it.

    I am finding a fairly strong DC bias in the output which I’m working on correcting. It may be frequency error in the RF or something else.

    • Andrew Farris

      Chris, I’ve been refreshing some parts of the codebase for ham2mon as well and working some improvements. If you’ve got something on the DC Bias I’m interested. I’m going to be trying to incorporate a few other branches together that are not yet getting pulled to main branch in madengr’s repo and a couple other ideas I have as I can work it. https://github.com/lordmorgul/ham2mon

      • Chris Sullivan

        Hi Andrew,

        More of a guess, but is it possible there’d be DC Bias if the station is not on a multiple of 5 kHz? Or more likely, that the RTL-SDR frequency is not exact with the same result.


        • Chris Sullivan

          By the way, I’d be delighted to do some testing. Probably a better fit considering my math knowledge pretty much stopped at first year university, except my economics courses which don’t really count 🙂 I got as far in the code as noticing the 5kHz steps and figured that was the basis of the DC bias, but didn’t test further than that as the main reason for using the software has diminished, although it may come back.

          The reason I picked up on the software was that our 2 metre repeater was getting a lot of malicious interference for a while. It seems to have mostly gone away. I have a decently situated antenna and can pick up a lot of signals on the repeater input frequency, and was looking to characterize them, for instance looking at the amplitude of the CTCSS tone, or frequency errors (where the DC bias comes in) of the unmodulated carrier, etc. But without any new samples, there’s not much point, and to run the software, I have to reboot my desktop system into Ubuntu as the Pi 3B can’t keep up. I’d like to try it on a Pi 4 but don’t have one to spare right now.

          • Andrew Farris

            Hi Chris,
            I’m admittedly weak on the signal processing side of things; I’m an RF Antenna Design Engineer with some digital and computer hardware background, but processing implications are a weak side. I do believe though that with AM signals you do see DC bias from having a frequency offset since you essentially get offset in the amplitude swings. But with FM, NBFM, having no additional modulation (quad, etc) I dont’ think that frequency offset causes much DC Bias. I’ll play with that in GQRX or CubicSDR to see what I think. For a frequency offset of the channel in FM you should see a reduction in energy collected in the channel but not necessarily a strong DC Bias as I understand it.
            “The other notable cause of DC offsets is the presence of a strong in-band interference source(s) in the
            received signal. AM modulated signals are particularly problematic with the receiver second order
            intermodulation (IM2) response producing varying DC. Near-zero IF and low IF systems are not as
            susceptible to IM2 DC offsets as true zero IF (direct conversion) designs.” From this resource: https://www.digikey.de/Site/Global/Layouts/DownloadPdf.ashx?pdfUrl=FD48D904BC024E19AA8C72A9EFFD13E8

            I confirmed you can play around with that channel width setting and the program runs fine with 2500, 5000, 10000 for instance. For your specific use case I would think making it narrower could help identify near-by noise by recording it in separate demodulator but that also will have some energy from signals on repeater frequency in a side bin with half the spectrum that demodulation will sound strange so have to check whether it was the sideband of the primary signal or another interferer for each time thats recorded. Anyway you can play with it if you like seems to work, I think I might make that a command line parameter.

  2. mike

    doesn’t work here 🙁

    ./ham2mon.py -a “rtl” -n 4 -f 145E6 -r 2E6 -g 20 -s -40 -v 0 -t 30 -wlinux; GNU C++ version 4.6.3; Boost_104900; UHD_003.004.002-0-unknown

    Traceback (most recent call last):
    File “./ham2mon.py”, line 131, in
    File “/usr/lib/python2.7/curses/wrapper.py”, line 43, in wrapper
    return func(stdscr, args, *kwds)
    File “./ham2mon.py”, line 55, in main
    freq_correction, record, lockout_file_name, play)
    File “/home/pi/ham2mon/apps/scanner.py”, line 69, in init
    hw_args, freq_correction, record, play)
    File “/home/pi/ham2mon/apps/receiver.py”, line 450, in init
    integrate_ff = blocks.integrate_ff(100, fft_length)
    File “/usr/local/lib/python2.7/dist-packages/gnuradio/blocks/blocks_swig3.py”, line 287, in make
    return _blocks_swig3.integrate_ff_make(args, *kwargs)
    TypeError: integrate_ff_make() takes at most 1 argument (2 given)
    [email protected] ~/ham2mon/apps $

  3. Mario Filippi

    DE8MSH: To set it up with the RTLSDR you connect an antenna to the RTLSDR dongle and using HDSDR software, tune the SDR dongle to the same frequency as the wireless transmitter. Remember to pick an FM broadcast frequency that is not in use in your area or is very weak. Make sure you are in FM mode, and you should hear the sounds coming out your laptop computer’s speakers. On the lower right of the HDSDR dashboard you will see the audio waterfall and spectrum. Adjust the range of the spectrum as needed, e.g. 0 – 7000 hertz. To record sounds, just click on the record function on HDSDR.

  4. DE8MSH

    Dr op KD4HSO,

    how to set it up for RTLSDR? I Found nothing related in the repo. Can you give us some information how to do it?

    Thank in advance.


Post a comment

You may use the following HTML:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>

This site uses Akismet to reduce spam. Learn how your comment data is processed.