Anth's Computer Cave

Using CircuitDraw to create electronics diagrams


A 7.2V power source regulated to 5V for a raspberry Pi. Image created by Anthony Hartup using CircuitDraw.

Today I will show you how to use Estimcad CircuitDraw to create diagrams for electronics and robotics projects.


Download and setup

There is no actual installation required for CircuitDraw, but you will need Python 3.4 installed on your system.

If you need help with that click here for a tutorial on how to install Python.

Once you have Python ready to go you can download CircuitDraw from here.

Extract the setup folder to wherever you would like to keep it. Open the folder and double-click the file called circuit_draw_alpha_02.py.


Using CircuitDraw

Interface

When CircuitDraw opens you will see a blank canvas with a Components column on the right and two drop-down menus on the left.

The initial blank CircuitDraw window.

The upper menu adds primary components like micro-controllers and breadboards.

The primary component CircuitDraw menu.

The lower menu adds secondary components such as cables and resistors.

The secondary component CircuitDraw menu.

Project example

The easiest way to show you how to use CircuitDraw is to build a sample project.

We will create a diagram of a system to power a Raspberry Pi and an Arduino board from one 7.2V power source.

From the Add Primary drop-down menu select Pi.

Select a Raspberry Pi.

Select Add

You should now have a Raspberry Pi.

A Raspberry Pi created with CircuitDraw.

Now repeat the process, this time choosing Arduino from the Add Primary menu and clicking Add.

Select Arduino from the dropdown menu.

You will see an Arduino Uno appear and an entry added to the Components column on the right.

An Arduino board has been added. Image created by Anthony Hartup using CircuitDraw.

Next we'll add a 7.2V power supply. Select Power Supply from the Primary component menu and click Add.

Select Power Supply from the Primary Component menu.

Enter the voltage for the power source and click Add Power.

Select the voltage for the power supply.

You should now have a power source.

A 7.2V power supply has been added. Image created by Anthony Hartup using CircuitDraw.

Now we'll add a breadboard to hold our voltage-regulator circuit.

Select Breadboard from the Primary Component menu.

There is our breadboard

A breadboard has been added. Image created by Anthony Hartup using CircuitDraw.

Those are all the primary components we need. Let's move on to the secondary components.

We need a voltage regulator to reduce the 7.2V power to 5V for the Raspberry Pi. We'll add an L7805ct three-pin IC.

Select IC from the Secondary Component drop-down menu and click Add.

Select IC from the Add Secondary menu.

You'll need to add the details for your IC.

Select Breadboard in the Board drop-down menu.

Select breadboard as the location for the IC.

Give the IC a name and enter the breadboard pin number for the first and last pins. Enter the model of the IC.

The details I have entered for this sample project.

Click Add IC.

An L7805ct regulator has been added to the diagram. Image created by Anthony Hartup using CircuitDraw.

There is our L7805ct running from pin 109 to pin 129.

Cables

Now we have our regulator it's time to connect everything together with cables.

Let's add the main power cable to the breadboard.

Select Cable from the Secondary Component drop-down menu.

Select Cable from the Add Secondary drop-down menu..

Give the cable a name and select Power1 + as Board One

Select Power1 + as the first cable end.

Select Breadboard from the Board Two drop-down menu and enter the breadboard pin-number to connect the cable to.

Select Power1 + from the Board1 drop-down menu.

Enter a thickness and color and click Add Cable.

Select Breadboard from the Board2 drop-down menu.

You have now added your first cable.

A cable has been added. Image created by Anthony Hartup using CircuitDraw.

Let's connect this main power to the Arduino. Once again, select Cable from the Add Secondary menu and click Add.

This time select Breadboard as Board One and enter the breadboard pin-number. Select Arduino as Board Two and enter "power".

Enter a thickness and color and click Add Cable.

A power cable has been connected to the Arduino. Image created by Anthony Hartup using CircuitDraw.

Now we connect power from Vout (the last pin) on the 7805 regulator to the Raspberry Pi. Choose Pi for Board One and enter "power". Choose Breadboard for Board Two and enter 126.

Details for a power cable to the Pi.

Enter a thickness and color and click Add Cable.

A power cable has been connected to Pi.

That is the positive power cables done, let's add some GND cables. This time for Board One we select Power1 -.

Details for GND cable to breadboard.

For Board Two select Breadboard and enter 117

Details for GND cable to breadboard.

Enter a thickness an color and click Add Cable.

A GND cable has beeen connected to the breadboard. Image created by Anthony Hartup using CircuitDraw.

There is our main GND cable. Now we'll extend that to the Arduino.

Details to connect a GND cable to the Arduino.

A GND cable has beeen connected to the Arduino. Image created by Anthony Hartup using CircuitDraw.

Finally, we need a GND to the Pi.

A GND cable has beeen connected to the Arduino.

Click Add Cable.

The finished CircuitDraw project. Image by Anthony Hartup

That is it, you have completed your first CircuitDraw project.

Save the project

To save your project just click the green Save button underneath the Add Secondary button.

By default CircuitDraw saves to a file called "circuit1.dat". Each subsequent save will automatically increase the number that is appended to the save-name. You can change the default name in the variables at the top of the code.

To open the project later, start CircuitDraw and turn off the GUI window but leave the Idle shell open. at the prompt, type the save-name you used earlier. Make sure the name ends with .dat and is enclosed in quotes.

The finished CircuitDraw project.

Next type main() and press Enter.

Your project should open just as it was when you saved it.

Export your project

To export your project, press ALT+PRINTSCREEN to take a screen-shot and save save it to a file. Open the file with Windows Paint and crop the image to display just the parts of the diagram you want. Save the PNG file.

Next article in the Series

In the third article in the series I will show you how to work with the various secondary components.

In the fourth final article we'll customize the CircuitDraw by modifying parts of the code. I'll guide you through moving the primary components around the canvas and changing the zoom, as well as manually controlling the window size.

I'll also show you how to remove or rename the CircuitDraw heading if you wish to personalize the program.

Cheers

Anth


Previous: Using CircuitDraw to create diagrams

Next: Using CircuitDraw to create diagrams

_____________________________________________

Comments

Leave a comment on this article