Skip to content

roerohan/8086.js

Repository files navigation

Issues

All Contributors


Logo

A basic web-based 8086 emulator built with Javascript.
Explore the docs »

View Demo · Report Bug · Request Feature

Table of Contents

About The Project

8086.js is a basic 8086 emulator built using Javascript, hosted at https://roerohan.github.io/8086.js/.

Built With

Getting Started

To get a local copy up and running follow these simple steps.

Prerequisites

You will need the following to be able to run the project.

Installation

  1. Clone the Repo
git clone https://github.com/roerohan/8086.js.git
  1. Install NPM packages using (npm or yarn)

Using npm

npm install

Using yarn

yarn install

Note: If installing the packages with npm you get errors use yarn to install them.

Usage

Note: 8086.js does not support all instructions, pre-processor directives and interrupts yet. You can check out the supported instructions in the switch-case here.

To run the React App locally, you can run the following command.

  1. Run the React App

Using npm

npm start

Using yarn

yarn start

Basic Workflow

The UI is split into 2 major halves, the right half is the editor and the left half is the emulator. Instructions can be written in the editor, and when they are executed, the registers and memory in the emulator get updated accordingly. There are a few steps which happen in the background to make this possible.

  1. An object of the Emulator class is exported, which is the point of interaction between the frontend and the emulation logic.

  2. First, the lexer divides the source code into tokens and sends them to a parser. The parser is responsible for extracting instructions from the tokens and converting them to a form that the CPU understands.

  3. The CPU reads the mnemonic and the operands that were sent to it by the parser, and according to these values, it executes the instructions.

Note: The communication between the parser and the CPU is NOT in terms of shellcode, i.e, opcodes and operands. The CPU recognizes an instruction by it's mnemonic, such as MOV or ADD.

Roadmap

See the open issues for a list of proposed features (and known issues).

Contributing

Contributions are what make the open source community such an amazing place to be learn, inspire, and create. Any contributions you make are greatly appreciated.

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b feature/AmazingFeature)
  3. Commit your Changes (git commit -m 'feat: Add some AmazingFeature')
  4. Push to the Branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

You are requested to follow the contribution guidelines specified in CONTRIBUTING.md while contributing to the project 😄.

License

Distributed under the MIT License. See LICENSE for more information.

Contributors ✨

Thanks goes to these wonderful people (emoji key):


Rohan Mukherjee

💻 📖

Rishit Bansal

💻 📖

Ritika

💻

Rob Capellini

💻

Jose M. Segura Polanco

💻

Pranav P

💻

Namit Nathwani

💻

Sanjana Rai

📖

vikitor566

💻

This project follows the all-contributors specification. Contributions of any kind welcome!