ex1 - digsys.upc.esdigsys.upc.es/.../00_old/09_10_q2/ex/ex4/e1_curs_09-10_q2_ex4.docx  · web...

14
EX3: Designing a dedicated processor EX 4ELECTRONICS I A digital heart rate meter ( preliminary) 1.1 Cooperative group TEAM NUMBER: ___________ DUE DATE: ________________ 1 st review due date: ________________ STUDY TIME: Study time (in hours) Group work Classroom and laboratory sessions Sessions out of classroom Individu al Student 1 Student 2 Student 3 STATEMENT: My signature below indicates that I have (1) made equitable contribution to EX 4 as a member of the group, (2) read and fully agree with the contents (i.e., results, conclusions, analyses, simulations) of this document, and (3) acknowledged by name anyone outside this group who assisted this learning team or any individual member in the completion of this document. Today’s date: __________________ Active members Roles: (reporter, simulator, etc.) (1) ________________________________________ _______________ 1

Upload: vanthuan

Post on 20-Jan-2019

216 views

Category:

Documents


0 download

TRANSCRIPT

EX3: Designing a dedicated processor

EX 4 ELECTRONICS I

A digital heart rate meter (preliminary)

1.1 Cooperative groupTEAM NUMBER: ___________

DUE DATE: ________________ 1st review due date: ________________

STUDY TIME:

Study time

(in hours)

Group work Classroom and laboratory sessions

Sessions out of classroom

Individual Student 1

Student 2

Student 3

STATEMENT:

My signature below indicates that I have (1) made equitable contribution to EX 4 as a member of the group, (2) read and fully agree with the contents (i.e., results, conclusions, analyses, simulations) of this document, and (3) acknowledged by name anyone outside this group who assisted this learning team or any individual member in the completion of this document.

Today’s date: __________________

Active members Roles: (reporter, simulator, etc.)

(1) ________________________________________ _______________

(2) _________________________________________ _______________

(3) _________________________________________ _______________

Acknowledgement of individual(s) who assisted this group in completing this document:

1

EPSC – E1: Electronics I

(1) _______________________

(2) _______________________

1.2 Abstract Explain here the most significant developments, results or conclusions about the exercise. Use the remaining space in this sheet (200 words maximum).

(This section is mandatory. You must complete it in order to get a mark.)

2

EX3: Designing a dedicated processor

CONTENT

A digital heart rate meter (preliminary)..........................................................................................................1

1.1 Cooperative group.....................................................................................................................................1

1.2 Abstract.....................................................................................................................................................1

1.3 Description................................................................................................................................................3

1.4 Topics........................................................................................................................................................3

1.5 Block diagram...........................................................................................................................................3

1.6 Project implementation.............................................................................................................................4

1.6.1 Divide project into smaller units.......................................................................................................4

1.6.2 Build the top architecture..................................................................................................................4

1.6.3 Prototype the project into the training board...................................................................................5

1.7 VHDL testbench........................................................................................................................................5

1.7.1 Testbench for a simple entity.............................................................................................................5

1.7.2 Testbench for the heart rate meter....................................................................................................5

1.8 A list of projects of similar complexity.....................................................................................................5

1.9 Problem solution (títol 2)..........................................................................................................................6

1.9.1 Part 1 (títol 3)....................................................................................................................................6

1.10 References.................................................................................................................................................7

1.11 Study plan to solve the exercise................................................................................................................8

1.12 Topics and activities checklist..................................................................................................................9

1.13 Grading grid..............................................................................................................................................9

1.14 Questions in solving EX2..........................................................................................................................9

3

EPSC – E1: Electronics I

1.3 DescriptionIn this fourth exercise, a project is to be proposed. Cooperative groups will have to plan, develop, simulate, implement and prototype a digital heart rate meter. The problem can be considered a complex design which includes multiple blocks and components. However, it has to be conceived as a dedicated processor consisting of a datapath (arithmetic logic unit plus data registers) and a control unit (FSM). In this way, this project is a recompilation of many previously designed components and structures.

In the second part, the significant concept of simulating a VHDL testbench is presented. This is the professional alternative to TCL macro or Proteus EasyHDL scripting which where used in previous exercises.

The same or a similar project can be implemented alternatively using microcontrollers in Chapter 4.

