Microcontroller System Design


EE 347


Fall 2005

Announcements:

1. Meet in Crothers 351 on Monday November 7

2. Directions to install the gcc compiler at home are still here


Instructor Dr. Robert S. Fourney
Email Robert.Fourney@sdstate.edu
Phone 688-4016
Office 215 Harding Hall
Class Time MWF 2:00-2:50
Class Location Crothers Engineering Hall, room 351
Office hours TBD (with your input) by the first full week of class
Text MC68HC11:An Introduction, Software and Hardware Interfacing, 2nd Ed. by Han-Way Huang, published by Delmar Thompson Learning

The text will be supplemented with additional reference materials which will be linked from this page and/or handed out in class as they are assigned.



Prerequisites
EE 245 (formerly known as EE 345)
Corequisites
EE 347L -- Microcontroller System Design Lab
Course Description
This course serves as an introduction to microcontrollers, using the MC68HC11 as an example.
Course Work

Unless otherwise specified, all work that you submit in this course must be your own; unauthorized collaboration is considered academic dishonesty. Please save us both a lot of trouble by realizing that I will pursue any such transgressions to the fullest extent possible.

As a rule, late assigments are not generally accepted (e.g., attempting to hand in an assigment after the start of class on the due date will result in a grade of 0 for that assignment).

Late assignments will only be accepted under exceptional circumstances AND with prior arrangement. A penalty may apply.

Grading Policy
 Final grades will be determined via the following breakdown:

 
Exam #1 20%
Exam #2 20%
Homework and Quizzes 10%
Class Participation (and quizzes) 5%
Design Lab Practical(s) 10%
Lab Project and PDR 15%
Comprehensive Final Exam 20%

Your class participation grade will be determined by your on time attendance to class as well as your participation in classroom discussions. Pop quizzes, when given, will cover material previously covered in class, previous homework assignments, and/or simple questions on the current days reading assignment.
 

Please read Making the Grade by Kurt Wiesenfeld and keep his views (which I share) in mind when deciding how much effort to invest in your coursework.

Schedule of Upcoming Classes
No. Date Topic, Reading, and Assignment
1 Aug 31 Introduction

Discuss Syllabus

Read Chapter 1

Homework # 1 assigned.

2 Sep 2 CPU Registers, machine code, source code, assembly vs higher level language

Through Section 1.5

Read section 1.6 again

Sep 5 No Class -- Labor Day Holiday
3 Sep 7 Addressing Modes Section 1.6
4 Sep 9 Sample instructions, hand assembly, program tracing
Through Section 1.8.1

Homework # 2 assigned. Due on Monday, September 12

5 Sep 12 Cycle-by-cycle analysis, Dis-assembly using opcode maps,
Sections 1.8.2-1.9, 2.0-2.4 (plus some bonus material not found in your textbook)

Homework 2 due before class

Homework # 3 assigned. Due on Wednesday, September 14

6 Sep 14 Flowcharts, Arithmetic

