9 ms·
Turning the Raspberry Pi Into an FM Transmitter
- meaty 14y agoI bet the FCC (or RCA in the UK) will love that :) The amount of noise and harmonics that come off that sort of transmitter will be horrible. At least chuck a bandpass on the end of it.
- andyking 14y agoI don't suppose it's any more than a few mW - Ofcom don't seem to be interested in / able to remove the many high-power pirate radio stations, often with awful dirty signals, dotted around the UK (particularly London) so this would be a long way down their list of priorities! Even in rural Yorkshire, I get the "delights" of Phatt 100 and others every weekend. Agreed though - anything throwing unwanted noise onto the RF spectrum is a Bad Thing, however low-power it is (see powerline networking).
- meaty 14y agoTBH they're not really interested I understand as the FM broadcast band is on its way out in the UK.
- celticninja 14y agopirate radio stations have a long history especially in London, they frequently try to take them down, but so do rival radio stations try to take out their competitors radio stations too. Anyway, the FM band is still in use, see the furore over iTrip or similar devices that were at a time banned in the UK as the law said you needed a license to broadcast on FM. The FM band is still in use and even when radio goes digital AFAIK the idea is that the FM band would be available for alternative use once radio stations no longer require it.
- andyking 14y agoThe current modus operandi of most pirate radio operators is to run as a legitimate internet radio station - remove all reference to the FM broadcast frequency from the website and promotional materials, promote yourself as "the internet's no.1 grime station" or whatever. Then, when Ofcom come calling, the FM transmission is "someone relaying our internet broadcast, we don't know who it is."
- andyking 14y agoThis isn't true - I'm in the radio industry. High-level discussions have been taking place on the future of DAB digital radio, but there are no plans to switch off FM radio. It's FUD that's been spread over the past few years. At the very most, we will see a migration of national (and possibly large regional) stations to DAB in the next decade. FM will still remain up and running for local commercial and community radio - and an expansion of this is planned once the spectrum currently used by national broadcasters is released. The current FM and MW spectrum is of little use for new technology like mobile broadband - they are more interested in the current TV spectrum and up into the GHz bands. All this is currently under discussion, though, and nothing is confirmed. The status quo remains for now!
- CJefferson 14y agoSorry to jump in with a random reply. I've always been interested (just out of interest) to get an understanding of what the whole spectrum looks like, which bits are good (and why), and which bits are currently taken by what and could be used by other things. Is there any good place I could find such a thing that you know of?
- andyking 14y agoIn the UK, Ofcom provide quite a good overview of spectrum allocation here: http://spectruminfo.ofcom.org.uk/ http://spectruminfo.ofcom.org.uk/ This rather psychedelic PDF is linked from the above page: http://www.roke.co.uk/resources/datasheets/uk-frequency-allocations.pdf http://www.roke.co.uk/resources/datasheets/uk-frequency-allo... It doesn't say which allocations are good or bad - just what each slice of spectrum is used for. People like the mobile operators are only really interested in spectrum above the 800MHz area. This is where the competition for spectrum and billion-pound licence auctions come into play. Cellular companies are interested in line-of-sight frequencies in the UHF and SHF bands, where range is smaller but robustness of coverage is high. Then, they just blanket their desired area with cellular towers. VHF travels further, at the expense of robustness - it's ideal for broadcasting, but not for two-way data services. If you cleared FM and transplanted the existing 3G service onto, say, 100MHz, you'd find all sorts of interference issues. 87.5-108MHz, for instance, is used for FM broadcasting all over the world (except Japan where it's down in the 70s). The receivers will be available for the foreseeable future - certainly for my lifetime. If the band was vacated and all radio migrated to digital, the pirates would simply use it. It is of such little value - so it may as well be kept, rather than switching to digital for its own sake.
- synx508 14y agoYou might be interested in this response to a FOI request on the subject of pirate radio enforcement action. http://www.whatdotheyknow.com/request/141864/response/351401/attach/2/1%20223462781.pdf http://www.whatdotheyknow.com/request/141864/response/351401...
- Adirael 14y agoNah, they sell small FM transmitters you hook up to your MP3 in order to get the audio on your car audio system, this is kinda similar I guess (link is down for me at the moment).
- MBCook 14y agoNo, those have to comply with FCC regulations to ensure that the signal they are sending out isn't stomping over all the other bands. This has no filtering at all.
- noonespecial 14y agoNot the ones you get on eBay from china. I was finally able to drag a handful of them over to someone who had a decent spectrum analyzer and was duly horrified.
- bhousel 14y agohttp://en.wikipedia.org/wiki/Part_15_%28FCC_rules%29 http://en.wikipedia.org/wiki/Part_15_%28FCC_rules%29 Unlicensed broadcasts on the FM broadcast band (88 to 108 MHz) are limited to a field strength of 250 µV/m at a distance of 3 meters from the antenna. This is equivalent to 0.01 microwatts.[2] Emissions must be kept within the 88.0 to 108.0 MHz band under Part 15 rules.
- jdietrich 14y agoEmissions must be kept within the 88.0 to 108.0 MHz band Without a spectrum analyser, you have absolutely no idea how much energy is being emitted on other frequencies. A crude unfiltered transmitter of this sort is probably emitting more spurious energy than on the intended frequency. Ignorance is no defence and it is the obligation of the operator to ensure that their transmission is compliant. Lots of serious, life-or-death stuff depends on radio. The FM broadcast frequencies are directly adjacent to the VHF Airband, either side of 108MHz. The lowest part of the Airband is allocated to VOR and ILS navigation aids. Transmit a couple of watts on 107MHz and you're just going to interfere with broadcast radio; A couple of watts on 109MHz could take down a light aircraft. If you're going to experiment, you have a moral duty to get yourself an amateur license and ensure you have the skills and equipment to be a good neighbour.
- Nrsolis 14y agoAgree. Amateur radio operators have dummy loads and SWR meters to make sure that the signal they are putting out isn't stomping on some other critical portion of the RF band. Experimentation is a good thing, but this is the equivalent of someone being disturbingly careless experimenting with chemicals in their home "lab." The chance you could cause a serious problem with contamination for your neighbors is small but definitely non-zero.
- ul5255 14y agoI fail to see how a dummy load and a SWR meter will help to make sure you don't disturb other (portions of) RF band(s). To assess this you must look into the spectral purity of your signal. You do this with a spectrum analyzer (or equivalent). The SA is already 50 Ohms terminated so you at most need attenuators for your transmitter. The SWR meter will tell you if your transmitter is matched to your antenna. If not you might kill the final stage of your transmitter. SWR doesn't tell you something about radiating unwanted frequencies.
- darkarmani 14y agoWhat is the power output of something like this? Would the FCC even care?
- limmeau 14y agoThey describe they had to get several concrete walls and a metal cabinet between themselves and the Raspi before reception stopped, so I'd say too high.
- exhilaration 14y agoThey say, "This means that all you need to do to turn the Raspberry-Pi into a (ridiculously powerful) FM Transmitter..." and claim it's transmitting at least 50 meters away, which is far beyond what's allowed by the FCC. Not that they'd care unless someone filed a complaint.
- lifeguard 14y agoWrong. There are multiple rules for different spectrum. Anyone can transmit for miles on FM in the 'green dot' / 'blue dot' spectrum. The laws were written for business, but anyone can use them. http://en.wikipedia.org/wiki/Business_band#Overview http://en.wikipedia.org/wiki/Business_band#Overview
- mark-r 14y agoThe replies to this comment are missing your point. It's not just the power of the FM signal, it's the amount of extraneous junk outside the FM band that will be a problem. This is a very dirty signal generator.
- lifeguard 14y agoFilter functions Four general filter functions are desirable: Band-pass filter: select only a desired band of frequencies Band-stop filter: eliminate an undesired band of frequencies Low-pass filter: allow only frequencies below a cutoff frequency to pass High-pass filter: allow only frequencies above a cutoff frequency to pass http://en.wikipedia.org/wiki/RF_and_microwave_filter#Filter_functions http://en.wikipedia.org/wiki/RF_and_microwave_filter#Filter_...
- deleted 14y ago[deleted]
- lifeguard 14y agoHams solved all the issues I saw mentioned in the article 100 years ago. In the USA, it will be easy to break laws with this device. However, since the 1980s there has not been field enforcement by uncle Charlie (the FCC). Licensed users must complain a lot to get a response.\ For example, several times in CA police radio repeaters have been cross patched into HAM radio bands. No prosecution. Now, all that being said, jamming is the worst sin a radio operator can commit. Please be careful if you start transmitting. Not out of fear, but out of being a good operator.
- jjwiseman 14y agoHams, too.
- meaty 14y agoI have been the worst operator - a 12v car battery with a large file brushed across the terminals :) That interfered with EVERYTHING. 25 years later, an EE degree and 5 years working RF comms engineering, I realise what an asshat thing to do that was.
- lifeguard 14y agoI thought you were trolling at first!
- lifeguard 14y agoThere is far less noise on a proper antenna with filters. Hams deal with these issues all the time.
- 0x0 14y agoI wonder, would it be possible to do the same thing in reverse, i.e. use it as some kind of radio receiver that dumps .wav to disk?
- yuvadam 14y agoNo, but rtlsdr [1] is a classical use-case for raspis. [1] - http://sdr.osmocom.org/trac/wiki/rtl-sdr http://sdr.osmocom.org/trac/wiki/rtl-sdr
- DoubleCluster 14y agoJust found PiHAT - Rasberry Pi Home Automation Transmitter: http://www.skagmo.com/page.php?p=projects/22_pihat http://www.skagmo.com/page.php?p=projects/22_pihat
- emaste 14y agoThanks for that link. The PiHAT page does a much better job of explaining the details of how this works to me (as someone with a lot of hardware experience but not a lot of familiarity with the Broadcom SOC on the Pi).
- StavrosK 14y agoThat's fantastic, I discovered earlier that I had some plugs like those and now I'm trying to make them work. I've managed to make them turn off easily enough, but I can't for the life of me get them to turn on. Would anyone happen to know how I can tune in to my remote's frequency (144.63 MHz, it says, even though the remote operates at 433.49 or something) and listen to the tones it generates?
- mgunes 14y agoAn unreplied comment on a previous submission on HN was questioning the remote feasibility of running TCP over FM with the Raspberry Pi. I too am curious about the state of the art in general, if any, and how it might possibly be exploited for long-range networking between small computers like the Pi.
- sp332 14y agoPacket radio has increased in popularity in recent years. https://en.wikipedia.org/wiki/Packet_radio#Amateur_Packet_Radio_Evolution https://en.wikipedia.org/wiki/Packet_radio#Amateur_Packet_Ra... Might be worth looking into, although I'm not sure how practical it would be for the RPi.
- ge0rg 14y agoIt should be entierly possible to modulate packet radio using the GPIO hack, however you would probably need a real-time kernel extension to ensure proper transmission. Decoding is easily possible on the CPU as well, provided you attach soeme RF demodulation circuitry, e.g. to a sound card input.
- lifeguard 14y agoToo bad the amateur radio service forbids encryption. People do use ssh on packet, but it is a violation.
- gvb 14y agoYes, but it isn't practical or effective. You would be re-inventing 802.11 very poorly. 1) You could use the given technique to create the MOdulation side of a modem[1]. You would have to solve the receiver and DEModulation side. Not likely to be do-able with a bare Raspberry Pi so you will end up adding a receiver and probably a demodulator (software demodulation is theoretically within the grasp of a Raspberry Pi). Ref: http://en.wikipedia.org/wiki/Modem http://en.wikipedia.org/wiki/Modem 2) Your data rate would be dependent on how well you implement your modem. Assuming you limit yourself to audio range frequency modulation (i.e. 10-3000Hz), you will have a hard time exceeding 300 baud using frequency shift keying (e.g. modulate with two tones, one indicating '0' and the other indicating '1'). If you use phase shift keying, you may achieve 2400 baud, but (a) I really doubt that a Raspberry Pi can do phase shift keying, (b) demodulating PSK is much more difficult that frequency shifting, and (c) in my limited experience, attempting phase shift modulation on top of a FM carrier doesn't work for crap (FM can be viewed as a type of phase shift modulation, so you end up phase shift modulating a phase shift modulator which doesn't demodulate + demodulate reliably into your baseband signal). Ref: http://en.wikipedia.org/wiki/Modem#Narrow-band.2Fphone-line_dialup_modems http://en.wikipedia.org/wiki/Modem#Narrow-band.2Fphone-line_... Higher data rates over phone lines encode multiple bits per baud (signaling unit), making the encoding and decoding tasks go through the roof if done in software. Getting to e.g. 56Kbaud of the end-of-the-road phone modem is impossible - 56Kbaud only worked when the phone company digitized the phone audio, and rather iffy even then. Ref: http://en.wikipedia.org/wiki/Modem#Using_digital_lines_and_PCM_.28V.90.2F92.29 http://en.wikipedia.org/wiki/Modem#Using_digital_lines_and_P...
- jaykru 14y agohttp://webcache.googleusercontent.com/search?q=cache:www.icrobotics.co.uk/wiki/index.php/Turning_the_Raspberry_Pi_Into_an_FM_Transmitter http://webcache.googleusercontent.com/search?q=cache:www.icr...
- ck2 14y agoBack in the TRS-80 days, someone discovered they could make sounds through an AM radio and a few games took advantage of that.
- mark-r 14y agoI saw it done in the '70s with a PDP-8.
- jlgreco 14y agoBack when I was doing z80 programming on my TI-83+, I would sometimes us an AM radio as a very crude debugger. Programs stuck in busy loops would generally have a very distinct sound, and you were often over time able to learn what other parts of your program sounded like too.
- meaty 14y agoThat is one of those little stories which is just awesome. That's when you KNOW the machine. You just can't do that with anything these days. Even my HP50G calc is personality-free in that respect.
- jlgreco 14y agoYeah, my understanding is that doing that became difficult even on the higher end 83+/84+ series calculators as the clockrate went up, though I haven't actually put that to the test.
- jamii 14y ago> You just can't do that with anything these days You can fake it - https://github.com/jamii/mechanical-sympathiser https://github.com/jamii/mechanical-sympathiser
- deleted 14y ago[deleted]
- unimpressive 14y ago
- Joeboy 14y agoSince there's a nerdy rPi post at the top of HN, I'm going to take the opportunity to plug my new baremetal midi file player / lv2 audio plugin host: http://www.joebutton.co.uk/blog/baremetal-midi-lv2-raspberrypi/ http://www.joebutton.co.uk/blog/baremetal-midi-lv2-raspberry... When I get time I want to connect up a MIDI keyboard and audio input, so it becomes a synth / guitar stompbox that'll use an open audio plugin format.
- walshemj 14y agoNow that is cool will have to try that on one of my PI's
- jobigoud 14y agoFantastic, now we should combine that with a good text to speech engine so it can read aloud e-books, blogs, and whatnot during daily commute.
- antonb2011 14y agoWell, this is cool, but it would be cooler if they wrote an open source cell tower for GSM phones running on Raspberry Pi.
- IgorPartola 14y agohttp://wush.net/trac/rangepublic http://wush.net/trac/rangepublic
- anthonyb 14y ago$5k for a dev box? Not really in the same league...
- shaddi 14y agoI have this sitting on my desk at the moment (just OpenBTS + rPi + a SDR). Nothing too crazy about it. I like this because they are using the rPi itself as a radio -- that's a pretty neat hack.
- mynegation 14y agoOh, nice! Here is situation: I have a pretty old car with FM receiver and single CD player, with no line input. Problem: I want to listen to the music from my iPhone, hopefully with a distraction free interface. For that I need a horrible contraption from car power splitter, USB cable to the iPhone that usually doubles as GPS on the dashboard, audio cable back to FM transmitter down there plugged into power outlet. But now I can have a raspberry pi hidden somewhere, translating audio to FM and possibly recognizing my voice commands while at it like "play We Are the Void by Dark Tranquillity"
- holri 14y agouse a Nokia N900 with built in FM Transmitter
- yesbabyyes 14y agoOr you could get an iTrip, but I agree that the RPi is way more fun. http://www.griffintechnology.com/itrip http://www.griffintechnology.com/itrip
- StavrosK 14y agoWhy would you not play Lost to Apathy?
- RaphiePS 14y agoI just read about Distributed Dance Party [1], a movement that uses an FM transmitters and a bunch of boomboxes to power outdoor parties. Seems like this would be perfect for parades or groups that need a cheap way to communicate with a large number of people. [1] http://www.wired.com/underwire/2013/01/mf-decentralized-dance-party/ http://www.wired.com/underwire/2013/01/mf-decentralized-danc...
- lifeguard 14y agoI found this very exciting! Every Pi is now a potential pirate radio station! I imagine that if a proper ground plane antenna were hooked up to it the pi would transmit much farther. Are FM transmitters still restricted for civilians in some parts of the world?
- neya 14y agoThis is brilliant! Thanks for sharing!!
- ChuckMcM 14y agoHeh, that blows away my AM morse code sender [1] using a PIC. One of the things I did in the PIC and it would probably work here is to mush the data into a sort of pre-encoded form (which is ready to be shipped out to the transmitter) I expect you could do the same here by taking the wave file, precomputing what the stereo deltas on the FM signal would be than then just using that file (maybe a foo.efm for encoded-FM) then just DMA the pre-processed file to the spectrum offset and voila, done. [1] http://www.mcmanis.com/chuck/robotics/projects/eelb.html http://www.mcmanis.com/chuck/robotics/projects/eelb.html (and yes I'm re-doing the web site not in Comic Sans which will eventually all be moved to http://robotics.mcmanis.com http://robotics.mcmanis.com but until then ...