2/17/2006EECS150 Lab Lecture #51 Logic Analyzers EECS150 Spring 2006 – Lab Lecture #5 David Lin Greg Gibeling.

Slides:



Advertisements
Similar presentations
Verilog Overview. University of Jordan Computer Engineering Department CPE 439: Computer Design Lab.
Advertisements

Combinational Logic.
Lab7: Introduction to Arduino
Sumitha Ajith Saicharan Bandarupalli Mahesh Borgaonkar.
1 Brief Introduction to Verilog Weiping Shi. 2 What is Verilog? It is a hardware description language Originally designed to model and verify a design.
Electrical and Computer Engineering MIDI Note Number Display UGA Presentation and Demo ECE 353 Lab B.
ECE 551 Digital System Design & Synthesis Lecture 08 The Synthesis Process Constraints and Design Rules High-Level Synthesis Options.
EECS150 Lab Lecture #61 AC97 PCM Audio EECS150 Fall 2007– Lab Lecture #6 Udam Saini 10/05/2007.
ECE 551 Digital System Design & Synthesis Lecture 09 Synthesis of Common Verilog Constructs.
2/24/2006EECS150 Lab Lecture #61 N64 Controller (Project Checkpoint#1) EECS150 Spring2006 – Lab Lecture #6 Philip Godoy Guang Yang Greg Gibeling.
Useful Things to Know Norm. Administrative Midterm Grading Finished –Stats on course homepage –Pickup after this lab lec. –Regrade requests within 1wk.
1/20/2006EECS150 Lab Lecture #11 EECS150 Intro. & CAD Tools EECS150 Spring 2006 Lab Lecture #1 David Lin.
10/1/2004EECS150 Lab Lecture #51 Good Design & Network Audio EECS150 Fall2004 – Lab Lecture #5 Udam Saini.
2/16/2007EECS150 Lab Lecture #51 Logic Analyzers EECS150 Spring 2007 – Lab Lecture #5 Shah Bawany.
2/9/2007EECS150 Lab Lecture #41 Debugging EECS150 Spring2007 – Lab Lecture #4 Laura Pelton Greg Gibeling.
ELEN 468 Advanced Logic Design
From Design to Verilog EECS150 Fall Lecture #4
DIGITAL ELECTRONICS CIRCUIT P.K.NAYAK P.K.NAYAK ASST. PROFESSOR SYNERGY INSTITUTE OF ENGINEERING & TECHNOLOGY.
8/31/2007EECS150 Lab Lecture #11 EECS150 Intro. & CAD Tools EECS150 Fall 2007 Lab Lecture #1 Shah Bawany.
1 COMP541 State Machines – 2 Registers and Counters Montek Singh Feb 8, 2007.
02/10/06EECS150 Lab Lecture #41 Debugging EECS150 Spring 2006 – Lab Lecture #4 Philip Godoy Greg Gibeling.
1/19/2007EECS150 Lab Lecture #11 EECS150 Intro. & CAD Tools EECS150 Spring 2008 Lab Lecture #1 Ke Xu.
10/31/2008EECS150 Lab Lecture #10 The Waveform Generator EECS150 Fall Lab Lecture #10 Chris Fletcher Adopted from slides designed by Chris Fletcher.
Overview Logistics Last lecture Today HW5 due today
Guest Lecture by Ben Magstadt CprE 281: Digital Logic.
Guest Lecture by Ben Magstadt CprE 281: Digital Logic.
Introduction to FPGA AVI SINGH. Prerequisites Digital Circuit Design - Logic Gates, FlipFlops, Counters, Mux-Demux Familiarity with a procedural programming.
ASIC/FPGA design flow. FPGA Design Flow Detailed (RTL) Design Detailed (RTL) Design Ideas (Specifications) Design Ideas (Specifications) Device Programming.
Spring Introduction  Today’s tutorial focuses on introducing you to Xilinx ISE and Modelsim.  These tools are used for Verilog Coding Simulation.
Comments on Lab #4 Annotating Timing Diagrams Draw viewer’s attention to the points you are trying to show / verify –Important output states glitch or.
Advanced Digital Circuits ECET 146 Week 5 Professor Iskandar Hack ET 221G, Me as I typed this slides.
ECE 551 Digital System Design & Synthesis Fall 2011 Midterm Exam Overview.
LAB #2 Xilinix ISE Foundation Tools Schematic Capture “A Tutorial”
C++ Programming Language Lecture 2 Problem Analysis and Solution Representation By Ghada Al-Mashaqbeh The Hashemite University Computer Engineering Department.
1 Workshop Topics - Outline Workshop 1 - Introduction Workshop 2 - module instantiation Workshop 3 - Lexical conventions Workshop 4 - Value Logic System.
1 COMP541 Sequential Circuits Montek Singh Feb 1, 2012.
Anurag Dwivedi. Basic Block - Gates Gates -> Flip Flops.
The UNIVERSITY of NORTH CAROLINA at CHAPEL HILL State Machines Anselmo Lastra.
CSCI-365 Computer Organization Lecture Note: Some slides and/or pictures in the following are adapted from: Computer Organization and Design, Patterson.
Introduction to ASIC flow and Verilog HDL
The Hashemite University Computer Engineering Department
Teaching Digital Logic courses with Altera Technology
2/3/2006EECS150 Lab Lecture #31 Implementation of FSMs EECS150 Spring 2006 – Lab Lecture #3 Guang Yang Greg Gibeling.
2/2/07EECS150 Lab Lecture #31 Verilog Synthesis & FSMs EECS150 Spring 2007 – Lab Lecture #3 Brent Mochizuki Greg Gibeling.
CprE 281: Verilog Tutorial Ben Magstadt – Master’s Student Electrical Engineering.
1 University of Jordan Computer Engineering Department CPE 439: Computer Design Lab.
1 Workshop Topics - Outline Workshop 1 - Introduction Workshop 2 - module instantiation Workshop 3 - Lexical conventions Workshop 4 - Value Logic System.
Overview Logistics Last lecture Today HW5 due today
Hardware Description Languages: Verilog
Figure 8.1. The general form of a sequential circuit.
Using Xilinx ChipScope Pro Tools
Supplement on Verilog Sequential circuit examples: FSM
Hardware Description Languages: Verilog
Digital Engineering Laboratory
EECS150 Intro & CAD Tools EECS150 Fall Lab Lecture #1
Logic Analyzers EECS150 Fall Lab Lecture #5 Arjun Singh
ChipScope Pro Software
332:437 Lecture 8 Verilog and Finite State Machines
LAB #2 Xilinix ISE Foundation Tools Schematic Capture “A Tutorial”
EECS150 Fall 2007 – Lab Lecture #4 Shah Bawany
Debugging EECS150 Fall Lab Lecture #4 Sarah Swisher
ECE 554 Digital Engineering Laboratory Nam Sung Kim (Chunhua Yao –TA)
Debugging EECS150 Fall Lab Lecture #4 Sarah Swisher
ChipScope Pro Software
The Verilog Hardware Description Language
Digital Engineering Laboratory
The SDRAM Controller EECS150 Fall Lab Lecture #8 Chen Sun
Logic Analyzers EECS150 Fall Lab Lecture #5 Arjun Singh
Verilog Synthesis & FSMs
332:437 Lecture 8 Verilog and Finite State Machines
Presentation transcript:

