Below is a preview of our week-by-week plan for the entire quarter. There may be slight adjustments and rearrangements as we go. The schedule for the final project is set and will not change.

In the readings below, K&R refers to Kernighan and Ritchie’s classic text The C Programming Language (accessible via Stanford’s subscription to Safari Books Online). Nick Parlante’s EssentialC is another great C reference. Please do the recommended readings before lecture for best effect!

Date Topics/Readings
Week 1
Mon 1/7
Introduction and Welcome ( slides )
Lab/assign No lab in first week Assignment 0: Choose Lab Section, Learn Git ( writeup )
Fri 1/11
ARM processor and architecture ( slides , code )
Week 2
Mon 1/14
ARM assembly and machine code ( slides , code )
Lab/assign Lab 1: Setup your Raspberry Pi ( writeup )

Please do the Lab 1 prelab preparation before coming to lab.

Assignment 1: Implement a Larson Scanner ( writeup )
Fri 1/18
From Assembly to C ( slides , code )
  • Review ARM manual section A3.2 and 3.3 on conditional execution and branch instructions
  • Brush up on C basics (syntax, data types, operators, control structures, function calls) via your favorite C reference; sections 1-2 of Nick Parlante’s EssentialC; or chapters 1, 2, and 3 of K&R. Skip content on I/O and standard libraries (we are bare metal!)
  • Read Dennis Ritchie’s account of the history of C.
  • Link to Compiler Explorer demoed in lecture
Week 3
Mon 1/21
C Pointers and Arrays ( slides , code )
  • Note: Monday is a university holiday. Julie will cover key content in a makeup lecture so we can keep on schedule. Please come Monday evening 7pm in Gates B12 if you are willing/able (or watch screencast once posted).
  • Before lecture, read EssentialC chapters 3 (skip material on structures) and 6 (skip material on the heap and memory management) or K&R 5.1-5.4. C-strings are primitive compared to Java/C++ strings; take note of the manual effort required to use and pitfalls to avoid.
  • The screencast of Monday’s night session.
Lab/assign Lab 2: Below C Level ( writeup )

Prelab to prep before lab.

Assignment 2: Implement a Clock
Fri 1/25
C Functions ()
  • Read up on C functions (Chapter 4 in K&R, or Section 4 in Essential C).
  • Read Thinking Geek’s explanation of the mechanics of local variables and stack frames.
Week 4
Mon 1/28
Communication and the Serial Protocol
Lab/assign Lab 3: Debugging and Testing Assignment 3: Implement a String Formatting Library
Fri 2/1
Modules, Libraries, and Linking
Week 5
Mon 2/4
Memory Management
Lab/assign Lab 4: Linked and Loaded Assignment 4: Backtrace and Malloc
Fri 2/8
C Mastery
Week 6
Mon 2/11
Keyboards and the PS/2 Protocol
Lab/assign Lab 5: Keyboard Surfin Assignment 5: Keyboard and Simple Shell
Fri 2/15
Graphics and the framebuffer
Week 7
Mon 2/18
President's Day Holiday
Lab/assign Lab 6: Drawing into the Framebuffer Assignment 6: Graphics Library and Console
Fri 2/22
Week 8
Mon 2/25
Interrupts, cont'd
Lab/assign Lab 7: Raspberry Pi, Interrupted Assignment 7: System Monitor with Interrupts
Fri 3/1
Week 9
Mon 3/4
Project topic TBA
Lab/assign Project Lab 1: What is Your Project? Final Project
Fri 3/8
Week 10
Mon 3/11
Lab/assign Project Lab 2: How Are You Doing?
Fri 3/15
Free day (Payback for MLK)
Week 11
Final projects due Fri 3/22