CMPE 311: C Programming and Embedded Systems
Fall 2022

Course Information

Instructor - Prof. Tinoosh Mohsenin
Lecture: Tuesday, Thursday, 1:00 - 2:15
Discussion: Tuesday, Thursday, 4:00 - 5:15
Office Hours: by appointment

TA : Mohammad Akram
UTA : Kenneth Addo
Grader : Rachit Sood

Lecture


Thanks to previous instructors Alex Nelson, Prof. Robucci and Prof. Hamid Mahmoudi for preparing the original slides and other material for the class.

Date

Notes

Info

9/1/2022 Intro, Syllabus, Syllabus presentation, 310 Review and Chapter 1
9/6/2022 Instruction Set Architecture review , Memory Types, Review and AVR Architecture Review the Atmel datasheet, particularly the architecture details ATMega169P Datasheet,
9/8/2022 instruction types Assignment 1 posted and discussed
9/13/2022 IO Ports and Assembly examples Very helpful notes on AVR operation, Instruction and examples
9/15/2022 m169Pdef.inc AVR Butterfly Board Pin Connections
9/20/2022 AVR CPU Registers
9/20/2022 AVR Addressing Modes, AVR Addressing Modes with exampleS from UNCC, State Machine Example, State Machine Notes For instructions and examples review AVR Command Set
9/22/2022 Assembler Examples More Examples from Bill Smith Macro examples added to slides
9/22/2022 *NEW*UART Write Example *NEW*AVR UART Notes
9/27/2022 Begin C Introduction Quiz 1
9/27/2022 C Introduction Bitwise operation examples from micah carrick, _bv macro typedef uint8_t
9/29/2022 Finish C Introduction
10/4/2022 Functions, Macros, Separate Compilation
10/6/2022 Arrays Quiz 3
10/6/2022 Strings Examples for using String
10/11/2022 Pointers a Pointer example
10/13/2022 Pointers from Reference book-slides Pointers from Reference book
10/18/2022 Structs, Unions and Bitfields Examples for Struct Examples for Union Examples for BitFields
10/20/2022 Advanced Pointers and Dynamic Memory Management *NEW* Example on Dynamic Memory Management
10/25/2022 Important Linkedlist Examples
10/27/2022 *For MidTerm Practice & Code Examples go to the shared Google Drive*
11/1/2022 MidTerm
11/3/2022 Interrupts Atmel DataSheet Section 11 and 12
11/7/2022 Analog To Digital Converters ADC AVR notes, and Atmel DataSheet Section 22
11/10/2022 Timers and Counters Atmel DataSheet Section 14
11/15/2022 Timers and Counters Continued
11/17/2022 HW4 clarification and notes
11/17/2022 Embedded Processing Applications and multicore
11/17/2022 Real-Time Operating Systems Quiz 4
11/17/2022 slides from reference book
11/22/2022 types of parallelism and multicore Quiz 5
11/24/2022 More on types of parallelism and multicore Source: Thread Level Parallelism – SMT and CMP, DR.SHANTHI
12//2022 Review for Final Exam


Discussions


Date

Notes

Info

9/6/2022 & 9/8/2022 CMPE311:Guidelines, Discussion1, LED Blink Assembly Code, Part List, AVR Butterfly Pin Connections, Link to Download Atmel(Microchip) Studio (Free)
9/13/2022 & 9/15/2022 Discussion 2 slides, Discussion2 sample code
9/20/2022 & 9/22/2022 Discussion 3 UART.asm
9/27/2022 & 9/29/2022 Discussion 4 C Example
10/04/2022 & 10/06/2022 Discussion 5 main file for uart test uart.c uart.h
10/11/2022 & 10/13/2022 Discussion 6 Discussion 6 C Code, LCD Driver.c, LCD Driver.h
10/18/2022 & 10/20/2022 LinkedList.c
10/25/2022 & 10/27/2022 Discussion 7 Interrupt C Code, LCD Driver.c, LCD Driver.h
11/1/2022 & 11/3/2022 Discussion 8 Timer C Code
11/8/2022 & 11/10/2022 Discussion 9 ADC C Code, ADC Tutorial Extra


Projects

All Projects will be assigned through Blackboard, please check your Blackboard.

Date Assigned

Date Due

Project Link

Reading References

09/04/2022 Part 1 - 9/11/2022
Part 2: 9/18, 11:59 PM No UART, Part 3: 09/25 with UART
Assignment 1 ATMega169 Datasheet, AVR Instructions,Butterfly User Guide to find the register location for joystick and buzzer
09/25/2022 Part 1 - 10/02/2022
Part 2 - 10/09/2022
Assignment 2 Uart.c, Uart.h, Demo Example
10/11/2022 10/23/2022 Assignment 3 input.txt, Demo Example
10/26/2022 11/15/2022 Assignment 4 HW4 part connections


Resources


Type

Links

AVR Assembly Beginner AVR Assembler - AVR Assembler Begginer Guide
AVR Command Set - AVR Assembler Command Set
AVR Assembler Macros Useful Macros, How to use Macros
Subroutines Writing Subroutines
AVR Parts Parts List, JTAG Connection
AVR Butterfly ATMega169P Datasheet, Butterfly User Guide
Valgrind Quick-Start Guide
C Examples MIT OpenCourseWare, AVR C Code Examples