TORONTO METROPOLITAN UNIVERSITY

Course Outline (F2023)

BME538: Microprocessor Systems

Instructor(s)Sattar Hussain [Coordinator]
Office: TBA
Phone: TBA
Email: sattar.hussain@torontomu.ca
Office Hours: Wednesdays 7:00pm-8:00pm, online via zoom meetings
Calendar DescriptionThis course introduces students to small microprocessor-based systems, with an emphasis on embedded system hardware and software design as applied to Biomedical Engineering. Topics will include microprocessor architecture and structure, with an overview of 8- 16- and 32-bit systems, assembly language programming and the use of high-level languages. Basic input/output including parallel communications with and without handshaking and serial protocols. Hardware and software timing using interrupts and exceptions. Overview of single-chip microprocessors and controllers with an emphasis on the PIC32 microcontroller. The internal structure and design of peripheral devices are examined; together with memory system design and analysis. Key software design concepts are reinforced through labs/project work; together with the use and structure of development tools such as (cross) assemblers or compilers, monitor programs, simulators, emulators, etc.
PrerequisitesBME 328 and CEN 199
AntirequisitesCOE 538
Corerequisites

None

Compulsory Text(s):
  1. Programming 16-Bit PIC Microcontrollers in C: Learning to Fly the PIC 24, Lucio Di Jasio, 2nd edition, Copyright © 2011 Elsevier Inc. ISBN: 978-1-85617-870-9
  2. Microcontrollers from Assembly Language to C Using the PIC24 Family, Reese, R., Bruce, J.W., and Jones, B.A., 2nd edition, Course Technology PTR, 2014. ISBN 13: 9781305076556, ISBN 10: 1305076559.
  3. Programming 32-Bit Microcontrollers in C: Exploring the PIC32, Lucio Di Jasio, 1st Edition, Newnes, 2008. ISBN: ‎ 978-0750687096
Reference Text(s):
  1. Embedded Computing and Mechatronics with the PIC32 Microcontroller, Kevin Lynch, Nicholas Marchuk, and Matthew Elwin, 1st edition, Newnes, 2015. ISBN: 978-0-12-420165-1
  2. Microcontrollers and Microcomputers Principles of Software and Hardware Engineering, Frederick M Cady, 2nd Edition, Oxford University Press, 2009.
  3. Microchip Developer's Help Center: https://microchipdeveloper.com/16bit:start
  4. Proteus Tutorials Videos-https://www.labcenter.com/tutorials/
  5. Microcontrollers from Assembly Language to C Using the PIC24 Family home page: https://sites.google.com/site/pic24micro/Home/textbook
  6. Embedded Computing and Mechatronics with the PIC32 Microcontroller homepage: http://hades.mech.northwestern.edu/index.php/NU32
Learning Objectives (Indicators)  

At the end of this course, the successful student will be able to:

  1. Demonstrates an understanding of microprocessor systems concepts, microprocessor architecture, I/O interface, peripherals, components, and programming and debugging methodology. Applies scientific approaches, knowledge, and programming skills to analyze, model, and solve a given engineering problem. Understand the role of embedded microprocessors in biomedical applications. (1d)
  2. Use technical knowledge including microprocessor architecture, microprocessor I/O interface, microprocessor peripherals, programming and debugging methodology. Use design tools and related resources including microprocessor, microprocessor peripherals, assemblers, compilers, and hardware debuggers. Apply the programming principles to define an accurate programming problem statement. Recognize that good problem definition assists the program design process. (4a)
  3. Describe differences between the various approaches that can be used to solve a microprocessor programming problem using assembly/C language. Select one specific approach to solve the problem. When the selected approach fails to solve the problem satisfactorily, analyze the cause of failure using standard assembly/C language programming and debugging methodologies. Based on the analysis, come up with new suggestions to improve the existing approach. Integrate the new suggestions into the existing design plan. Judge the completeness and quality of the generated solutions using standard assembly/C language programming and debugging methodologies. (4b)
  4. Describe the iterative process of programming and debugging microprocessor programs using assembly/C language. Using debugging tools to generate information on the current state of an assembly/C language program that can be used to modify and improve the current program solution. Based on the generated information, examine and critique the current program solution to revise the solution as needed. Incorporate and integrate feedback from the teaching assistants and others and generate new knowledge about the programming problem. (4c)
  5. Produce lab and project reports using appropriate format, grammar, and citation styles for technical and non-technical audiences. (7a)
  6. Illustrate concepts including the structure of assembly/C language programs and obtained experimental results. (7c)
  7. Know the role of the biomedical engineer in society. Including responsibility for protecting, specifically, patient safety, and, generally, the broader public interest. (8b)
  8. Describe interactions between biomedical instrumentation system design and economic and environmental factors. (9a)
  9. Describe project outline and its biomedical implementations. Set up a milestone to meet project goals. Determine the project outcomes and deliverable biomedical instruments. Perform risk assessment. (11b)

NOTE:Numbers in parentheses refer to the graduate attributes required by the Canadian Engineering Accreditation Board (CEAB).

Course Organization

3.0 hours of lecture per week for 13 weeks
2.0 hours of lab per week for 12 weeks
0.0 hours of tutorial per week for 12 weeks

Teaching AssistantsSections 1 & 3: Abdelrahman Abdou, abdelrahman.abdou@torontomu.ca
 Sections 2 & 4: Martin Ivanov, martin.ivanov@torontomu.ca  
Course Evaluation
Theory
Midterm Test 25 %
Final Exam 40 %
Laboratory
Laboratory 25 %
Final Project 10 %
TOTAL:100 %