1.4 Topics The following topics have been listed from the course’s specific and cross-curricular learning objectives 1: #10, #11, #12. After studying Chapter 2 and successfully completing all the assignments in this task, you will be able to:

------------- Part 1 -------------

1. Explain the concept of a datapath consisting of an ALU and registers for the operands and results.

2. Explain the concept of “flags” or operation indicators and list the most common flags.

3. Explain the concept of control unit based in the application of a FSM.

4. Plan a frequency meter conditioned for heart rate metering.

------------- Part 2 -------------

5. Implement the project using a structure of components and signals.

6. Use a VHDL testbench entity to automate the simulation process (assert and report).

1.5 Block diagram a) Study examples and gather information about digital heart rate meters or frequency meters. Deduce or

propose a set of specifications for your instrument. For instance, in Fig. 1 there is the photograph of a commercial device used by runners for training. Heart rate is the measurement of the work your heart does expressed in the number of beats per minute (bpm or b/min). Study the schematic in Fig. 2. The idea is that a block diagram for a heart rate meter can be deduced from a frequency meter.

1 http://epsc.upc.edu/projectes/ed/E1/units/Guia_docent_E1_v2.pdf

4

EX3: Designing a dedicated processor

Fig. 1 Example of a commercial device used by athletes (http://www.polarusa.com) to measure and monitor speed, distance and heart rate

Fig. 2 An example of a frequency meter block diagram (from Problem 2.1 in http://epsc.upc.edu/projectes/sed/ED/problemes/Problemes_PA_06_07_Q1.pdf

b) Invent a block diagram for your project which shows a top internal architecture based on a dedicated processor. See Fig. 3.

5

EPSC – E1: Electronics I

Fig. 3 An advanced digital system consisting in the combination of a datapath and a control unit.

1.6 Project implementation

1.6.1 Divide project into smaller units

c) Assign each cooperative group member a given section of the project and start designing in parallel. Every section has to be simulated and verified before using them as a component in a top architecture.

1.6.2 Build the top architecture

d) Assemble all the components into the top architecture and complete the project.

1.6.3 Prototype the project into the training board

e) Prototype the project into de UP2 board, verify the way it works.

f) Calibrate your instrument applying using the signal generator.

g) Design the analogue section so that real electrodes or sensors can be conditioned to obtain the instrument’s input digital signals.

1.7 VHDL testbench

1.7.1 Testbench for a simple entity

h) Study the testbench entity and implement a testbench simulation of a small component from the project. For example, a 4-bit counter. Compare and discuss the solution with the one obtained using TCL macros.

6

EX3: Designing a dedicated processor

1.7.2 Testbench for the heart rate meter

i) Generate the testbench entity to simulate the whole project.

1.8 A list of projects of similar complexity- A speed and distance meter for a bike

- A 16-bit binary sequential multiplier (add-and-shift algorithm)

- A tachometer or speed meter for a motor

- A serial transmitter/receiver (an UART peripheral)

- A programmable timer/counter

- A PWM generator

- Real time clock or chronometers

Do not modify the text from page 3 to page 5

7

EPSC – E1: Electronics I

1.9 Problem solution (títol 2)1.9.1 Part 1 (títol 3)

Part 1.1 (títol 4)

És necessari que seguiu aquestes indicacions per qualsevol dels vostres documents en aquesta assignatura. Aprendre-les forma part de la competència de comunicació escrita. Adapteu els vostres documents al format subministrat per aquesta plantilla.

Si alguna indicació o format no l’acabeu d’entendre bé, pregunteu-nos-ho o aclariu els dubtes, però no lliureu mai res que no compleixi aquestes indicacions perquè no us ho corregirem i perdreu el temps.

Afegiu aquí el vostre text (estil normal) encapçalat amb títols (Títol 2 i 3 i 4), amb figures (estil “llegenda” o “epígrafe”) i referències creuades en el text com aquesta Fig. 4 (és una referència creuada a la llegenda, veureu que surt en color gris quan la cliqueu) a les figures que inseriu. Fixeu-vos que la primera vegada que obrireu aquest document en Word 2007, no us sortirà aquesta llegenda “Fig.”, així que haureu de crear-ne una, i després, encara que la esborreu,ja us quedarà la referència. Veureu també que la numeració de les figures és un paràmetre automàtic. Si seleccioneu tot el document, i premeu “F9” actualitzareu tota la numeració.

