Teensy Convolution SDR (Software Defined Radio)

Hi Mike,

filtering with FIR filters in the time domain is very inefficient when it comes to large filter sizes (= steep filters). It is much more efficient to filter in the frequency domain, which involves an FFT, a complex multiply with a filter mask and an inverse FFT. That process is called Fast Convolution.

In the context of the Teensy Convolution SDR, its all explained here:

https://github.com/DD4WH/Teensy-ConvolutionSDR/raw/master/Teensy Convolution SDR english.pdf

Also you could have a look at the excellent paper by Borgerding referenced in Wikipedia:


Youngblood has published a nice paper in 2002:


One side effect of using Convolution filtering in an SDR is that you do not even have to demodulate SSB at all, because the sideband suppression is already done in the filter (of course, you have to choose your filter bandwidth in the right way for LSB/USB) :).

Have fun with the Teensy Convolution SDR,

Last edited:
Compile error

Hi Guy's I am trying to compile Teensy SDR code and setup as per Jans instruction but still get the error below. Help would be much appreciated. 1.8.6 Arduino IDE.

C:\Program Files (x86)\Arduino\hardware\teensy\avr\libraries\Arduino-Teensy-Codec-lib-master\asmpoly_thumb2.S:2:2: error: invalid preprocessing directive #.

#.fpu softvfp


Error compiling for board Teensy 3.6.
Looks like an interesting project. FWIW I have successfully compiled 2018_03_24 code with Arduino 1.8.7, Teensy Loader 1.44 using https://github.com/DD4WH/Teensy-ConvolutionSDR.

However, not sure what kind of hardware radio to get. The GitHub article suggests "QSD = quadrature sampling detector and a local oscillator that can be tuned by I2C (eg. Si5351, Si570, Si514 . . .) [should run with Softrock, Elektor SDR (https://www.elektor.de/elektor-sdr-reloaded-150515-91), Fifi SDR and many others]

The ones mentioned on various pages are not available or don't seem to be Si5xxx.. based. Most seem to be complete SDRs not requiring your software solution. I'm not sure how to figure out where the QSD outputs would be. Any recommendations on how to select one? Will an open source for http://pa0rwe.nl/wp-content/uploads/2015/07/sdr_schematic.gif be available?

Hi Mike

you can contact pa0rwe whether he still has his excellent PCBs available.

or try the kit by QRP labs „Receiver module“, which has excellent Performance for its price.

we have very good experience with the Si5351 as a local oscillator

however, the Teensy Convolution SDR is more an educatioal project than a ready-to-use SDR.
so I recommend to read through all the relevant literature and the Wiki before buying any hardware.
Also have a look at the Wiki of our UHSDR software on github where you will find even more info on hardware but especially on the software and how they work.

Also for high performance you need proper lowpass RF filtering at the antenna input, (as with all QSD SDRs).

have fun and good luck

Thanks for the info. The QRP labs 'Receiver module' looks like the way to go with maybe the OCXO/Si5351A Synth kit.

I recently built Bob Larkins awesome AVNA and a nice 3D printed case to put it in.


The same display, Teensy and audio board are used. Some parts of the schematic are very similar, such as the instrumentation configured op amps. Wondering if I can use the AVNA PWB almost as is and modify your software to input the I Q data into the AVNA path. I have massaged your SDR software to display on the AVNA so far. This just required changing some I/O pins and a few other details. As you noted this is an educational project. Wonder what else I could repurpose from the AVNA without ruining it for its normal use.


Wonder what you think. Hopefully Bob will see this too.
Last edited:
Hi Guys, I'm joining the party :)
I've just complied the latest code and uploaded to a Teensy 3.6, serial monitor scrolling 'Unable to access the SD card', so all looking good so far....
Display on order expecting delivery next week, now looking into I & Q hardware, have emailed Joris enquiring about his SDR front end boards....
Has anyone designed a motherboard for the display, encoders and buttons? I'm learning a huge amount here already :)
Thanks Frank for this fasinating project.
Hi Kevin,

