TOP Contributors

  1. MIKROE (2784 codes)
  2. Alcides Ramos (385 codes)
  3. Shawon Shahryiar (307 codes)
  4. jm_palomino (118 codes)
  5. Bugz Bensce (97 codes)
  6. S P (73 codes)
  7. dany (71 codes)
  8. MikroBUS.NET Team (35 codes)
  9. NART SCHINACKOW (34 codes)
  10. Armstrong Subero (27 codes)

Most Downloaded

  1. Timer Calculator (139842 times)
  2. FAT32 Library (72209 times)
  3. Network Ethernet Library (57392 times)
  4. USB Device Library (47739 times)
  5. Network WiFi Library (43364 times)
  6. FT800 Library (42700 times)
  7. GSM click (29980 times)
  8. mikroSDK (28440 times)
  9. PID Library (26989 times)
  10. microSD click (26398 times)
Libstock prefers package manager

Package Manager

We strongly encourage users to use Package manager for sharing their code on Libstock website, because it boosts your efficiency and leaves the end user with no room for error. [more info]

< Back
Project

Designing a Microprocessor from Scratch

Rating:

0

Author: Val Gretchev

Last Updated: 2014-05-29

Package Version: 1.0.0.0

Category: Other Codes

Downloaded: 539 times

Not followed.

License: MIT license  

Many students in electronics learn how to use and program a microprocessor but very few know what goes on inside the chip itself. This project will give the reader insight into the inner workings of a very simple 8-bit microprocessor that can be extended to more powerful designs.

No Abuse Reported

Do you want to subscribe in order to receive notifications regarding "Designing a Microprocessor from Scratch " changes.

Do you want to unsubscribe in order to stop receiving notifications regarding "Designing a Microprocessor from Scratch " changes.

Do you want to report abuse regarding "Designing a Microprocessor from Scratch ".

  • Information
  • Comments (0)
DOWNLOAD LINK RELATED COMPILER CONTAINS
Other Compiler
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc

Project Blog

Data Paths

Data Paths

This diagram depicts how the data moves from one resource to another.

View full image
PicoCode Sequencer

PicoCode Sequencer

This logic is where the instructions in RAM are interpreted and the data paths manipulated to execute those instructions.

View full image

 

  1. Introduction

    A long time ago, before integrated microprocessors, there was a wonderful chip with a number designation of 74181 (a 4-bit ALU). This was a time when you made up a microprocessor using many TTL logic chips. Two or four of these ALU chips made the core of a microprocessor. For a 16-bit ALU, there was a companion chip designated 74182 which was used to speed up the carry output.


    These chips are no longer readily available but the published circuit diagram makes it useful for simulation (see datasheets included in this package).


    Purpose

    Many students in Electrical Engineering learn how to use and program a microprocessor but very few know what goes on inside. This article will give the reader insight into the inner workings of a very simple microprocessor that can be extended to more powerful designs. I will use a visual method of ANDs ORs and Inverters to implement the data paths and controls. In order to do that, we have to use a logic simulator to test the design. Fortunately, there is a simple free program (CEDAR Logic) that accomplishes this task and is easy to learn.

    You can download it from the following URL:

    http://sourceforge.net/projects/cedarlogic/?source=dlp


    Design Description

    The file BlockDiagram.pdf shows the data paths that feed the ALU and RAM. There is only 1 Accumulator for simplicity. Control logic is centered on a 32-bit ROM that implements the sequences for fetching data from RAM and decoding the instructions. You can view the sequences as a state diagram but traditionally it’s called horizontal programming (see PicoCode.pdf). Each program word is 32 bits wide and includes the next address of the flow. Two way branching is possible on the Carry Latch, Zero Latch and bit 0 of the Op Code Register. A 16 way branch can be performed on the high-order 4 bits of the Op Code Register.

    As mentioned before, the Arithmetic-Logic-Unit is based on the 74181 datasheet. Refer to ALU.jpg for an image of the circuit as presented by the simulator. The page illustrated by A-SidePath.jpg shows the data paths feeding the A-side of the ALU. SystemRAM.jpg shows the B-side data path for the ALU. Sequence.jpg and ClockAndDisplay.jpg complete the entire design. 

 

ALSO FROM THIS AUTHOR

Mikromedia Plus for STM32 with Shield and GPS Click L10 Board.

0

This example uses the GPS click L10 board in slot 2 of the shield and communicates with it through UART2. Commands and messages are available using UART6-to-USB circuit on the shield board. The USB-HID Bootloader is used for loading the code. However, you can use mikroProg programmer if you prefer.

[Learn More]

Solar tracking algorithm for predicting sun location.

0

Here is another application for the Mini-M4 for STM32 board.

[Learn More]

Examples for FreeRTOS

0

I am delighted that FreeRTOS was ported for use with MikroE compilers. After trying the demo codes supplied by MikroE, I decided to try some of my drivers for USB and UART. After resolving some issues, I was able to get a lot of code working in the new environment and I wanted to share it with users.

[Learn More]