Animate Your Circuit Schematics With Free Software

This is a short tutorial on how to create animated electronic circuit schematics in minutes using a combination of free and open source software.

The 38Khz signal is applied to the ground side of each IR LED through the use of an NPN transformer

The 38Khz signal is applied to the ground side of each IR LED through the use of an NPN transformer

This is essentially a three part process using the following:

  • Circuitlab.com – Free online circuit schematic design – Very intuitive and easy to use.
  • Inkscape – An open source vector graphics program.
  • Gimp – A GNU advanced image manipulation program.

Step 1:  Create your schematic

circuitlab1

Circuitlab has a very intuitive drag and drop interface for creating electronic circuit schematics.  Register for a free account and you will be able to create, save, and share your creations.

Step 2:  Export the schematic to SVG format

Another great feature of circuitlab is that you can export your schematics to the SVG(Scalable Vector Graphics) format.  This just so happens to be the native format of Inkscape.

Step 3:  Open the schematic in Inkscape and set document properties

In the main menu, select File -> Open.

Inkscape2

Choose the file you just exported in step 2 above.  After it is opened, you’ll want to set the background to white.  This is an optional step but I’ve found it to be the most predictable results when creating animated gif’s.
In the main menu, select File -> Document Properties.

Click on the area immediately to the right of the “Background:” label.  This will pop open a dialog where you set the RGBA values of the background..Set all values to 255, 255, 255, 255.  This 4 number combination determines the RED, BLUE, GREEN, and ALPHA (TRANSPARENCY) values of the background.  In this case, it is white with 100% visibility.

Step 4:  Ungroup the schematic object

The SVG you exported in step 2 is considered one large object even though the individual components of the image are in tact in the SVG format.  We will need to ungroup these objects in order to edit them individually.

In the main menu, select Object -> Ungroup

Inkscape1

At this point, you can set the properties of these components one by one.  To make life easier, you can select different components and re-group into their own group of objects using the Object -> Group command from the same menu.

Step 5:  Export to PNG format and save the schematic.

This will be frame 1 of your animation.  In subsequent steps, you will be editing the schematic but you can always refer back to frame 1 for the original (before modifications).

In the main menu, select File -> Export

Inkscape3

When the export dialog appears, make sure the “Page” button is selected to ensure you aren’t just exporting a small section of the drawing.  This is also where the size of the export is determined.

Step 6: Change vector fill and stroke

Each line or object in the schematic has a fill and stroke (border) property that can easily be changed.

In the main menu, select Object -> Fill and Stroke

<img class="alignnone size-full wp-image-326" src="http://www.mycontraption buy zyban online.com/wp-content/uploads/2013/05/Inkscape4.png” alt=”Inkscape4″ width=”327″ height=”447″ srcset=”https://mycontraption.com/wp-content/uploads/2013/05/Inkscape4.png 327w, https://mycontraption.com/wp-content/uploads/2013/05/Inkscape4-219×300.png 219w” sizes=”(max-width: 327px) 100vw, 327px” />

A panel will appear with 3 tabs.  To change the properties of an object, select it in the drawing and then click on one of the tabs and select the color from the scale or enter the values manually.  To set it to Red, you would enter 255, 0, 0, 255.  If you aren’t familiar with setting these properties in Inkscape you may need to play around with it to get the feel for it.  One trick to changing multiple objects is to select them all at once (CTRL-A) and then holding down the SHIFT key as you deselect items you don’t want to change (such as labels).  Same thing for selecting items individually, hold down the SHIFT key as you select them.  I’ve found this to be different then most software where you hold down the CTRL key.

Inkscape8

There are many other tools that aren’t covered in this tutorial that could be useful such as flipping the components horizontally or vertically, changing stroke style to dashes, etc.

Step 7:  Export to PNG format and save the edited schematic

The goal is to create a PNG image of matching size for each frame in the animation.  You will  essentially repeat steps 6 and 7 until all frames are exported.

Step 8:  Drag exports from Inkscape into Gimp

Open Gimp and drag the first frame PNG image onto the blank canvas.

Gimp1

Drag the remaining PNG images on top of each other in their proper order.  This will automatically create layers in GIMP.  Since we set the background to 100% white, there is no issue with seeing more than one frame at a time.

Gimp2

Step 9:  Export animated GIF

The final step is to export the Gimp image to GIF format.  Choose the animation settings that best suit your needs.  The following are choices when exporting to GIF:

  • Loop Forever (Check this)
  • Delay between frames (In Milliseconds)
  • Frame Disposal (Blend or Replace)

In the main menu, select File -> Export

Change the image extension to “.gif”.  Choose “GIF Image” format at the bottom of the dialog.  You should then be prompted to choose your animation settings.

Gimp4

Finally, you should end up with an image that continuously rotates between the frames you created in Inkscape.  The following example is a simple 2 frame “On/Off” example of a simple LED circuit.

simple-led_animation

2 Comments

Leave a Reply

Your email address will not be published. Required fields are marked *