2/17/2006EECS150 Lab Lecture #51 Logic Analyzers EECS150 Spring 2006 – Lab Lecture #5 David Lin Greg Gibeling

2/17/2006EECS150 Lab Lecture #52 Today Lab #3 Solution Synplify Warnings Debugging Hardware Administrative Info Logic Analyzer ChipScope ChipScope Demo – Not on webcast!

2/17/2006EECS150 Lab Lecture #53 Lab #3 Solution (1) Simple Solution Use the standard 2 (or 3) block FSM format 1. (posedge Clock) block that instantiates the register that contains state. 2. Combinational logic block that responds to inputs and state changes by updating nextState wire and outputs. 3. Optionally, block that updates outputs.

2/17/2006EECS150 Lab Lecture #54 Lab #3 Solution (2) Cleaning Up Your Verilog FSM Code (ps) begin case (ps) STATE_Init: begin Open = 1’b0; Prog1 = 1’b0; Prog2 = 1’b0; Error = 1’b0; if (Decode1 & Enter) ns = STATE_Ok1; else if (~Decode1 & Enter) ns = STATE_Bad1; end... STATE_Ok2: begin Open = 1’b1; Prog1 = 1’b0; Prog2 = 1’b0; Error = 1’b0;...

2/17/2006EECS150 Lab Lecture #55 Lab #3 Solution (3) (ps) begin Open = 1’b0; Prog1 = 1’b0; Prog2 = 1’b0; Error = 1’b0; case (ps) STATE_Init: begin if (Decode1 & Enter) ns = STATE_Ok1; else if (~Decode1 & Enter) ns = STATE_Bad1; end... STATE_Ok2: begin Open = 1’b1;... How about using assign statements for outputs?

