How do I save a recorded station in an audio file

Main forum to discuss RTL-SDR related topics.
Post Reply
Posts: 1
Joined: Mon Aug 14, 2017 4:17 pm

How do I save a recorded station in an audio file

Post by kunfuster » Mon Aug 14, 2017 4:39 pm

I am currently working on a Project related with rtl-sdr and I have some issues to solve and I wonder if you may help me.

Our aim is to build up a reciever by using a Raspeberry Pi (model 3, Jessie OS) to record the conversations in the control tower of Valencia's Airport. My dongle is 820T2.

I successfully installed your software and their utilites. I have been messing around with the different commands, such as, rtl_fm, rtl_sdr...

So, what I have thought in order to achive this goal are the following steps:

1) Record the airband every minute and save a 1 minute file
2) Analize that file to check if the control tower broadcast signal or not. The file must be full of noise if the case is not.
3) If signal was broadcast, delete the file. If not, then save the file

So, here comes the first issue. How could I do that? Saving the output in a file in the following way rtl_fm -M wbfm -f99.5M filename and convert it to a audio file? If that the case, how can I do that, I do not know how to face filename since I do now know how is the output format.

Another choice that I came up to was to use sox to record a 1 minute audio. But, I don't know how streaming recording works with sox.

Thank you so much!

Site Admin
Posts: 1360
Joined: Mon Nov 19, 2012 11:54 pm

Re: How do I save a recorded station in an audio file

Post by rtlsdrblog » Wed Aug 16, 2017 12:00 am

You can use the rtl_fm squelch and the sox silence features. Also it's probably best to use keenerds rtl-sdr version

There are some good examples here in her post and in the comments One particularly nice one is this line which should record a new audio file everytime someone talks.

Code: Select all

rtl_fm -M nfm -f $FREQ -p $PPM -s 16k -g $GAIN -l $SQUETCH | sox -r 16k -t raw -e signed -b 16 -c 1 -V1 - $FILENAME sinc 400-4500 silence 1 0.50 0.1% 1 2.0 0.1% : newfile : restart
You might also want to look into rtl_airband This also has a recording to mp3 feature which can skip silence.

Post Reply