També l’índex de la pag. 2 és completament automàtic. Es genera sol ( a partir de referències, índex de continguts, Inseriu un índex de continguts) i s’actualitza sol a partir també de “F9” havent seleccionat tot el text de document. És possible que la primera vegada que l’actualitzeu desaparegui. No passa res, simplement cal tornar-lo a generar a partir del menú referències i taula de contingut.

Fixeu-vos en la Fig. 4. Les imatges han d’estar centrades i alineades amb el text. Si voleu posar un parell d’imatges a la mateixa línia, inseriu primer una taula d’un parell de columnes i tot seguit feu invisibles les vores. El millor que podeu fer és “cut & paste” de la pròpia taula que veieu, i, canviar les figures per les vostres.

Feu referència també en el text a les fonts bibliogràfiques o de web que consulteu d’aquesta manera [1] (és una referència creuada a l’element numerat [1]). Expliqueu perquè les heu consultat i quina informació útil heu trobat.

Per corregir la primera versió del vostre treball, no imprimiu ni lliureu des de les pàgines 3 a la 5. És l’enunciat del problema. Sols cal que imprimiu les 2 primeres pàgines que contenen els detalls personals, el resum i l’índex, i a partir d’aquesta mateixa pàgina 6. Però feu-ho amb la numeració correcta. És a dir, treballeu sempre sobre aquest document, i en tot cas, importeu altres textos que tingueu cap a aquest mateix document i formateu-los correctament.

Insistim sobre això mateix: treballeu sempre sobre aquest mateix fitxer per preparar la vostra solució. Així usareu tots els estils i formats que ja té predefinits aquest document.

8

EX3: Designing a dedicated processor

Fig. 4 Exemple de peu de figura que segueix la numeració de l’enunciat (llegenda).

Heu d’instal·lar els correctors ortogràfics en català, espanyol i anglès en el vostre paquet d’eines office. I sobretot, corregir qualsevol error mentre escriviu. Si treballeu això estalviareu molta feina als vostres companys i instructors.

1.10 References Modify or add new references to this section. Follow the same format.

[1] http://epsc.upc.edu/projectes/ed/ . Comment: Course wed page where to find a lot of resources for the course. Specially, materials from previous editions. Read the section on theory about digital systems. [visited 12/2009]

[2] Brown,S., Vranesic, Z., “Fundamentals of digital logic with VHDL design”, McGraw-Hill, 2005. Comment: Figure 1. 7 contains an example of design flow for logic circuits and Figure 2.29 the structure of a typical CAD/EDA system.

[3] An image to define a concept map: http://redie.uabc.mx/contenido/vol2no1/art-11-eng/contenido-ruiz-figura1.png

9

EPSC – E1: Electronics I

1.11 Study plan to solve the exercise

Establish a study plan, a task distribution scheme and other requirements to succeed in producing a good solution when working cooperatively: flux diagrams, concept maps, schematics, tables, pictures, etc.

(This section is mandatory. It must be filled in order to get a mark.)

10

EX3: Designing a dedicated processor

1.12 Topics and activities checklist

Topics Activities

Group member in

charge Comments

1 2 3

1. The architecture of a dedicated processor

2. The concept of a datapath

3. The concept of a control unit

4. Diagram of a frequency meter

5. Block diagram for a heart rate meter and specifications

6.

7.

8.

9.

10.

11.

12.

13.

1.13 Grading grid Here you are the way the exercise could be grades.

Part 1

Design and simulation

Part 1

Implementation and laboratory

Part 2

Testbench for a single component

Part 2

Testbench for the whole project

Total

Scores 2p 5p 2p 1p

Self-assessment

11

EPSC – E1: Electronics I

Instructor’s grades

1.14 Questions in solving EX22

Write here your questions, comments, doubts, opinions, etc. ...

2 Add more sheets if necessary to report your progress or comments though the exercise.

Aquests fulls de dubtes i d’explicació de com heu anat fent l’exercici són obligatoris. Si no és present, no es corregeix l’exercici i s’ha de tornar a lliurar. Abans de corregir i posar-vos qualificacions volem saber quin ha estat procés en què heu dissenyat els circuits i comparar-lo amb les nostres pròpies observacions de classe.

12