2/17/2006EECS150 Lab Lecture #56 Synplify Warnings (1) Why Bother? in the Synthesis Report (Errors are Part of your project grade Major warnings will cost points Knowing these will make your life easier Saves debugging Always run synthesis before simulating in ModelSim! Incomplete Sensitivity List ModelSim will use the sensitivity list Synplify pretty ignores it

2/17/2006EECS150 Lab Lecture #57 input[15:0]A, B; output[31:0]Sum; outputCOut; // Adder (A) {COut, Sum} = A + B; Synplify Warnings (2) inputClock; reg[31:0]Count; // Counter (posedge Clock) Count <= Count + 1; OK! Incomplete Sensitivity input[15:0]A, B; output[31:0]Sum; outputCOut; // Adder (A or B) {COut, Sum} = A + B; OK!

2/17/2006EECS150 Lab Lecture #58 Synplify Warnings (3) Latch Generated input[1:0]select; inputA, B, C; outputOut; regOut; // Mux (select or A or B or C) begin case (select) 2’b00: Out = A; 2’b01: Out = B; 2’b10: Out = C; endcase end input[1:0]select; inputA, B, C; outputOut; regOut; // Mux (select or A or B or C) begin case (select) 2’b00: Out = A; 2’b01: Out = B; 2’b10: Out = C; default: Out = 1’bx; endcase end

2/17/2006EECS150 Lab Lecture #59 Synplify Warnings (4) Combinational Loop Must remove the loop or add a register Multiple assignments to wire/reg Nothing should be assigned to in more than one place! ∞??

2/17/2006EECS150 Lab Lecture #510 Synplify Warnings (5) FPGA_TOP2 always has warnings Un-driven Input Unconnected Output These are truly unneeded pins Things like the audio chips… Your modules should not have warnings

2/17/2006EECS150 Lab Lecture #511 Synplify Warnings (6) Why bother? Getting rid of warnings saves debugging Synplify warnings will result in lost points Warnings are the only syntax check Verilog is a forgiving language Undeclared variables default to 1 bit wires This isn’t a good thing

2/17/2006EECS150 Lab Lecture #512 Debugging Hardware (1) Debugging Algorithm Hypothesis: What’s broken? Control: Give it controlled test inputs Expected Output: What SHOULD it do? Observe: Did it work right? If it broke: THAT’S GREAT! If we can’t break anything like this then the project must be working…

2/17/2006EECS150 Lab Lecture #513 Debugging Hardware (2) Using the logic analyzer / ChipScope The most reliable tool you have When used properly Use the triggers effectively Trigger on recurring sequences Trigger on errors An unstable display is useless Compare synthesis to simulation ChipScope is almost as good as simulation

2/17/2006EECS150 Lab Lecture #514 Debugging Hardware (3) Before you change anything Understand exactly what the problem is Find an efficient solution Evaluate alternative solutions After the change Fixes may make things worse sometimes May uncover a second bug May be an incorrect fix Repeat the debugging process

2/17/2006EECS150 Lab Lecture #515 Administrative Info (1) Lab/Project Partners If you don’t have a partner, stay after lab lecture and we’ll help you get partnered up. Remote access to Xilinx tools Use Remote Desktop Connection to access kramnik.eecs.berkeley.edu. A link to the kramnik set-up guide is on the documents page. Also useful for transferring files to and from your U:\ drive.

