Digsim

the Digsim site
 
   

A Digital Circuit Simulator

PDF
PDF

The digsim project is designed to introduce electrical/computer engineering students to the Object-Oriented paradigm.

Goals

The goals for this project are mainly educational. In particular, a specific problem that electrical engineering students can relate to—digital circuit simulation—is used to explore the following four phases of Object-Oriented practice.

Analysis:

The behaviour of digital circuits is analyzed. In particular, the event-driven model for simulating ideal digital circuits is examined (leveraging a student's knowledge of digital circuits and Boolean algebra). The analysis phase focuses on understanding the problem with scant reference to software issues.

Design:

Once the problem is understood in enough depth, the design of an Object-Oriented architecture—i.e. the classes, interfaces, etc.—can procede. Unlike the analysis phase, software concerns arise here. However, insofar as possible, these software issues should be teated generically at this level. It should be possible for a competent programmer to implement the design in any object-oriented language.

Implementation:

The design can then be impelemented in a some progamming language. I have chosen to use Java. (However, many of my students have also been subjected to an implementation in C. Yes, in C, not C++; although C is not an object-oriented language, it is possible to use it in an object-oriented way.)

Testing and deployment:

The implementation should also be rigorously tested and some strategy for deploying (e.g. packaging, distribution, documentation, etc.) the software product.

Note
It is wrong to infer that the 4 phases described above procede in linear way. In real design, the phases can be intertwined in various ways. It is not unusual, for example, to discover a problem during testing that is a result of an incorrect (or incomplete) analysis. Fixing the analysis may lead to changes in the design; it will certainly require changes in the implementation.

How to use this web page

A good starting point is the digsim package description which includes a basic analysis of the digital circuit simulation problem, an overview of the design and links to detailed design documents and implementation.

Note
Although this document covers both analysis and design, it is not a stand-alone paper. On the contrary, it is written using Java documentation conventions.

More intrepid readers can jump directly to the javadocs page.

Background

I believe that the Object-Oriented paradigm is best learned from examples that are relevant to the student. Otherwise, generic examples which are often so simple that a student may say “So what!”.

User interfaces

Although the main goal was and remains the analysis, design and implementation of an event-driven simulation engine, a basic user-interface has been added that allows digital circuits to be simulated without knowledge of the internal workings of the event-driven engine.

by Ken Clowes; v1.0 March 30, 2004
Valid HTML 4.01!Valid CSS!Built with Apache Forrest logo