CMPE 401 - Computer Interfacing

Department of Electrical and Computer Engineering

University of Alberta


Announcements:


Note that the following email addresses are in the ece.ualberta.ca domain.

Instructor:
Dr. Gabriel Jarillo;
Office: W2-051
E-mail: gabrielj
Website: gabrielj
Office Hours: Wednesday 11 - 12:30 or by appointment via email.

Lab Instructor:
Nancy Minderman;
Office: ETLC E3-012;
E-mail: nem
Consultation hours will be in the lab and will be 1 P.M - 2 P.M. on Tuesday, Wednesday, and Thursday.

Electrical Stores Technician:
Rick McGregor;
Office: ETLC E3-012;
E-mail: rmcgreg
Office Hours: 8 A.M. - Noon and 1 P.M. to 4 P.M.

Lab TAs
Note that David's email address is in the ualberta.ca domain
David Kastelan
E-mail: drk

Note that Anish's email address is in the ece.ualberta.ca domain
Anish Kumar
E-mail: akumar

Lab Report Marker
Note that Yifan's email address is in the liyifan.com domain
Yifan Li
E-mail: liyifan

Lecture and Laboratory Sections:

Lec A1: Reg. No. 90548; Mondays, Wednesdays and Fridays 10:00 to 10:50 in ETLE2 002
Lab D1: Reg. No. 90549; Tuesdays 14:00 to 16:50 in ETLE5 002
Lab D2: Reg. No. 99213; Wednesdays 14:00 to 16:50 in ETLE5 002
Lab D3: Reg. No. 92815; Thursdays 14:00 to 16:50 in ETLE5 002
Note: registering in one of the three laboratory sections will cause automatic registration in the one lecture section.

Calendar Course Description:

(either term, 3-0-3/2). The design and use of digital interfaces, including memory, serial, parallel, synchronous and asynchronous interfaces. Hardware implementations of interrupts, buses, input/output devices. Prerequisite: EE 380 or CMPUT 229.

Required Textbook:
Either of the following books will be useful references in the course. These texts were required for EE380 and can be used for this course as well.

Thomas L. Harman, The Motorola MC68332 Microcontroller: Program Design, Assembly Language Programming, and Interfacing, (Prentice Hall, 1991, ISBN 0-13-603127-7).
or
Alan Clements, 68000 Family Assembly Language-W/3"Disk, (ITP Nelson, ISBN 0534932754).

Evaluation Scheme:

Midterm examination: 30% (Date: Wednesday October 24th 50 minutes in the classroom starting promptly at 10:00)
Final examination: 40% (Date and Location: TBD)
Assignments (~5) and Quizzes(~2): 10%
Laboratory Exercises: 20%
Note: Students will work in teams of two in the laboratory.

Official Course Outline:

click here The order and relative emphasis of the topics may vary in the actual course.

Detailed Topic Sequence: (Order and topics subject to change)

Review of the 68332 microcontroller: registers, instructions, addressing modes, the user & supervisor modes, interrupt handling
Embedded system software architecture: operating systems, real-time kernels, device drivers, MicroC/OS-II
The RS-232 serial interface, the 68681 Dual Asynchronous Receiver Transmitter (DUART) Interface Chip
Network interfaces: the OSI layered model, UDP/IP, TCP/IP, client-server interaction, the socket API, the lwIP stack
Digital-to-analog and analog-to-digital conversion
Interfacing to sensors, actuators, stepper motors, servos, the Motorola Time Processor Unit (TPU)
The 68000 System Bus: read cycles, write cycles, read-modify-write cycles, IACK cycles, direct memory access (DMA)
High-speed digital signals, transission lines, termination methods
Survey of Other Illustrative Serial Interfaces: RS-422, Ethernet, SCI, USB, Firewire
Survey of Microcomputer Interfaces: memory interfaces, Intel microprocessor buses, ISA, EISA, PCI, cPCI, Rambus
Survey of Other Illustrative Parallel Interfaces: IEEE-1284 printer port, IEEE-488 instrument bus, Unibus

Assignments:

Assignment #1 Solution to assignment #1

Assignment #2 Solution to assignment #2

Assignment #3 Solution to assignment #3

Assignment #4 Solution to assignment #4

Assignment #5 Solution to assignment #5

Quiz Solutions:

Solutions for Quiz #1

Solutions for Quiz #1

Midterm Solutions:

Solutions for the midterm