2/17/2006EECS150 Lab Lecture #516 Administrative Info (2) The grade book is online. Use your web account to access it. We will update the grade book roughly once a week. Hours spent on labs/checkpoints will not affect your grade. U:\ is only for storage. 100 MB limit. Don’t synthesize on it! Use “Project”  “Cleanup Project Files” before copying to U:\

2/17/2006EECS150 Lab Lecture #517 Administrative Info (3) Pick up graded assignments from cabinet at the back of room. Midterm 1 graded, except for #5 Mean ~71/80 so far. If you have #5 grade, then you’re done. If not, it’ll be up soon. There are still problems with computers in ½ the room. We’ll post to web site when it’s fixed.

2/17/2006EECS150 Lab Lecture #518 Lab #6: Logic Analysis (1) Exhaustive FSM Testing Very similar to Part3 of Lab #4 You’ll be mapping the whole FSM No bubble-and-arc to start from No single step Takes an input every cycle at 27MHz Much too fast to see on the LEDs Logic Analyzer!

2/17/2006EECS150 Lab Lecture #519 Lab #6: Logic Analysis (2) Logic Analyzer HP54645D Mixed Signal Oscilloscope Analog Oscilloscope Digital Logic Analyzer Graphs Signals vs. Time Like a timing diagram Invaluable for Debugging This is your only tool for examining your clocks Easy to see trends in signals…

2/17/2006EECS150 Lab Lecture #520 Lab #6: Logic Analysis (3)

2/17/2006EECS150 Lab Lecture #521 Lab #6: Logic Analysis (4) Procedure Set up the Logic Analyzer Synthesize the design Write a test pattern and set SW10 Press Single on the logic analyzer Press Reset to start the test Examine the waveforms Build a bubble-and-arc diagram

2/17/2006EECS150 Lab Lecture #522 The Logic Analyzer (1) Graphs Voltage vs Time Takes real signals from a CUT Can show both analog and digital signals Great for signal quality, delay, timing

2/17/2006EECS150 Lab Lecture #523 The Logic Analyzer (2) 16 Digital Inputs Excellent Debugging Tool Not very many input signals Digital Controls Trigger Controls

2/17/2006EECS150 Lab Lecture #524 The Logic Analyzer (3) Read the Lab. This is just a quick 10min demo.

2/17/2006EECS150 Lab Lecture #525 ChipScope (1) Software based logic analyzer Get results on the computer Put a logic analyzer right into the FPGA ICON – Connects FPGA to software ILA – Does the actual analysis More flexible than the bench analyzers Can create busses Advanced triggering support

2/17/2006EECS150 Lab Lecture #526 ChipScope (2) Steps to use ChipScope Generate an ICON Generate an ILA Connect the ILA to the ICON Synthesize, and implement your design With the ILA and ICON Program the CaLinx board Run the ChipScope Pro Analyzer Runs over the JTAG, not Slave Serial connection!

2/17/2006EECS150 Lab Lecture #527 ChipScope (3) Logic Analyzer Similarities/Differences Triggering is similar Can be set to show waves before trigger Can trigger on repeated or combined events Data/Trigger can be MUCH bigger Up to 256bits wide As many samples as Block RAM on the FPGA Data is captured synchronously Can’t look at clocks Much easier to view waveforms

2/17/2006EECS150 Lab Lecture #528 ChipScope (4) ChipScope is useful to verify In this lab we’re using it just to make absolutely sure You will NEED ChipScope You cannot debug a large design (i.e. your project) without it Bench analyzers won’t show enough signals It helps to master use of HP Logic Analyzer and ChipScope early on. You want to have ready knowledge of both tools for when you’re working on the project.

2/17/2006EECS150 Lab Lecture #529 ChipScope (4) Detailed ChipScope Tutorial Tutorials Tutorials Get used to reading technical documents and tutorials. It’s a useful and necessary job skill for engineers.

2/17/2006EECS150 Lab Lecture #530 ChipScope Demo Aren’t you glad you decided not to webcast today?