Note: In order for a student to pass a course, a minimum overall course mark of 50% must be obtained. In addition, for courses that have both "Theory and Laboratory" components, the student must pass the Laboratory and Theory portions separately by achieving a minimum of 50% in the combined Laboratory components and 50% in the combined Theory components. Please refer to the "Course Evaluation" section above for details on the Theory and Laboratory components (if applicable).


Examinationsa) Midterm Test will be held on week 7, Tuesday, October 17, 2022, during regular lecture hours. The midterm covers up to the prior week of the midterm exam.  
 b) Final Examination will be held during the final examination period.
 c) Labs are conducted in groups of two students each. Attendance is mandatory for all labs.  
      
 The theory component is assessed via the midterm and Final Exam (65% of the final grade), while the laboratory component is assessed by completing and demonstrating the given lab tasks as well as submitting the lab reports. In the course project, students will design a signal acquisition and processing system based on interfacing a Microprocessor with external sensors/actuators. The laboratory is 25% of the final grade and the course Project is 10%.
Other Evaluation InformationMidterm, makeup test, and Final Examination are closed book exams. Instructions and coverage are to be discussed in the class prior to each test.
 
 Labs begin in the second week of the classes. Students are expected to attend the lab sessions of the section for which they are registered. One lab report is to be submitted per group. Missing a lab session will result in zero marks given to that lab regardless of submitting a lab report.
 All reports, whether for the lab or the final project, are expected to include a standard FEAS cover page. The reports are expected to adhere to IEEE format, including references. The report should justify the design choices, problem definition, methodology, implementation details, and performance analysis. Refer to the marking and style guides provided within each lab document for details on what is required in these reports. More instructions can be found in the lab rules posted in D2L.
Teaching MethodsBME538 lectures and labs are delivered in person. Lectures are at KHE321A & labs are at ENG307. Office hours will be held online via zoom meetings.  
 All course-related communications will be through D2L Brightspace LMS. Lecture notes, lab handouts, and assignments will be made available through D2L course shell. Students are expected to frequently check the course shell for posted announcements and course materials.   
 TMU University requires that any official or formal electronic communications from students be sent from their official TMU E-mail account. As such emails from other addresses may not be responded to.
 
 Prof Sattar Hussain holds the copyright in the works of all original materials used in this course and students registered in this course can use the materials for the purposes of this course but no other use is permitted, and there can be no transfer or use of the work for any other purpose without the explicit permission of Prof Sattar Hussain.
Other InformationNone

Course Content

Week

Hours

Chapters /
Section

Topic, description

1

3

Text 1: CH. 1, 2, & 3 Text 2: CH. 8

General Concepts Internal Architecture
 


2

3

Text 1: CH. 1, 2, & 3 Text 2: CH. 8

Parallel I/O Ports-Interfacing I/O Devices


3

3

Text 1: CH. 5 Text 2: CH. 9

Interrupts and Timers


4

3

Text 1: CH. 5 Text 2: CH. 8

System and Peripheral Clocking Oscillators- Configuration Bits


5

3

Text 1: CH. 12 & 15 Text 2: CH. 11

Output Compare Module Configuration-PWM Applications


6

3

Text 1: CH. 8 Text 2: CH. 10

Asynchronous Serial Communications-UART


7

3

Weeks 1-6

Midterm
 


8

3

Text 1: CH. 7 Text 2: CH. 10

Synchronous Serial Communication-SPI


9

3

Text 1: CH. 7 Text 2: CH. 10

Synchronous Serial Communication-I2c


10

3

Text 1: CH. 10 Text 2: CH. 11

Analog interfacing


11

3

Text 1: CH. 10 Text 2: CH. 11

Analog interfacing-Continued


12

3

Text 1: CH. 12 Text 2: CH. 11

Input Capture
 


13

3

Text 2: CH. 8 & 13

Watchdog Timers-Advanced Interfacing and Programming Topics


Laboratory(L)/Tutorials(T)/Activity(A) Schedule

Week

L/T/A

Description

1

NA

No Lab

2

Lab 0

Installing MPLAB X, Proteus, & Compilers

3

Lab 1

PIC24 Ports Configuration

4

Lab 2

I/O Interfacing   

5

Lab 3

Keypad Interfacing

6

Lab 4

Interrupts & Timers

7

Lab 5

Output Compare-Pulse Width Modulation

8

lab 6

Asynchronous Serial Communications-UART

9

Lab 7

Asynchronous Serial Communications-SPI

10

Lab 8

Analog Interfacing-ADC

11

Lab 9

Input Capture-Temperature Sensor interfacing

12

Project

Final Project

13

Project

Final Project-Cont'd

University Policies

Students are reminded that they are required to adhere to all relevant university policies found in their online course shell in D2L and/or on the Senate website

Important Resources Available at Toronto Metropolitan University

Accessibility

Academic Accommodation Support

Academic Accommodation Support (AAS) is the university's disability services office. AAS works directly with incoming and returning students looking for help with their academic accommodations. AAS works with any student who requires academic accommodation regardless of program or course load.

Academic Accommodations (for students with disabilities) and Academic Consideration (for students faced with extenuating circumstances that can include short-term health issues) are governed by two different university policies. Learn more about Academic Accommodations versus Academic Consideration and how to access each.

Wellbeing Support

At Toronto Metropolitan University, we recognize that things can come up throughout the term that may interfere with a student’s ability to succeed in their coursework. These circumstances are outside of one’s control and can have a serious impact on physical and mental well-being. Seeking help can be a challenge, especially in those times of crisis.

If you are experiencing a mental health crisis, please call 911 and go to the nearest hospital emergency room. You can also access these outside resources at anytime:

If non-crisis support is needed, you can access these campus resources:

We encourage all Toronto Metropolitan University community members to access available resources to ensure support is reachable. You can find more resources available through the Toronto Metropolitan University Mental Health and Wellbeing website.