Turn your Raspberry Pi into a FM Transmitter – Hack Radio Frequencies

1. First off, you need to get your Pi to transmit sounds by using PiFM, download the binaries from icrobotics (download), extract them and run the following commands in the same folder:

$> sudo python
>>> import PiFm
>>> PiFm.play_sound("sound.wav")

2. To expand your range connect a 20cm plain wire to the Pi’s GPIO 4 to act as antenna. GPIO 4 is the 4. pin on the on the left row (inner row) of pins. I simply cut a wire of its plug and twisted it around the pin.

FM Transmitter

3. Tune your FM radio to your preferred frequency, I’ll choose 106,7 Mhz.

4. To change the boadcast frequency run the ./pifm binary as following:

sudo ./pifm sound.wav 100,0

This will broadcast on frequency 100 Mhz. In most countries only frequencies between 88 Mhz and 108 Mhz are working properly.

Run the ./pifm binary without arguments to find usage.


It is possible that manipulating the FM broadcasting system is illegal in your country!
I am not responsible for anything you do after reading this tutorial!

2 comments to Turn your Raspberry Pi into a FM Transmitter – Hack Radio Frequencies

  • Pascal  says:

    Hay! Is it possible to use another pin? GPIO 4 is already used @ my system (PicoBorg…).

    If not: Is it possible to use the picoborg as amplifter? For more range?

    • rezin  says:

      Hi, just have a look at the Python module, maybe it is possible to change the pin, but I don’t think so.

Leave a reply

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>