return 1; computer engineering and electronics
  • Home
  • Projects
  • Archive
Plotting ngspice results with Python

Featured Article

Plotting ngspice results with Python

The new return1.net!

Featured Article

The new return1.net!

Popular Articles

  1. No data yet..
  1. Plotting ngspice results with Python

    Written by Lucas on January 22nd, 2012

    My favourite schematic capture program on Linux is Gschem, part of the gEDA project. The gEDA project contains a lot of open source tools which aid in electronic design automation. Think of programs to create schematics and PCB boards, to view Gerber files and more.

    They're not as "user friendly" as OrCad or Multisim, but they work fine. For example, unlike most commercial schematic capture programs, most symbols in gEDA don't include a SPICE model by default, for most symbols you have to explicitly define which SPICE model to use when you want to start simulating. When you know what to do it's not that hard, and a project like spicelib makes it even easier.

    gEDA also doesn't integrate a circuit simulator into its user interface. We do actually have some nice simulators on Linux, which are both command line based. Examples are ngspice and gnucap. Both work great, but they aren't tightly integrated as most commercial software. This can be a bit overwhelming for users who are just starting with gEDA.

    Luckily, there's a nice tutorial on the gEDA wiki on how to simulate a circuit created with gEDA, and I'm not going to repeat that in this post. The point is, I don't like the builtin plot viewer of ngspice. When viewing a graph, you can't zoom, you can't move the viewport, it's just really basic. So, I've written a Python script which uses the matplotlib package to plot the results of ngspice, which looks a lot better than the builtin viewer. Details after the break!

    Read more - Comments
  2. The new return1.net!

    Written by Lucas on January 15th, 2012

    So, hi! It has been a long time since I've written something here. The last post according to http://web.archive.org is from September 17th, 2008, so that's more than three years. :) But we're back, and better than ever!

    I'm currently studying electrical engineering, and that's quite awesome. Electrical engineering is awesome because you can do great stuff with it, and I have tons of ideas for projects in the future. I sometimes also have some nice projects going on at the University I'm attending, and this site will give all those projects a home. Expect open hardware, detailed explanations of how the project was designed, and lots of other nice tricks and tips on electronics, computers and engineering.

    The design also got an update, thanks to the awesome work of Daan (http://dsng.us). But not only the design has been updated, the whole codebase is new, and more about that after the break!

    Read more - Comments