Microcontroller System Design


EE 347


Fall 2006

Announcements:

1. Updated info on what to expect on exam 2.


Instructor Dr. Robert S. Fourney
Email Robert.Fourney@ieee.org
Phone Office: 688-4016 (home number handed out in class)
Office 215 Harding Hall
Class Time MWF 2:00-2:50
Class Location Crothers Engineering Hall, room 351
Office hours MWF 3-4, Tu 12-1
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 and either CSc 218 or CSc 250
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 30 Introduction

Discuss Syllabus

Read Chapter 1

Homework # 1 assigned.

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

We covered through Section 1.5

Look at textbook problems E1.1-1.9 and Read section 1.6 again prior to Wednesday's lecture

Sep 4 No Class, Labor Day
3 Sep 6 Addressing Modes Section 1.6
4 Sep 8 Sample instructions, hand assembly, program tracing
Through Section 1.8.1

Homework # 2 assigned. Due on Monday, Sep 11

Don't forget about the IEEE picnic this evening

5 Sep 11 Arithmetic, multiple precision addition and subtraction

Read chapter 2 through section 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 assigned. Portions due tonight and before lab on Thursday.

Homework # 2 due before class

6 Sep 13 Double precision multiplication, Sim68 demo and discussion, relative addressing and the BRA instruction

Homework # 4 assigned. due on Monday

Note submission instructions!

7 Sep 15 Lenghty C discussion, Flow Charts Branching, conditional branching (based on the CCR)
Sections 1.6.6 and 2.7-2.9

Get started on Homework 4

8 Sep 18 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 4 due today

In order to participate, you should bring your textbook to class today

Homework # 5 assigned. Due on Friday

9 Sep 20 Finish with shift and rotate instructions. Delay loops.
Sections 1.6.6 and 2.7-2.9 Introduce the stack, and the push and pull operations.
Begin to discuss modular programming, subroutines, storage of the return address, and parameter passing.
Chapter 3 through 3.3
10 Sep 22
Subroutine calls, parameter passing, reentrant and recursive subroutines, examples, "Well behaved" subroutines. Sim68 demo/discussion

Homework #6 assigned, due Wednesday.

11 Sep 25 Finish with reentrant and recursive subroutines. Begin to discuss interrupts (maskability, priority, "stacking registers")
12 Sep 27 Finish with Chapter 6: Interrupts and Resets (Buffalo Monitor JMP table, local and global enables and masks, various types of interrupts).

Homework #7 assigned, due Friday.

13 Sep 29 Finish with interrupts (Chapter 6). Discuss lab.

Homework # 8 assigned, Due, via email, before lab on Thursday. Note that the calling program will have to use JSR rather than BSR due to the memory locations that I specified.

Also see the Calling program (snippet) for Homework # 8

14 Oct 2 Parallel I/O: Brute Force, Strobed, and handshaking. general discussion (Read sections 7.4-7.7 and skim 7.7-7.11 for project hints)

Homeworks 9 and 10 due

Oct 2 Optional Evening Review Session at 5:00 pm, in CEH 351. Please be on time, since I have to leave by 6:45.
Please bring questions, this is not a lecture
15 Oct 4 Exam # 1
16 Oct 6 Memory Decoding Section 5.6.2

Homework # 9 assigned for Wednesday

Oct 9 No Class -- Native American Day

Do not forget about the Sencore Symposium on Tuesday. The bus will leave from the area north of Crothers at 8 am. We should be back before 4 pm.

17 Oct 11 Parallel I/O on the MC68HC11 Prior to class you should read sections 7.4-7.7 and skim 7.7-7.11 for project ideas

Homework # 9 Due

Read 7.12 for next time

18 Oct 13 Output handshaking, Centronics printer example. Section 7.12

Homework # 10 assigned for Wednesday.

19 Oct 16 Discuss the built in analog-to-digital (A2D) subsystem, (Chapter 11, skim through 11.4, read 11.5-11.9, and browse 11.10-11.12 for project hints and ideas.)

Homework # 11 assigned for Friday.