Laboratory Exercises (Tentative Schedule):
Lab Date(s) Demo Due Date Report Due Date
Topic Lab D1 Lab D2 Lab D3 Lab D1 Lab D2 Lab D3 Lab D1 Lab D2 Lab D3
Lab #1 Introduction to uC/OS-II on a 68332-based Microcomputer
(reports marked by Yifan)
Sept. 25 Sept. 26 Sept. 27 Oct. 9 Oct. 10 Oct. 11 Oct. 10 Oct. 11 Oct. 12
Lab #2 Serial Interfacing Using the 68681 DUART
(reports marked by Yifan)
Oct. 9
Oct. 23
Oct. 10
Oct. 24
Oct. 11
Oct. 25
Nov. 6 Nov. 7 Nov. 8 Nov. 7 Nov. 8 Nov. 9
Lab #3 Serial Interfacing Over SLIP to a TCP/IP Stack in an Embedded System
(reports marked by Yifan)
Nov. 6 Nov. 7 Nov. 8 Nov. 26* Nov. 26* Nov. 26* Nov. 27* Nov. 27* Nov. 27*
Lab #4 Stepper Motor Control Using the Motorola Time Processor Unit (TPU)
(reports marked by Yifan)
Nov. 20 Nov. 21 Nov. 22 Dec. 3^ Dec. 4^ Dec. 5^ Dec. 3^ Dec. 4^ Dec. 5^

Notes on the Schedule:

^ Demo due dates and lab report dates coincide for lab #4 only and are the result of University regulations that specify that all term work must be completed by the last day of classes.

* Demo dates for lab #3 have been changed.

Laboratory Documentation:

Lab Download and Setup Instructions
A List of Useful MicroC/OS-II Functions
Datasheets for the New Micros NMIX-0332-OEM 68332-based Microcomputer
Schematics for the New Micros NMIX-0332-OEM 68332-based Microcomputer
An Introduction to the MC68331 and MC68332 (56-page tutorial)
MC68332 User's Manual (265 pages)
CPU32 Reference Manual (330 pages)
MC68HC681 DUART User's Manual (88 pages)
TPU Reference Manual (142 pages)
Lab libc documentation
Makefile Tutorial


Code of Student Behaviour:

It is the student's responsibility to be familiar with, and to adhere to, the terms of the University of Alberta's Code of Student Behaviour. Included in the Code are descriptions of unacceptable behaviour for students attending the University, the sanctions for the commission of academic offences, and explanations of the complete discipline and appeal procedures. In particular, please note the definitions of plagiarism in section 30.3.2(1), of cheating in section 30.3.2(2), of misrepresentation of facts in section 30.3.6(4), and of participation in an offence in section 30.3.6(5). For example, cheating includes the submitting of the words, ideas, images, or data (including computer programs) of another person as the student's own in any academic writing, essay, thesis, research project or assignment in a course or program of study. Penalties for academic offences range from a written reprimand up to expulsion from the University.


Supplementary Reference Materials:

Please do not feel obligated to buy copies of any of these books. They are not required for the course, but you might find some of these titles useful to supplement the lecture and laboratory material. Limited numbers of the book on MicroC/OS-II by Jean Labrosse are available in the University bookstore. This book would be a useful reference for the laboratory exercises, and might be useful later on for project courses.

  1. Don Anderson and Dave Dzatko, Universal Serial Bus System Architecture, 2nd ed., (Addison Wesley, 2001), ISBN 0-201-30975-0.
  2. Behrouz A. Forouzan, TCP/IP Protocol Suite, (McGraw-Hill, 2003), ISBN 0-07-119962-4.
  3. Jean J. Labrosse, MicroC/OS-II - The Real-Time Kernel, 2nd ed., (CMP Books, 2002), ISBN 1-57820-103-9.
    A copy of this book has been placed on reserve in Cameron library.
  4. Jane W. S. Liu, Real-Time Systems (Prentice Hall, 2000), ISBN 0-13099651-3.
  5. Hans-Peter Messmer, The Indispensable PC Hardware Book, 4th ed., (Addison Wesley, 2001), ISBN 0-201-59616-4.
  6. Tom Shanley and Don Anderson, PCI System Architecture, 4th ed., (Addison Wesley, 1999), ISBN 0-201-30974-2.
  7. David E. Simon, An Embedded Software Primer , (Addison Wesley, 1999), ISBN 0-201-61569-X.

Useful WWW Links:

Overview of Motorola's 32-bit Microcontroller Families
Motorola MC68340 User's Manual
Home page of Micrium Inc., the distributor of MicroC/OS-II
TCP/IP Tutorial and Technical Overview
Homepage of the Lightweight TCP/IP (lwIP) Project
Homepage of the uIP project, for small 8 and 16-bit microcomputers
Sockets Tutorial
GPIB Tutorial
A Tutorial Introduction to HPIB


Last Modified October 31, 2007