next up previous
Next: 4.2 Extending the labAlive Up: 4 Using and extending Previous: 4 Using and extending

4.1 Using the labAlive Toolbox: the labAlive technician

  It's only one object, a java subclass of the class Wiring, that defines a specific wiring. To start, an applet or an application creates an instance of it. To get such a new labAlive Wiring, all you have to do is programming this class.

4.1.1 Basics

A simple example should demonstrate how to create a new labAlive Wiring. The circuit arrangement consists of a sine-wave generator, a low pass filter and a sink (figure 1, upper part).

The steps the labAlive technician has to do are:

1.
Create the systems needed
2.
Create the wires needed
3.
Make up wiring, connect wires and systems
4.
Define the layout
5.
Initialize
6.
Start simulation

Steps 1 to 3 are similar to the procedure in an electronics laboratory: First you gather the required systems like a generator and a low-pass filter (1.). Then you take the wires you need to connect all systems (2.) and connect up the wiring (3.).

After that you have to define the arrangement of the components to be displayed (4.). The rest is simple formality: To initialize the wiring (5.) you just have to supply the generators (i.e. StartableSystem) to the wiring adminstrator. This is only one codeline. Just as starting the simulation (6.), where you can define the simulation speed.

While a wiring is running, a click on wires shows a corresponding oscillograph displaying the signal. The oscillographs have a moving beam like real oscillographs. A click on systems opens a corresponding property window where parameters--like frequency and amplitude of the sine-wave generator--can be changed interactively. The appearance of this example wiring looks similar in style to the later referred radar system in figure 2.

4.1.2 Creating customized labAlive Wirings

  The example above was kept as simple as possible in order not to confuse by many optional features. When using a labAlive Wiring for on-line teaching, its appearance should be according to didactic requirements. A more elaborate example is the radar system shown in figure 2.

 

  figure114


Figure 2: An example for a labAlive Wiring: A radar system with animations. The sent electromagnetic wave moves to the right, is reflected and moves backwards. Switch and downsampler switch in time.

In the labAlive Wiring class several parameters can be set in order to determine the wanted appearance:


next up previous
Next: 4.2 Extending the labAlive Up: 4 Using and extending Previous: 4 Using and extending

Erwin Riederer
Wed Jun 16 11:01:00 MET DST 1999