20 Oct 18 Finish with example of using built in analog-to-digital (A2D) subsystem, (example 11.7 on page 539),
Discuss using 68HC11 on printer side of printer interface (finish Setion 7.12 now that you've had a chance to look at the other side for homework), and
Discuss the Pulse Accumulator subsystem (Section 8.10--we will discuss the rest of Chapter 8 and all of the other various timer subsystems in about a week).

Homework 10 Due

21 Oct 20 Discuss on chip EEPROM. This is not covered in your textbook and there is no reading assignment prior to class.

Homework # 12 assigned for Monday.

Homework 11 due

22 Oct 23 Meet in Lab (HH 319). Half of us at 2 pm, the rest at 3 pm. Bring a soft copy of your solution to Homework 12

We'll start with this program, before implementing Homework 12.

Homework 12 due by email prior to class

23 Oct 25 Meet in Lab (HH 319). Half of us at 2 pm, the rest at 3 pm. Bring a soft copy of your (possibly revised after Monday) solution to Homework 12

If you made a revision to Homework 12, email it (using our standard procedure and naming convention -- call it hw13) prior to class

If your EEPROM program from Monday is not yet working, you need to demo it at the very beginning of class so as to not lose all of the participation/quiz points for Monday. You need to have the "second meter" working to get today's points.

24 Oct 27 Everybody Meet in Crothers 351 at 2:00 to discuss the timer subsystems. This lecture will cover most of Chapter 8.
25 Oct 30 Everybody Meet in Crothers 351 at 2:00 to finish up the timer subsystems (Chapter 8) and begin talking about asynchronous serial communication (Chapter 9-9.3).
26 Nov 1 Asynchronous Serial Communication.

Baud-rate mismatch homework asigned (from the board) Due Friday

27 Nov 3 Asynchronous Serial Communication -- Specifics of the 68HC11

Baud-rate mismatch homework due

28 Nov 6 More on SCI subsystem. Administrative stuff with lab practicals.
Nov 6 Optional evening review session in CEH 351. 7-9 pm

As usual, you should bring questions as I do not intend to lecture.

29 Nov 8 Exam II
Nov 10 No Class -- Veteran's Day (Observed)

30 Nov 13 Discuss Exam.

Homework # 15 and Homework # 16 and assigned for Wednesday.

Last Day to Withdraw from classes

31 Nov 15 Discuss Lab practical, go over Homework 16
32 Nov 17 In class PAI exercise became HW 17 (due Monday)
33 Nov 20 Discuss PAI assignment (HW 17), discuss SPI subsystem -- Chapter 10-10.5
34 Nov 22 Discuss Timing and interfacing memory to MCU (Section 5.7)

Homework # 18 and Homework # 19 and assigned for Monday

Nov 24 No class -- day after Thanksgiving
35 Nov 27 Meet in Lab (HH 319). Half of us at 2 pm, the rest at 3 pm.

Same Groups as last time Bring a soft copy of your solution to Homework 18

Homework 18 due by email prior to class

36 Nov 29 Meet in CEH 351 to discuss timing.

Looked at 68HC11 Bus timing along with the memory timing, and discussed write cycle timing (sorry, no PPT for that one).

Homework # 20 assigned for Friday

37 Dec 1 Work timing problems
38 Dec 4 Which Micro? Selecting the right microcontroller for the job
39 Dec 6 Current and Future trends in Microcontrollers. How Flash based micro help with time to market and decrease costs, system on a chip. This material is not in your book, but a quick google-search yielded the following three articles which seem to cover the current trends:

Memory options: flash may dominate from EDN (in general, EDN is an excellent resource)

A piece on the evolution of flash microcontrollers, and

a wikipedia article on System on a Chip

40 Dec 8 Final project report due If you do not have it ready by class time, you must make an appointment to put it in my hands sometime on Friday
Monday
Dec 11
Optional Review Session at 4 pm in Crothers 351.
Dec 13 Final exam -- 2 pm -- Crothers 351 (Wednesday, December 13)