GithubHelp home page GithubHelp logo

eslamashhraf / serial-peripheral-interface Goto Github PK

View Code? Open in Web Editor NEW
3.0 1.0 2.0 2.26 MB

๐Ÿ“ก In this project, we only focus on the Multi-Slave Regular Mode. We design and implement the following components of the SPI modules using Verilog such that they match the requirements of the development testbench and match the SPI specifications (Master - Slave - Self-Checking Testbenches for the Master and Slave)

License: MIT License

Verilog 100.00%
verilog cufe-2024 master-slave modelsim

serial-peripheral-interface's Introduction

Serial Peripheral Interface

logo


๐Ÿ“ Table of Contents


๐Ÿ“™ overview

Design and implementation the following components of the SPI modules using verilog such that they match the requirements of the development testbench and match the SPI specifications:

  • Master
  • Slave
  • Self-Checking Testbenches for the Master and Slave.


๐Ÿš€ Get Started

  1. Clone the repository
    git clone https://github.com/EslamAsHhrafSerial-Peripheral-Interface
    
  2. Main File is
    Serial-Peripheral-Interface/DevelopmentTB.v
    
  3. Read Project Description to undertand project vey well

๐Ÿ“œ How project Work

  • After each CLK the Master chose The Slave Again with CS with Enable One Slave and Disable the Other.
  • At Test Bench of the Master is to Send and Receive data from many Slaves at Same Time This Is Mainly Testing the ability Of the Exchange Between the Master and Many Slaves.
  • At Test Bench of The Slave Is to Receive Data from Master and makes shift Operation and Resend Shifted Data.
  • It wait the signal of start to begin the transmission (also the master will read "masterDataToSend" in order to send it to the slave).
  • And it takes 8 periods to send all data from the master to slave and slave to master.
  • We make it with 2 test cases different.

At Posedge

Both the Master and the slave take shifting operation which the Master writes data to the MOSI and the Slave Writes data to the MISO.


At Negedge

Both the Master and the Slave make sampling operation which the Master reads data From the MISO and The Slave reads data from the MOSI


How Data transfered between Master and Slave

the data is shown on the MOSI and MISO line. The start and end of transmission is indicated by the dotted green line, the sampling edge is indicated in orange, and the shifting edge is indicated in blue. Please note these figures are for illustration purpose only. For successful SPI communications, users must refer to the product data sheet and ensure that the timing specifications for the part are met


Multislave SPI configuration


๐Ÿ“ธ Demo Screenshots

Simulation Results of Development testbench


Waveform of Development testbench


Simulation Results of Master testbench


Waveform of Master testbench


Simulation Results of Slave testbench


Waveform of Slave testbench


๐Ÿ—ƒ๏ธ File Structure

Serial-Peripheral-Interface
โ”œโ”€โ”€ Code
โ”‚   โ”œโ”€โ”€ Master.v
โ”‚   โ”œโ”€โ”€ Master.v.bak
โ”‚   โ”œโ”€โ”€ Master_tb.v
โ”‚   โ””โ”€โ”€ Master_tb.v.bak
โ”œโ”€โ”€ CMP1030 Project Description.pdf
โ”œโ”€โ”€ DevelopmentTB.v
โ”œโ”€โ”€ DevelopmentTB.v.bak
โ”œโ”€โ”€ Introduction-to-SPI-Interface.pdf
โ”œโ”€โ”€ Lincense
โ”œโ”€โ”€ README.md
โ””โ”€โ”€ Report .pdf

๐Ÿ‘‘ Contributors


Adham Ali


Abd Elrhman Fathi


Waer


Eslam Ashraf

serial-peripheral-interface's People

Contributors

eslamashhraf avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.