Filter design and analysis in Linux

I was reading an article in the Danish hamradio magazine about a 1.8 MHz to 70 MHz SDR transceiver. In particular the RF frontend caught my attention because a set of band pass filters and a pre-amp would be a very useful companion for the USRP+LFRX, as would a power amplifier and a set of low pass filters be for the LFTX.

The article provided a reference to a filter design program called Elsie, which has been used to design the band pass filters of the SDR transceiver. It came as no surprise to me that Elsie is a 32 bit windows-only application. Fortunately, Elsie can be installed and run on Linux using the Wine windows emulator and runtime environment. I have tried using wine-1.1.31 on Ubuntu 9.10 and it works very well.

Elsie can be downloaded as a windows installer so we first have to install it. Go to the directory where you have downloaded the installer and type:

  alexc@solaris:~/Downloads$ wine LCinstall240.exe

The Elsie installer screen

By default the installer will install Eslie in the C:Program FilesElsie folder, which for the default wine configuration will be ~/.wine/drive_c/Program Files/Elsie

After successfull installation the Elsie can be executed with

  alexc@solaris:~/.wine/drive_c/Program Files/Elsie$ wine Elsie.EXE

The Elsie welcome screen

If you are not already familiar with the program you can start with “Retrieve old design” which will allow you to choose between several filters that come bundled with Elsie.

You can also choose the “New design” option which will take you to the design page shown below. Here you can select between the avaialble filter family and types, enter a few parameters like center frequency and band width and evaluate the result. You can use the buttons with “?” to get quick help on the options – they provide good info if you are not well fmailiar with the differetn filter types. The design page has many other menus that I have not yet explored so there are plenty of options to paly with. For this exercise I am going to design a band pass filter of the Butterworth fmaily for the 7.0 – 7.2 MHz.

The design page in the Elsie filter design tool

The “Schematic” page shows us the filter design with calculated values for all capacitors and inductors. We can adjust these values manually on the next page called “Edit” but we can wait with that for now.

The schematic overview in the Elsie filter design tool

The “Analysis” page will let us change parameters related to the presentation of the results, such as lower and upper limits for the plots. The “Plot” page will then show the varous plots of the filter, e.g. transmission, impedance, VSWR. These are the fancy plots we can see in magazines. Clicking on the plot will show the data for the clicked frequency and we can also insert fixed markers as I have done below.

The plot window in the Elsie filter design tool

We can now go back to the “Edit” page and manually change the values of the parts. We can use this to insert practical values instead of the theoretical ones, which can be difficult to achieve in particular for inductors. Changing a value here will show the new resonant frequency of the element right away and the “Plot” will be updated as well. Very clever and lots of fun.

In conclusion I can say that Elsie looks to be a very useful tool – even for us Linux users. Although the professional edition costs $200, the student edition is available for free and the only difference is that the number of stages is limited to 7. This should be more than sufficient given that a standard hamradio band filter can be accomplished using 3-4 stages – you don’t want to use too many parts anyway, right? The program is easy to use and even a non-expert like me can start designing filters right away. We will see later how my designs work in practice.

There is an even easier alternative running in a web browser at http://www.changpuak.ch/electronics/ – see under “Filter Design (RADIO)”. It can calculate to higher orders but it has fewer filter types and does not give us the nice plots.

Do you know of any other electrical filter design and analysis tool that will work in Linux? Let me know!

Once we have designed the filter we can go on and calculate the number of turns, etc. If we use iron powder toroids from Amidon we can use the mini Ring Core Calculator by Wilfried DL5SWB – again a windows application but it can also be installed and executed in Linux using wine.

mini Ring Core Calculator 1.2 running on Linux using Wine

Again, the aforementioned website provides a nice alternative that runs in the web browser.