nice to hear that you are working on your Teensy Convolution SDR!

No, unfortunately, we have not yet produced a PCB design for such a motherboard. But you may consider Bob Larkins´ very nice approach:


and he also designed nicely usable RF frontend filters:


IQ hardware would be available here:



The latter one from Elektor looks highly recommendable and even already contains the Si5351 LO, although I have not used this newer version of the board, only the older one.

However, you have to be smart to adjust some of the components for your specific needs (bandwidth of the quadrature detector)

I'm learning a huge amount here already :)
Thats essentially what this project is all about! ;-)

Have fun with the Teensy Convolution SDR!

Frank DD4WH
Thanks Frank for the update, I did look at Bob's project box, very nice, but as always there's something that I would do differently, so I've decided to pull something together myself. I'll post the schematics in a week or two. but basically the idea at the moment is to mount the display, 6 buttons and 3 encoders ( 2 encoders with buttons the tuning encoder an alps smooth rotation optical with no button), headers for I2C and band pass switching and probably pull out the SPI as well. So this hardware can be panel mounted in one, in a very simular manner to the Juma TRX2 DDS front panel.
I also think I'll pull together the Si5153 / div x 4, splitter QSD and amps, copying the Juma front end on a seperate board. The band pass filters I'm still pondering over, but these can wait until I've finished the above :)
Like all of us, far too many projects on the go...... I NEED to retire soon.......
Hi Frank,
my pensioner status is some years old, so I have enough time for experiments.
After no success with a PSoC5LP SDR project (10 dB image rejection) I found your very interesting Teensy3.6 Convolution SDR.
I'm very impressed about your work, and I begun to solder the things together. The QSD is a little bit different from PA0RWE,
but consists of the same circuits. I hope, that with phase and amplitude calibration I get better results than with the PSoC.
What I miss is a complete description of the wiring, with all details. My try is attached, please, if you have the time, have a look at it.
(The table is very redundant, but helps me to make the right connections...)



Thank you!
Last edited:
Hi Wolfgang,

thank you for your interest!

Yes, you can expect 50-60dB of image rejection with the Teensy Convolution SDR, the automatic software I & Q phase & amplitude correction algorithm in realtime also eliminates the need for any hardware correction or manual calibrations or measurements :).

The pinout, the source code and a pdf describing the basic functioning can be found on github.

PINOUT: https://github.com/DD4WH/Teensy-ConvolutionSDR/blob/master/Teensy Convolution SDR pinout.txt

GITHUB & WIKI: https://github.com/DD4WH/Teensy-ConvolutionSDR/wiki

PDF with functional description: https://github.com/DD4WH/Teensy-ConvolutionSDR/blob/master/Teensy Convolution SDR english.pdf

I have no detailed hardware wiring diagram, because everyone uses a bit different hardware setup and thats the whole fun of it . . . :).

Have fun with the Teensy Convolution SDR,

Frank DD4WH
Good luck and have fun!

Frank DD4WH

Hello Frank,
now I finally see your "Teensy Convolution SDR" headlines on my screen. Unfortunately, I can not set a frequency yet ...

It is a pity, that you let a beginner standing in the rain, resulting of the lack of some absolutely necessary informations:
- SD card in the teensy slot is a must!!,
- informations on how to install the software,
- length of the compiled data structures (in my case 281344 Bytes EEPROM / 189564 Bytes RAM)

My goal is to understand the principles of your software. This is a little bit difficult...

Thanks and 73, Wolfgang
This is not a beginner project..
At least you need to know how Teensy and Arduino works (then you know that 281344 Bytes EEProm ist not possible, for example), and that the numbers are dependend on your teensyduino-version and optimize-settings :) before you begin..

What do you want to know? Maybe I can help a bit, too... (I have not build this project so far, but I plan to do it when I have more time)
You can get the connections from the sourcecode, at least.

(2nd Frank, not DD4WH :) )

