Git Product home page Git Product logo

cmod-s7-25-xadc's Introduction

Cmod S7-25 XADC Demo

Note: This demo has been migrated to another repo. You can find instructions for working with the demo here: Digilent Reference - Cmod S7 XADC Demo. Sources are version controlled in the Cmod-S7 repo.

Description

This project demonstrates how to use the Cmod S7-25's Spartan 7 FPGA's analog-to-digital core (referred to as the XADC) with a Microblaze processor. Vivado is used to build the demo's hardware platform, and Xilinx SDK is used to program the bitstream onto the board and to build and deploy a C application.

To use this demo, the Cmod S7 must be connected to a computer over MicroUSB, which must be running a serial terminal. For more information on how to set up and use a serial terminal, such as Tera Term or PuTTY, refer to this tutorial.

As long as the demo is running, ten times per second, the voltages on each of the Cmod S7-25's DIP header's analog input pins (AIN32 and AIN33) are read and printed to a connected serial terminal. The readings are accurate to two decimal places. Take care not to apply a voltage greater than 3.5 Volts to the analog pins. Any voltages less than 0 Volts or greater than 3.3 Volts are read as those instead.

Requirements

Demo Setup

  1. Download the most recent release ZIP archive ("Cmod-S7-25-XADC-2018.2-*.zip") from the repo's releases page.
  2. Extract the downloaded ZIP.
  3. Open the XPR project file, found at <archive extracted location>/vivado_proj/Cmod-S7-25-XADC.xpr, included in the extracted release archive in Vivado 2018.2.
  4. In the toolbar at the top of the Vivado window, select File -> Export -> Export Hardware. Select <Local to Project> as the Exported Location and make sure that the Include bitstream box is checked, then click OK.
  5. In the toolbar at the top of the Vivado window, select File -> Launch SDK. Select <Local to Project> as both the workspace location and exported location, then click OK.
  6. With Vivado SDK opened, wait for the hardware platform exported by Vivado to be imported.
  7. In the toolbar at the top of the SDK window, select File -> New -> Application Project.
  8. Fill out the fields in the first page of the New Application Project Wizard as in the table below. Most of the listed values will be the wizard's defaults, but are included in the table for completeness.
Setting Value
Project Name Cmod S7-25-XADC
Use default location Checked box
OS Platform standalone
Target Hardware: Hardware Platform design_1_wrapper_hw_platform_0
Target Hardware: Processor microblaze_0
Target Software: Language C
Target Software: Board Support Package Create New (Cmod-S7-25-XADC_bsp)
  1. Click Next.
  2. From the list of template applications, select "Empty Application", then click Finish.
  3. In the Project Explorer pane to the left of the SDK window, expand the new application project (named "Cmod-S7-25-XADC").
  4. Right click on the "src" subdirectory of the application project and select Import.
  5. In the "Select an import wizard" pane of the window that pops up, expand General and select File System. Then click Next.
  6. Fill out the fields of the "File system" screen as in the table below. Most of the listed values will be the defaults, but are included in the table for completeness.
Setting Value
From directory <archive extracted location>/sdk_appsrc
Files to import pane: sdk_appsrc Checked box
Into folder Cmod-S7-25-XADC/src
Options: Overwrite existing resources without warning Checked box
Options: Create top-level folder Unchecked box
  1. Click Finish.
  1. Plug in a test circuit to the Cmod S7-25's analog input pins.
  2. Open a serial terminal application (such as TeraTerm FIXME LINK) and connect it to the Cmod S7's serial port, using a baud rate of 9600.
  3. In the toolbar at the top of the SDK window, select Xilinx -> Program FPGA. Leave all fields as their defaults and click "Program".
  4. In the Project Explorer pane, right click on the "Cmod-S7-25-XADC" application project and select "Run As -> Launch on Hardware (System Debugger)".
  5. The application will now be running on the Cmod S7. It can be interacted with as described in the first section of this README.

Next Steps

This demo can be used as a basis for other projects by modifying the hardware platform in the Vivado project's block design or by modifying the SDK application project.

Check out the Cmod S7's Resource Center to find more documentation, demos, and tutorials.

For technical support or questions, please post on the Digilent Forum.

Additional Notes

For more information on how this project is version controlled, refer to the digilent-vivado-scripts repo.

cmod-s7-25-xadc's People

Contributors

artvvb avatar

Stargazers

ejc avatar danielchu avatar

Watchers

James Cloos avatar Sam Kristoff avatar  avatar Sam Bobrowicz avatar  avatar

Forkers

artvvb eslamfayad

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.