LogicLab Copyright Notice This software package and document are copyrighted (c) 1988, 1989 by Stephen B. Duff and VS Graphics. All rights reserved. This document must accompany all copies of LogicLab. Disclaimer VS Graphics makes no warranties as to the contents of this software product and specifically disclaims any implied warranties of merchantability or fitness for any particular purpose. VS Graphics further reserves the right to make changes to the specifiations of the program and contents of the manual without obligation to notify any person or organization of such changes. Shareware Notice This program was originally a commercial software package that sold for $39.95 via mail order. However, with advertising costs being what they are, I had to make a choice between marketing this program and feeding my children. Therefore, I decided to rlease this product as shareware to acheive the widest possible distribution with minimum costs. You may copy and distribute this product freely, provided that no fee is charged for such copying and distribution, and it is distributed only in its' original unmodified state along with this document. If you find the product useful, please feel free to send your donation to me at the address listed at the end of this document. You may not use this product in a Government, Commercial or Educational organization without paying a licence fee of $39.95. For those interested in programming in C on the Amiga, I will make the source code for the program available for $59.95. The source code is available for both the Lattice and Manx C compilers. If you are new to C programming or the Amiga, the source code can be a great time saver. INSTRUCTIONS 1.0 Getting Started First, rename the file LogicLab.inf to LogicLab.info to show the icon for LogicLab. Second, LogicLab allows you to specify the disk drives that will be used in the Load/Save Project file requester. Drive DF0: will be available by default. Two additional drives can be made available by creating a file with the appropriate drive name (e.g. create a dummy text file named DH0 for a hard drive). These are the only options that needs to be specified before running the program. 2.0 Running the Program Point to the LogicLab icon and double click the left mouse button to start the program. The screen contains two main areas. The logic symbol gadgets appear across the top of the screen. The area below the logic symbols is the work area of the screen. To begin a project, point to a logic element, press the left mouse button and drag the element to a location in the work area. Release the left mouse button when the element is in the desired location. The work area will hold up to 7 rows of 11 elements. Once the logic elements are in the desired locations, they must be connected. After connecting the elements you may view the solution of the logic in real time by going to the RUN mode. Connecting elements and executing the logic is described below. 3.0 Menu Selections The three main menus will be displayed at the top of the screen after pressing the right mouse button. To make a selection, press and hold the right mouse button down. Move the pointer to one of the main menus. Then move the pointer to one of the menu items. Release the mouse button while pointing to the desired item. 3.1 Project Menu The project menu contains 6 menu items. They are New, Open, Save, Save As, Print and Quit. 3.1.1 New Selecting New from the Project menu erases all elements that have been added to the work area and initializes LogicLab for a new project. A warning will be displayed if the current project has not been saved. You will have the option of saving the curent project before the current project is erased. If the project save requester appears, point to the appropriate selection and press the left mouse button. 3.1.2 Open The Open menu selection is used to load a project into memory from the disk drive. The Load Project requester will appear with a list of the files contained in the current directory. The proportional gadget at the right side of the requester can be use to show additional files in the list if they are present. You may select a disk drive by pointing to the desired drive gadget near the bottom of the requester. If additional sub-directories are present, they can be selected by pointing to them and presing the left mouse button. When you have located the project that you want to load, point to it and press the left mouse button. Finally, if you want to load the project, point to the Load gadget located at the bottom left side of the requester and prss the left mouse button. You may also cancel the load operation by pointing to the Cancel gadget located at the bottom right side of the requester. Then, press the left mouse button to cancel. 3.1.3 Save Save is used to store a previously named project to disk. Save automatically stores the project without opening the Save Project requester. You must use the Save As menu item to give the project a name. 3.1.4 Save As The Save As menu selection is used to give the current project a name and to save the project to disk. Once Save As has been selected, the Save Project requester will be displayed. You have the option of changing the disk drive and the various disk dirctories that are available on your disk by selecting the appropriate gadget. After selecting the desired drive and directory, point to the Project Name string gadget and press the left mouse button. Type a valid AmigaDOS filename for the project and prss the Enter key. The project will be saved to the name you specified if you point to the Save gadget in the lower left corner of the requester and press the left mouse button. You may cancel the save by pointing to the Cancel gadget in the lower right corner and by pressing the left mouse button. 3.1.5 Print The Print menu item is used to print a project. Make sure you have run the Preferences program supplied with your Amiga and that you have configured the correct printer. Before selecting the Print option, make sure that your printer is on line and that there is sufficient paper. The project will be printed automatically after making this selection. 3.1.6 Quit The Quit menu item is used to end the program. The LogicLab screen will move down and disappear at the bottom of the screen. You will see the screen that was present before starting the program. 3.2 Edit Menu The Edit menu contains only one menu item named Cut. There are two sub- items under the Cut selection. Press the right mouse button and move to the Edit menu selection. You will see the Cut menu item. Move the pointer to the Cut menu item and the two sub-items will appear to the right. Move the pointer to the desired sub-item and release the right mouse button. 3.2.1 Element The Element sub-item is used to remove a logic element from the work area along with all the connections to the selected item. Move the pointer to the element to be removed and press the left mouse button. The element will be erased along with all input and output connections comming into or leaving the selected element. 3.2.2 Connection Connections between logic elements may be removed using this sub-item. Select the Connection sub-item. You will be prompted at the top of the screen to select the first element. Move the pointer to the first element and press the left mouse button. If the first element has more than one output, you will be prompted to select the top output (OUTPUT A) or the bottom output (OUTPUT B). Answer the prompt in the requester. Once the output has been selected, you will be prompted for the second element. Move the pointer to the second element and press the left mouse button. If there are two inputs to the second element, you will be prompted to select either the top input (INPUT A) or the bottom input (INPUT B). Make the appropriate selection and the program automatically deletes the line connecting the two elements. 3.3 Control Menu The Control menu contains selections for directing the various operations that may be performed in LogicLab. The menu items are available to Add elements, Connect elements, Run the logic in real time and to Stop running the logic. 3.3.1 Add The Add mode is the default mode when LogicLab is started. While in Add mode, new logic elements may be placed in the work area. Elements are added to the work area by pointing to the element, pressing and holding the left mouse button down, and by dragging the element to a position within the work area. You must re-enter the Add mode to continue adding elements after placing the program in other modes. 3.3.2 Connect The Connect mode is used to make the connections between logic elements that have been placed in the work area while in the Add mode. After selecting the Connect mode, you will be prompted to point to the first element. Move the pointer to the first element and press the left mouse button. If the element has more than one output, a requester will appear with prompts for you to identify the desired output. Make your selection by pointing to the OUTPUT A or OUTPUT B gadgets. You will then be prompted to select the second element. Again, if the second element has more than one input a requester will appear with prompts to select the desired input. 3.3.3 Run The Run menu item places the program in the Run mode and solves the logic that has been placed in the work area. While in the Run mode, you may change the state of logic Input elements by pointing to them and pressing the left mouse button. If the Input element was previously in the logic 0 (OFF) state it will be placed in the logic 1 (ON) state and vice versa. If the Input element is in the Logic 1 (ON) state, a light bulb will appear within the Input element. The Input element is in the OFF state if no light bulb is present within the element. Logic is solved within the work area column by column from left to right. The Output logic elements are used to display the results of the logic in the work area. If a light bulb appears within an Output element, it is in the logic 1 (ON) state. The Output element is in the logic 0 (OFF) state if no light bulb is present within the element. 3.3.4 Stop This item ends real time execution of logic. 4.0 Logic Element Description LogicLab contains eight different logic element types. Each is described below. Truth tables are provided for each element type. While in the Run mode additional detail about the state of the elements' inputs and outputs may be obtained by pointing to the element and pressing the left mouse button. A window will open showing a strip chart graph of the state of the elements' inputs and outputs with respect to time. 4.1 Input Element The Input element is included so you can change the state of the inputs of other logic elements and see the result of the change. The Input element has a single output that is in one of two possible states. It can be a logic 1 (ON) or a logic 0 (OFF). You may change the state of the Input element in the Run mode by pointing to the element and pressing the left mouse button. Input Element Input Output --- ON --- OFF 4.2 Output Element The Output element is included so you can see the result of the solution of any logic elements in the work area. The state of logic elements can only be changed by the other logic elements connected to it. It can be in one of two possible states, logic 0 (OFF) or logic 1 (ON). The Output element has a single input. Output Element Input Output ON --- OFF --- 4.3 And Element The And element contains two inputs and one output. If both inputs are ON, the output of the And elenemt will be ON. If only one input is ON, the output will be OFF. And Element Input A Input B Output OFF OFF OFF ON OFF OFF OFF ON OFF ON ON ON 4.4 Or Element The Or element contains two inputs and one output. If either input is ON, the output of the Or element will be ON. Or Element Input A Input B Output OFF OFF OFF ON OFF ON OFF ON ON ON ON ON 4.5 Xor Element The Xor (exclusive-or) element is a relative of the Or element. The Xor element can be used to produce a binary sum with no carry. Xor Element Input A Input B Output OFF OFF OFF ON OFF ON OFF ON ON ON ON OFF 4.6 Not Element The not element has one input and one output. If the input to the element is ON, the output will be OFF. If the input is OFF, the output will be ON. Not Element Input Output ON OFF OFF ON 4.7 Flip-Flop Element The Flip-Flop element has two inputs and two outputs. The Flip-Flop element in LogicLab is known as a Set/Reset (SR) type flip-flop element. Input A (top) is the Set input. If the Set input is ON, the top output (OUT A) will be ON. The bottom output (OUT B) will always be in the opposite state of the top output. OUT A will remain ON regardless of the state of the Set input until the flip-flop is reset. The Flip-Flop element can be reset by applying a logic 1 (ON) to the bottom input (Reset). Flip-Flop Element Input A Input B Output A Output B ON OFF ON OFF don't care OFF ON OFF (Set) OFF ON OFF ON OFF don't care OFF ON Reset) 4.8 Timer Element The Timer element is used to provide what is known as an on-delay or off-delay timer function. When the input to the Timer element is turned ON, the timer accumulates time until it reaches a predetermined time (preset). The time interval in the LogicLab timer is one second. The element window must be opened to set the preset time value for the timer element. Point to the Timer element while in the Run mode and press the left mouse button to open the element window. Point to the area to the right of the Preset text and press the left mouse button. Type the preset time value and press return. Timer Element Input A Output A Output B OFF OFF ON ON OFF ON (before preset) ON ON OFF (after preset) 4.9 Counter Element The Counter element is used to cause a delay based on a preset count. When the Counter element is turned ON, the counter accumulates one count each time the logic on the work area is executed. Counter Element Input A Output A Output B OFF OFF ON ON OFF ON (before preset) ON ON OFF (after preset) 5.0 Element Windows When you are in the RUN mode, more detailed information about a particular logic element may be obtained by pointing to the element and pressing the left mouse button. After pressing the mouse button, the element window will be opened. Element windows may be opened for all elements except the Input and Output elements. Only one element window may be opened at any one time. The information shown in the element window is dependent upon the logic element selected. Each window shows the state of the elements' input(s) and output(s) with respect to time in the form of a strip chart. The update speed of the strip chart can be changed using the proportional gadget on the far right side of the element window. The Timer and Counter element windows show the Preset and Accumulator values at the top of the element window. You may change the Preset value of either element by pointing to the right of the Preset text and by pressing the left mouse button. The string gadget will be highlighted allowing you to type a new value for the Preset. Press return to enter the value. The element window may be moved to a different area of the screen by pointing to the drag gadget at the top of the window. Press and hold the left mouse button. Move the window to a new location and release the mouse button. The element window may be closed at any time by pointing to the window close gadget and by pressing the left mouse button. Once closed, you may open an element window for a different element. 6.0 Examples Several example projects are included on the disk and are located in the project directory. Follow the directions in the section describing Load Project. After loading a project, enter the RUN mode and follow the instuctions for the specific project outlined below. After trying the projects, experiment with your own logic circuits. 6.1 Project1 Project one contains one Input and one Output element connected together directly. Place LogicLab in the RUN mode to experiment with the logic circuit. Move the pointer to the Input element and press the left mouse button. The Input element will be placed in the ON state. A light bulb will appear within the Input element to indicate that it is ON. Since the Input and Output elements are connected directly, the Output element will be turned ON whenever the Input element is turned ON. The light bulb within the Output element indicates that it is in the ON state. Move the pointer to the Input element and press the left mouse button. The Input element will be turned OFF. When the Input element is in the OFF state, the light bulb within the element is no longer visible. The Output element is turned OFF and its' light bulb is no longer visible. After trying Project One, place LogicLab in the STOP mode. Select New from the Project menu. Then try building a circuit with Input and Output elements. 6.2 Project2 Project two is a circuit using the And element. The And element has two inputs and one output. An Input element is connected to each input of the And element. The single output is connected to an Output element. Move the pointer to the top Input element and press the left mouse button to turn the Input element ON. Notice that the Output element is still OFF. Now, move the pointer to the lower Input element and press the left mouse button to turn the Input element ON. When both inputs to the And element are ON, the output of the element is ON. The Output element is turned ON since it is connected to the output of the And element. Try building a new project using the And element. For example, build a circuit where three Input elements are used and all three must be turned ON to turn ON a single Output element. 6.3 Project3 Project three contains two Input elements, an Or element and one Output element. Move the pointer to the top Input element and turn it ON. When either input to the Or element is ON, its' output is turned ON. Turn the top Input element OFF and watch as the Output element is turned OFF. Try building your own project using the Or element. For example, build a circuit using three Input elements such that if any one of the three Input elements is ON a single Output element is turned ON. 6.4 Project4, Project5, Project6 and Project7 Project four through Project seven show simple citcuits using the Not, Flip-Flop, Timer and Counter elements respectively. Try each of the projects to see how these elements work individually. 6.5 Project8 Project eight contains two Input elements, an And element, a Not element and an Output element. They are connected to form a more complex logic function known as a Nand (not and) function. 6.6 Project9 Project nine is very similar to Project five. It contains a Flip-Flop, Input and two Output elements. The circuit shows how to build a square wave generator using a Flip-Flop. The top output of the Flip-Flop element is connected to the reset input of the Flip-Flop. Each time the Flip-Flop goes to the SET state, it resets itself. 6.7 Project10 This project demonstrates how to build what is known as a Latch function. The Latch is composed of two Not elements in series with the output of the second Not element also connected to the input of the first Not element. Once the input to the Latch is energized, the output is energized and remains energized regardless of the state of the input. 7.0 Registration We encourage you to become a registered user of LogicLab by completing a registration form with your name, address and computer model along with a donation to VS Graphics. Registration also allows us to keep you informed of new products, enhancements and any problems found in our software. If you should encounter any problems with the software or have any suggestions that would improve the product, please let us know as soon as possible. Problem reports, donations and suggestions should be sent to: VS Graphics P.O. Box 518 Hatfield, PA 19440