Skip to content

Latest commit

 

History

History
 
 

01-gates

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 

Lab 1: Introduction to digital circuits

The purpose of this laboratory exercise is to learn how to use the git versioning system, the Linux console to work in the lab, and verify basic logic functions using an online simulator.

Contents

  1. GitHub
  2. Linux terminal
  3. Online simulator
  4. Synchronize git

Preparation tasks (done before the lab at home)

  1. Create an account on GitHub server.

1 GitHub

  1. In GitHub, create a new public repository titled Digital-electronics-1. Initialize a README and MIT license.

  2. Use How to make the perfect Readme.md on GitHub, Basic writing and formatting syntax or Mastering Markdown articles and add the following parts in your README file.

    • Headers
    • Emphasis
    • List
    • Link
    • Table

2 Linux terminal

  1. Try basic commands in the Linux terminal:
Command Description
Ctrl+Alt+T Open Linux terminal in Ubuntu based distributions
Tab Automatic completion what you are typing or suggest options to you
Up/Down Browse command history
ls List directory contents
cd Change the current directory (change to parent directory: cd ..)
mkdir Make directories
pwd Print name of current/working directory
clear Clear the terminal screen
touch Create an empty file (if it does not exist)
cp Copy files and directories
mc GNU Midnight Commander (file manager)
  1. In the lab, make your own home folder within Documents, and with help of git command create a local copy of your public repository:

    $ cd
    $ pwd
    /home/lab661
    
    $ cd Documents/
    $ mkdir your-name
    $ cd your-name/
    $ pwd
    /home/lab661/Documents/your-name
    
    $ git clone https://github.com/your-github-account/Digital-electronics-1
    $ cd Digital-electronics-1/
    $ ls
    LICENSE  README.md
  2. Download Docs folder from teacher's repository and copy it to your Digital-electronics-1 local repository.

    $ ls
    Docs  LICENSE  README.md
  3. Make a new folder Images.

    $ mkdir Images
    $ ls
    Docs  Images  LICENSE  README.md
  4. Make a new folder Labs/01-gates and create an empty file README.md.

    $ mkdir Labs
    $ cd Labs/
    $ mkdir 01-gates
    $ cd 01-gates/
    $ touch README.md
    $ ls
    README.md

3 Online simulator

  1. Use online digital circuit simulator CircuitVerse, launch the simulator, draw and verify basic two-input logic gates.

    and_gates

  2. Run any text editor, such as Visual Studio Code, open Digital-electronics-1/Labs/01-gates/README.md local file (not on GitHub), create/complete tables with logical values, and add a screenshot from the simulator.

    A NOT
    0
    1
    A B AND NAND OR NOR XOR XNOR
    0 0 0 1 0 1 0 1
    0 1
    1 0
    1 1
  3. Use De Morgan's law and modify logic function to form with (N)AND and (N)OR gates only. Verify all three functions in online simulator.

    equation

     

    equation

     

    equation

     

    A B C equation equation equation
    0 0 0
    0 0 1
    0 1 0
    0 1 1
    1 0 0
    1 0 1
    1 1 0
    1 1 1

    Equations and symbols were generated by Online LaTeX Equation Editor as an Encoded URL link.

4 Synchronize git

  1. Use cd .. command in Linux terminal and change the working directory to Digital-electronics-1. Then use git commands to add, commit, and push all local changes to your remote repository. Check the repository at GitHub web page for changes.

    $ pwd
    /home/lab661/Documents/your-name/Digital-electronics-1/Labs/01-gates
    
    $ cd ..
    $ cd ..
    $ pwd
    /home/lab661/Documents/your-name/Digital-electronics-1
    
    $ git status
    $ git add <your-modified-files>
    $ git status
    $ git commit -m "[LAB] Adding 01-gates lab"
    $ git status
    $ git push
    $ git status

Experiments on your own

  1. Use digital circuit simulator and verify basic Boolean postulates:

    equation

    equation

    equation

    equation

    and Distributive laws:

    equation

    equation

  2. Use online digital circuit simulator, draw the logic diagram according to figure, complete the truth table, and determine the circuit function.

    logic

    A B Q3 Q2 Q1 Q0
    0 0
    0 1
    1 0
    1 1
  3. Try different online simulators, such as Logicly, simulatorIO, LogicEmu, or find others, and compare them.