Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
cmod_a7:cmod_a7:cmod_a7_stopwatch:start [2016/07/15 19:41] Brandon Kallahercmod_a7:cmod_a7:cmod_a7_stopwatch:start [2021/05/14 23:06] (current) – ↷ Links adapted because of a move operation Arthur Brown
Line 1: Line 1:
 +====== Cmod A7 Stopwatch Demo ======
  
-====== CmodA7 Stopwatch WIP ====== +Using the CmodA7 and a 4-digit seven-segment display, this project creates a 10 second stopwatch with millisecond resolution.
-//Overview//+
  
-This Page is a WIP. Information **will** change+===== Prerequisites =====
  
-//images/video//+=== Skills === 
 +  * Basic familiarity with Vivado 
 +  * Familiarity with programming the GPIO of the CmodA7 
 +    * Follow the [[learn:programmable-logic:tutorials:cmod-a7-gpio-demo:start|CmodA7 GPIO Demo]]
  
-===== Prerequisites =====+=== Software === 
 +  * Vivado Design Suite
  
-Follow the [[learn:programmable-logic:tutorials:cmod-a7-gpio-demo:start|CmodA7 GPIO Demo]] +=== Hardware ===
-==== Software ==== +
-  * Vivado +
-==== Hardware ====+
   * CmodA7-15T or CmodA7-35T   * CmodA7-15T or CmodA7-35T
   * Four Digit 7-segment Display   * Four Digit 7-segment Display
   * Breadboard   * Breadboard
   * Jumper Wires   * Jumper Wires
 +
 ===== Procedure ===== ===== Procedure =====
-=== Wiring the CmodA7 to the 7-segment Display ====+==== 1. Wiring the CmodA7 to the 7-segment Display ====
  
 This step may be different depending on your 7-segment display. The one used in this project has the following pinout: This step may be different depending on your 7-segment display. The one used in this project has the following pinout:
Line 32: Line 34:
 </columns> </columns>
  
-For more information on Seven-Segment Displays see the [[reference:programmable-logic:nexys-4-ddr:reference-manual#seven-segment_display|Nexys 4 DDR Wiki]] section on them.+Place the Seven-Segment Display and CmodA7 in the breadboard. Using the Jumper Wires Connect the two parts using the following table as a guide. The display being used may have a different pin-out. If this is the case find the datasheet and wire according to that.
  
-//Schematic?//+<columns 100% - 40%  - ->
  
-=== Programming the CmodA7 ====+<newcolumn> 
 + 
 +^  Wiring Table                                                               ||| 
 +^  Signal                ^  Seven-Segment\\ Pin Number  ^  CmodA7\\ Pin Number 
 +^ Cathode A              |  11                          |  8                    | 
 +^ Cathode B              |  7                            6                    | 
 +^ Cathode C              |  4                            42                   | 
 +^ Cathode D              |  2                            40                   | 
 +^ Cathode E              |  1                            39                   | 
 +^ Cathode F              |  10                          |  7                    | 
 +^ Cathode G              |  5                            43                   | 
 +^ Decimal Point Cathode  |  3                            41                   | 
 +^ Digit 1 Anode          |  12                          |  3                    | 
 +^ Digit 2 Anode          |  9                            2                    | 
 +^ Digit 3 Anode          |  8                            1                    | 
 +^ Digit 4 Anode          |  6                            48                   | 
 + 
 + 
 +<newcolumn> 
 + 
 +</columns> 
 + 
 +When the wiring is done the breadboard should look something like this: 
 + 
 +{{ :cmod_a7:cmod_a7:cmod_a7_stopwatch:cmoda7_stopwatch_wiring.jpg?500 |}} 
 + 
 +For more information on Seven-Segment Displays see the [[programmable-logic:nexys-4-ddr:reference-manual#seven-segment_display|Nexys 4 DDR Wiki]] section on them. 
 + 
 +==== 2. Programming the CmodA7 ==== 
 + 
 +== 2.0 Open Vivado ==
  
 From Vivado open the Hardware Manager and open a target. From Vivado open the Hardware Manager and open a target.
Line 42: Line 74:
 {{ :cmod_a7:cmod_a7:cmod_a7_stopwatch:open_target.png?200 |}} {{ :cmod_a7:cmod_a7:cmod_a7_stopwatch:open_target.png?200 |}}
  
-Now there are two options:+After the CmodA7 connects there are two options for programming: 
 + 
 +== 2.1. JTAG == 
 + 
 +This will program the FPGA directly, the program will not run after a power cycle. 
 + 
 +**2.1.1:** Download and extract the BIT file for your board: {{:cmod_a7:cmod_a7:cmod_a7_stopwatch:stopwatch_15t_bit.zip |CmodA7-15T}} {{:cmod_a7:cmod_a7:cmod_a7_stopwatch:stopwatch_35t_bit.zip |CmodA7-35T}} 
 + 
 +**2.1.2:** In the Hardware Manager click Program device (in the green bar) then the device to program from the drop-down. Select the bit file and click program. Once the programming window closes the board is ready. 
 + 
 +{{ :cmod_a7:cmod_a7:cmod_a7_stopwatch:programdevice.png?500 |}} 
 + 
 +== 2.2. Quad-SPI == 
 + 
 +This will program the on-board flash memory, the program will run after a power cycle. 
 + 
 +**2.2.1:** Download and extract the BIN file for your board: {{:cmod_a7:cmod_a7:cmod_a7_stopwatch:stopwatch_15t_bin.zip |CmodA7-15T}} {{:cmod_a7:cmod_a7:cmod_a7_stopwatch:stopwatch_35t_bin.zip |CmodA7-35T}} 
 + 
 +**2.2.2:** In the Program Manager right click on the device and click Add Configuration Memory Device. 
 + 
 +{{ :cmod_a7:cmod_a7:cmod_a7_stopwatch:addconfigmem.png?500 |}} 
 + 
 +**2.2.3:** In the next window select the **n25q32-3.3v-spix1_x2_x4** device and click OK in the next window to program the device now. 
 + 
 +{{ :cmod_a7:cmod_a7:cmod_a7_stopwatch:memselection.png?500 |}}
  
-== 1JTAG ==+**2.2.4:** Select the BIN file that was downloaded above and click OK.
  
 +{{ :cmod_a7:cmod_a7:cmod_a7_stopwatch:progmemdevice.png?500 |}}
  
 +The flash will be programmed and will need to be power cycled in order to load the program from the memory.
  
-== 2. QUAD-SPI ==+===== Operation =====
  
 +To start the stopwatch press BTN0. To stop and reset the stopwatch press BTN1.
  
 +{{ :cmod_a7:cmod_a7:cmod_a7_stopwatch:cmoda7_stopwatch_on.jpg?500 |}}
  
 {{tag>learn programmable-logic project cmod-a7}} {{tag>learn programmable-logic project cmod-a7}}