Third party cookies may be stored when visiting this site. Please see the cookie information.

PenguinTutor YouTube Channel

Free and Open Source Software for Linux and Windows

Interactive electronic circuit software

The software provided here is interactive circuit simulation software used as applets on the PenguinTutor electronics pages. This is written as an aid to teaching electronic circuit theory and to demonstrate electronic component functions.

This is my first attempt at programming applets and applications using the Processing programming language.

The electronic components, classes and functions are evolving as each of the applets / applications are created. Therefore if you would like to use the object classes in your own applications you should be aware that the components from each of the source code archives are unlikely to be compatible. The most recent version is the one nearest the top of the downloads table, this is the version most suitable for inclusion in other programs. This may be made into a library in future.

Electronic circuit demonstration - basic switch circuit

circuit1 is a simple switch circuit. The components are now created using object-oriented programming with the components created as individual classes. The circuit works as designed, but the class objects are not consistent in their orientation. The classes will undergo significant changes in the future interactive circuit simulators.

Electronic circuit simulator - diode half-wave rectifier

diode1 is a half-wave rectifier circuit showing the output voltage for an AC input voltage. There is a simulated "electron flow" showing whenever the diode is conducting.

This is my first attempt at programming using the Processing programming language. It is deliberately created without using object oriented programming or classes. This program is contained within a single pde (Processing Development Environment) file. It is not scalable and therefore not recommended to use the code in its current form as the basis of a more complex circuit.

Downloads

CircuitVersionLinuxWindowsMac OS XSource Code
circuit10.1circuit1-linux-0.1.tar.gzcircuit1-windows-0.1.zipcircuit1-macosx-0.1.zipcircuit1-src-0.1.tar.gz
circuit1-src-0.1.zip
diode10.1diode1-linux-0.1.tar.gzdiode1-windows-0.1.zipdiode1-macosx-0.1.zipdiode1-src-0.1.tar.gz
diode1-src-0.1.zip

Installation

These circuits are available as applets online on the Penguin Tutor electronic circuit applet pages. If you prefer they can be installed as applications following the instructions for the appropriate operating system below.

Linux

Java version 5 (JRE 1.5) or above must be installed on your system. This can be done using your distributions software package manager or by downloading from www.java.com.

Extract the files using the following command
tar -xvzf filename.tar.gz
Run the appropriate script (eg. circuit1). If this does not work you may need to change the permissions to make the script executable.
chmod +x circuit1

In certain circumstances Processing used with Java 5 may cause X to restart. This has been observed on Ubuntu Netbook Remix (Karmic version 9.10) running on an EeePC, but not on other platforms. See: How to get processing working on Ubuntu Netbook Remix - Karmic Koala (9.10) on an EeePC. If you experience this problem install Java 5 (it can be installed alongside Java 6, although it will need to be installed outside of the standard package manager). Then update the script to point at the JRE java binary file in Java verison 1.5.

If you do find this problem please post details on the Blog comment section for Processing on UNR bug. Provide details of the distribution you are running, the version of Java and what hardware (including graphics card) that you are running. If we can identify a common cause then it may help in identifying where the bug is and how to get it fixed.

Windows

Java version 5 (JRE 1.5) or above must be installed on your system. This can be downloaded from www.java.com.

Extract the zip file to a suitable location and launch the exe file (eg. circuit.exe).

Mac OS X

Java version 5 (JRE 1.5) or above must be installed on your system. This can be downloaded from www.java.com.

Unfortunately I am not able to test the Mac OS X application or provide detailed instructions. Extract the files and run the appropriate script.

Processing Source code (.pde)

The source code is in the form of processing development environment (pde) files. After extracting the files rename the directory to match the project name (ie. remove the -scr-version from the directory name). The pde file can then be opened in the processing pde.

The programs are written for Processing version 1.0.9. There appear to be some problems using processing with the latest version of JDK 1.6 (known as Java 6). It is therefore recommended that processing is installed with JDK 1.5 (Java 5) as the Java development platform. Fix for problems with Processing applications compiled with JDK 1.5. The application should run on any computer running any version of Java from version 5. It will still run on Java 6 on most computers if compiled using Java 5. In some rare circumstances it may be neccessary to run using Java 5 rather than Java 6.

You will need to generate the fonts using the Processing "Create Font" tool in the pde.

The applications / applets are designed to provide a visual representation for teaching. These are not intended to provide a realistic simulator suitable for simulating circuits on a computer prior to creating in hardware.