Read sections 2.5 and 2.6 (except 2.6.5 and FDIV) through the bottom of page 59 (skip top of page 60 to start of 2.7
re-read example 2.10

Homework # 3 due before class

7 Sep 16 Double precision multiplication, Sim68 demo and discussion, relative addressing and the BRA instruction

Homework # 4 assigned. Due on Monday

8 Sep 19 Conditional Branching (based on the CCR), loops, shift and rotate instructions, and delay loops.
Sections 1.6.6 and 2.7-2.9
9 Sep 21 Finish with delay loops, introduce the stack Push and pull operations, subroutine calls
Through section 2.9, skipping (for now) 2.7.5. Skim 2.10, concentrating on the parts that are relevant to the axiom Eval boards.
10 Sep 23 More on subroutines, parameter passing, reentrant and recursive subroutines, examples

Homework # 5 assigned.

11 Sep 26 Finish with reentrant and recursive subroutines. Long homework discussion, part of HW 5 extended until Wednesday, (and renamed "Homework # 6"
12 Sep 28 Interrupts, maskability, priority, "interrupt vector", "stacking registers",

Homework # 7 assigned, Due on Friday
Homework # 8 assigned, Due very early on next Thursday Also see the Calling program (snippet) for Homework # 8

13 Sep 30 Discuss/demo tpm subroutine using stack for parameter passing and local variables
More on Interrupts (Buffalo Monitor JMP table, local and global enables and masks) and Resets. Begin discussing memory address decoding.

Test will include all aspects of subroutines, but not of specific interrupts. Register stacking and basic interrupt information is fair game

14 Oct 3 Finish with memory address decoding example. Begin discussion of I/O

Homework # 9 re-assigned. Now due on Friday after the exam

Details on specific types of interrupts will not be on the test, but you should read ALL of chapter 6 (Interrupts and Resets) while this material is still fresh. Various interrupt details will be featured in labs and on future exams.

Oct 3 Optional Evening Review Session at 5:00 pm, in CEH 324
Please bring questions, this is not a lecture
15 Oct 5 Exam # 1
16 Oct 7 More on I/O

Homework 9 Due

Oct 10 No Class. Native American Day Holiday
17 Oct 12 Parallel I/O. Strobed and handshaking, general discussion
Test handed back,

Homework # 10 assigned for Friday

18 Oct 14 Interfacing a Centronics (style) printer to the 68HC11 using the built in subsystem. Detailed example.

Homework # 11 assigned for Monday.

Also, by Saturday, one member of each project team needs to email me explaining how ready they are for a "project day". If everybody is ready to get started (enough parts in hand to keep busy and productive for 3 hours), we can work on projects in lab next week. Otherwise we'll do a lab on hardware interrupts.

CC your project partner on the email so that I can respond to both of you easily.

19 Oct 17 Handshaking example, using MC68HC11 to implement the printer side of Friday's protocol and begin to discuss pulse accumlator subsystem.
20 Oct 19 Finish with Pulse accumulator, discuss on-chip Analog-to-digital converter.
21 Oct 21 Timer Functions (Free running main timer, TIC/TOC functions, Real time interrupts (Chapter 8-8.9)
22 Oct 24 Timer Functions (Free running main timer, TIC/TOC functions, Real time interrupts (Chapter 8-8.9)

Homework # 12 assigned for Wednesday.

23 Oct 26 Timing Diagrams, review general conventions Memory timing requirements in general: set-up and hold times Detailed timing analysis of 68HC11 (Section 5.7)

Preliminary Design Document for your project is due on Monday.

24 Oct 28 MC 68HC11 Bus Timing Diagrams. Memory timing diagrams. Interfacing memory to the MC 68HC11

Homework 13 Due Monday

Preliminary Design Document deadline postponed until Wednesday

25 Oct 31 Go over Homework 13 in excruciating detail.

Homework 14 Due Wednesday.

26 Nov 2 On Chip EEPROM
27 Nov 4 Finish with on chip EEPROM, begin to discuss asynchronous serial communication (leading up to SCI subsystem on 68HC11) Chapter 9

Homework 15 Due Monday.

28 Nov 7 Meet in Crothers 351
Continue with asynchronous serial communication and the SCI subsystem
Nov 7 Optional Evening Review Session in Solberg 128 I've got the room from 5-7 pm, I'll plan on starting at 5 unless we decide to compromise to reduce the two known scheduling conflicts (5:30?)

This is not a lecture, bring questions.

29 Nov 9 Second Exam
Nov 11 No Class -- Veteran's Day
30 Nov 14 Hand back and discuss test
31 Nov 16 More on the SCI subsystem
32 Nov 18 More SCI subsystem
33 Nov 21 SCI subsystem examples and timing analysis
Nov 23 No class -- payback for extra time spent in lab last week.
Nov 25 No class -- day after Thanksgiving
Nov 28 No class due to anticipated blizzard
34 Nov 30 Meet in Crothers 351 to discuss synchronous serial communication and the SPI subsystem (Chapter 10).
35 Dec 2 Meet in Harding 319. Bring a soft-copy of your second-meter program. We'll discuss storing code into the on-chip and On-board EEPROM, configuring the Axiom boards to start running code in EEPROM, and how to write to the on-chip EEPROM under program control.
36 Dec 5 Meet in Harding 319. Bring a soft-copy of the current revision of your second-meter program.

In addition to demonstrating your second-meter (how to write to the on-chip EEPROM under program control), we will discuss storing code into the on-chip and On-board EEPROM, and configuring the Axiom boards to start running code in EEPROM.

You will want to make use of this program.

37 Dec 7 Meet in Crothers 351 to discuss selecting a micro-controller for your Senior Design project and, later on, in "real life". No reading assignment.
38 Dec 9 Meet in Harding 319 to discuss/demonstrate loading your program to and running your program from the on-chip EEPROM and the on-board EEPROM. You will want to make use of this program.

Final Project Report Due . If you do not bring it to class, you must arrange to put it in my hands by the time I go home on Friday.

Dec 12 Optional Review Session at 4 pm in Crothers 351.
Dec 13 Final exam -- 2 pm -- Crothers 351 (Tuesday, Dec 13)