ARM project (De1, 14)

University of Cambridge, Department of Engineering
Easter Term 2002

Project leader: Frank Stajano
Demonstrators: Panit Watcharawitch, Tom Kelly

This project is based on the ECAD and Architecture workshops designed and lectured by Dr Simon Moore at the Computer Laboratory of the University of Cambridge. Simon's cooperation has been invaluable and is very gratefully acknowledged.


ARM project home | Tasks (weeks): 1 | 2 | 3 | 4

Introduction

This 4-week project sits at the boundary between hardware and software. You will be designing hardware circuits and programming a RISC processor. More specifically, you will build circuits by programming an Altera FPGA in Verilog (a hardware description language), and you will connect those circuits to an ARM 7 processor that you will program in ARM assembly language.

The goal of the project is to build a mouse interface for the ARM and write a rudimentary device driver allowing the ARM to read out the absolute 2D position of the mouse.

Deliverables

In each of the four weeks of the project there is an assigned task which requires you to program the FPGA, the processor or both. These four subtasks build on each other.
  1. Electronic Die in Verilog
  2. String sort in ARM assembler
  3. Mouse interface in Verilog
  4. Reading the mouse from the ARM

By the last session of every week you must produce a mini-report and give a live demonstration of your running hardware to one of the demonstrators. The mini-report is much shorter than the usual "interim reports" of most other projects and contains practically no prose. It consists of your commented ARM/Verilog code plus brief answers to a couple of questions on that week's task. You must give your demo and hand in your mini-report by the last timetabled session of each week (Thursdays 11:00-13:00). This is a serious deadline that nobody should miss: the penalty for late demos/mini-reports is 3 marks per weekday (Mon-Fri), which means you'd waste at least 6 marks since there is no session on Fri. It is of course acceptable and laudable to submit a mini-report ahead of time at some earlier session, although there are no bonus marks for this.

To submit a mini-report:

By 17:00 on Friday 7th June (last day of week 4, but not a timetabled session) you must hand in (to the Teaching Office) a final report of not more than 10 pages. See the bottom of the page for week 4 for advice on how to structure it. You will append copies of your 4 mini-reports to it. This is an even more serious deadline and no extension can be permitted.

Marking

Each mini-report is worth up to 15 marks, for a subtotal of 60 marks. The criteria that will be used for assessment are the following, of which the first will carry the most credit.

A further 20 marks are awarded at the end of the project. The final report (worth up to 15 marks) will be assessed on the following criteria.

The remaining 5 marks will be awarded based on a live demonstration of a working solution for the whole project. Note that this is the same as the week 4 demo; you won't have to give it twice, it will just count more than the others in the final score.

The total for the whole project is therefore 80 marks.

Note that this is not a team project and all work must be carried out individually.

Bonus Track (new)

Given your feedback about the pace being a little slow, but given also the extremely wide variance in completion times for the week 1 task, I hereby introduce this optional bonus track for those of you who can complete the standard tasks in much less time than allocated, but find little incentive to carry out additional work unless it's marked. Note in passing that, if week 1 is any indication, completing a weekly task as soon as possible doesn't usually yield the highest marks. It is advisable to complete the 4 tasks of the standard track with elegance and style before devoting time to the bonus track.

The main deliverable for the bonus track is a ps2 keyboard interface, with interrupt-based (this is a requirement too) device driver, attached to the "string sort" program of week 2. The user must be able to enter the input strings on a keyboard attached to the Altera board, and these should be sorted and printed on the console of the ARM debugger.

Unlike with the standard tasks, there will be no handholding. You will have to find out about the ps2 keyboard protocol by yourself (web search, library search, reverse engineering, whatever) and all the design choices will be your own. See the bottom of ECAD workshop 6 for hints on interrupt-driven device drivers.

There are two auxiliary deliverables: implement the 2-second delay line mentioned at the bottom of the page for week 1, and the prime number program from ECAD workshop 4. You have to show these to a demonstrator, but you must not submit the corresponding code.

If you choose the bonus track, the rules for marking change as follows. Firstly, you must submit all 4 weekly mini-reports and show a running solution to the two auxiliary deliverables. Until you do this, your bonus track deliverable won't be looked at (let alone marked). Having done this, you must show a running solution for the main deliverable (the ps2 keyboard feeding the string sort program), write a report about it (max 2 sides of A4) and include the code as an appendix.

Timetable

This project runs in the Cockroft 4 teaching laboratory on the New Museums Site (follow the links for directions; this is NOT on the Engineering site).

Repeat the following pattern for 4 weeks, starting Monday 2002-05-13.

2h slotMonTueWedThuFriSatSun
09:00-11:00Mandatory
11:00-13:00Mandatory
13:00-15:00MandatoryNOT AVAILABLE
15:00-17:00MandatoryNOT AVAILABLE

"Mandatory" means it's a timetabled session for this project. You have to be there at those times or you will be penalized at the rate of 1 mark per hour missed. I will use about 4 of these 8 hours, depending on the week, to introduce you to Verilog and ARM assembler. You will use the rest to program the devices yourself. During these sessions you will each have access to an individual workstation with the appropriately licensed software tools, and you will be issued one teaching board each. Demonstrators will be available to provide guidance and to help you using the tools.

"NOT AVAILABLE" means the room is booked for another course, so you can't be there at those times.

All the other slots are currently free, so you are welcome to go there and use the available facilities when it best suits you. At those unsupervised times, however, only 9 workstations will be equipped with teaching boards; the others will have just the software tools.

Remember that your work for each week is assessed by a demonstrator on the Thursday of that week, so you have no extra time to clean things up afterwards or at the weekend.

Departmental warnings

Useful online references

All in HTML except where marked.

Verilog

ARM assembler

ARM/Altera teaching board

Related lecture course material