Hi 2nd Frank,
Thank you for your answer.
My state is the following: (see picture)

The screen works, but the rotary encoders have no effect.
How are they connected? This is the pinout:

Teensy Convolution SDR pinout                
    Teensy name    DEVICE    PIN NAME    FUNCTION SDR
0        filter encoder button     button 6    
1        filter encoder        
2        filter encoder        
3        display    Backlight    
4        encoder 3        
5        encoder 3        
6        audioshield    MEMCS    
7        display/audioshield    TFT_MOSI/MOSI    
8        encoder 3 button    button 8    
9        audioshield    BCLK    
10        audioshield    SDCS    
11        audioshield    MCLK    
12        display/audioshield    TFT_MISO/MISO    
13        audioshield    Rx    
14        display/audioshield    TFT_SCLK/SCLK    
15            Volume    
16        tune encoder        
17        tune encoder        
18        audioshield/Si5351    SDA    
19        audioshield/Si5351    SCL    
20        display    TFT_DC    
21        display    TFT_CS    
22        audioshield    Tx    
23        audioshield    LRCLK    
24        attenuator PE4306 latch enable    ATT_LE    
25        attenuator PE4306 data    ATT_DATA    
26        LP Filter Band 5        
27        LP Filter Band 3        
28        attenuator PE4306 clock    ATT_CLOCK    
29        LP Filter Band 4        
30        LP Filter Band 2        
31        LP Filter Band 1        
32        display    TFT_RST    
33        push button    button 1    
34        push button    button 2    
35        push button    button 3    
36        push button    button 4    
37        push button    button 7    
38        tune encoder button    button 5    
39        audio amp enable    not yet used

So, for encoder3 for example, the switches connect to pin 4 and pin 5. There are encoders with different layout - be sure to use the right pins on the encoders.
In my case there is no attenuator and no LP Filter selector present. And the 5 buttons are not stocked yet.
Hm I don't know how the menu-handling works.. you don't need buttons for a try. You can use a wire and short the pins - just as test and "something" should

Edit: DON'T connect them to 5V - It can kill the Teensy 3.6 (not 5V tolerant)
Last edited:
Ok, thank you for your assistance!
I'm not a beginner (only at the Arduino IDE), my last projects were an SDR TRX with Red Pitaya and STM32F7 board, and the Antenna Analyzer EU1KY.
Hi guys!

@FrankB: thanks for chiming in!!! Followed your advances on T4, very very impressive !!!

@DH1AKF: sorry, Wolfgang for the insufficient documentation of the project! It is not in my intention to have you standing in the rain ;-).

Here are a few points, that could potentially be of interest:

* if there are problems with the CMSIS lib, follow the instructions here: https://forum.pjrc.com/threads/4059...Defined-Radio)?p=129081&viewfull=1#post129081

* sorry for the SD card problem, I will change the code not to stop when there is no SD card! You are absolutely right, that is annoying and should not be the case!

* beware, there is another problem: if the EEPROM has never been written (as is the case for everyone setting up the SDR for the first time), you need to do the following: comment out the line 1734:

// if loading the software for the very first time, comment out the "EEPROM_LOAD" --> then save settings in the menu --> load software with EEPROM_LOAD uncommented

Compile and upload. Start the Teensy SDR, go to "Save Eeprom" in the menu, press button --> all settings are now saved to EEprom and can be loaded

Then uncomment line 1734
compile and upload software again

Done! Now settings can be loaded!

My goal is to understand the principles of your software. This is a little bit difficult...

Well, the Teensy Convolution SDR is all about learning the principles of SDR, its basically the raw outcome of my trials of learning SDR and DSP, it was NOT intended to become a radio, but has accidentally evolved into some spaghetti code that works more or less :).

I have put many links and extensive information in the WIKI for this project and UHSDR (which is essentially very similar to the Teensy Convolution SDR in terms of DSP software):



Let me know if there are any questions left!

Have fun!

All the best 73s

Frank DD4WH