Design Notes

Synthesis Outlines

Butterworth low-pass filter design procedure

To design a butterworth low-pass filter:

  1. Specify K (passband gain) ѡs, ѡs (passband and stopband frequencies) and their required attenuations, αp and αs.
  2. If K != 1, scale αp and αs to correspond to K == 1.
  3. Calculate the required filter order using eq 6.46 from [1]
  4. Calculate ѡ0 from eq 6.42 or 6.47
    1. Alternatively, skip the above steps and specify n and ѡ0
  5. Find the pole positions and transfer functions from eq 6.30 (remember to multiply by K)

If using a Sallen-Key topology:

  1. TBD: Figure out how to order the stages
  2. For each stage:
    1. Pick the sub-topology:
      1. If K==1, use Figure 6.19(b)
      2. If K < 0 (inverting), use Figure 6.19(d)
      3. If K is don’t care, use Figure 6.19(a) to consolidate component values
      4. If you need a 3-pole stage, use the Geffe circuit of Figure 6.32
      5. If K < 1, use Figure 6.21(a)
      6. Otherwise use Figure 6.19(c) and follow the procedure for Design 3
    2. Calculate normalized component values based on Q and K
    3. scale component values up to ѡ0
    4. magnitude scale to get practical values

Butterworth high-pass filter design procedure

  1. Specify requirements as in the low-pass procedure, step 1)
  2. Transform Ωs and Ωs to ѡs and ѡs by the RC-CR transformation using eq 6.80
  3. Design the low-pass filter starting with step 2)
  4. Apply the RC-CR transformation to the resulting circuit using eq 6.82

Topology Notes

  • 4amp_tow-thomas_bs.sch, if R3 = R1 / 2, is allpass

Graphics Notes

SVG notes

Use svgfig library to do manipulations

  1. Find the terminal markers in each file with the regex path.*fill:n.*C.*C.*C.*C
  2. From the markers calculate the translation for each stage
  3. For each figure, apply a transformation like this: lp[1].attr[u'transform'] = u"translate(100,0)"
  4. From the translations and the original widths and heights, calculate the new widths and heights
  5. Combine stages like this: firstage[1].append(secondstage[1])

SCH to SVG conversion

sch2svg.pl has serious problems.

  1. Doesn’t read .gafrc to find the sym directory
    1. Needs rework to support multiple LIBPATH directories
  2. Clips part of the output image
  3. Just doesn’t look right

However, sch2svg does preserve as much structure as possible

gs has problems:

  1. convert with ‘gs -sDEVICE=svg -sOutputFile=foo.svg bar.eps
  2. gs always renders the text as lines
  3. gs produces large output files

pstoedit to .sk and then skconvert to svg has problems:

  1. It always splits text strings into individual characters, even for monospaced fonts. The man page says this will only happen if you use -pti or -pta , but it always happens.
  2. It also does this for the .fig output
  3. It also does this for the .dxf output
  4. the ps2ai output is not recognized as .ai by uniconvertor

pstoedit to .svg has problems.

  1. it’s nonfree and only available for i386

inkscape has problems:

  1. it calls pstoedit to import eps files

uniconvertor has problems:

  1. while it claims to support eps, it appears to only read adobe illustrator output.

Screen Captures

To capture screen with vnc2swf.py, use these settings: clipping: 1250x980+330+95

vnc2flv.py has been recently released. It probably will work better than vnc2swf.py .

TODO

  • Add Cauer filters
  • Make Horz and Vert markers make sense in ZPK display mode
  • Solve filter synthesis equations numerically with scipy.optimize, instead of analytically. Then add features such as being able to choose different seed components
  • Tooltips everywhere! Especially the columns of PartsStore. Use http://www.astro.umass.edu/~dpopowich/python/
  • turn attributes into properties where appropriate
  • Add bandpass, bandstop, and allpass filters
  • Sort the components in SeedView and PartsView reasonably
  • Replace LM324.MOD with a GPL-3 compatible file

Credits

  • Wolfgang Glunz helped me with pstoedit
  • Jim Pivarski wrote svgfig.py
  • Paul McGuire for the doc_string_inheritor metaclass
[1]M. E. VanValkenburg, Analog Filter Design. New York, 1982