Modern Embedded Systems Programming Video Course

This is the companion web-page to the YouTube video course about programming embedded systems the modern way. The course is taught by Quantum Leaps’ Miro Samek.

Here you can find various resources for the course as well as links to all released videos and project downloads.

share on: 

About the Course...

The course consists of focused, fast-paced, hands-on lessons that teach you how to program embedded microcontrollers in C. The course begins with the fundamentals, but gradually covers increasingly advanced concepts all the way to the contemporary modern embedded programming practice.

The course is specifically designed not just to be watched, but to be actively followed along on your own computer (Windows based PC) and a small, self-contained, very inexpensive evaluation board. This companion web-page provides the project downloads that you can open in a specific embedded toolchain and run on your PC at home.

The goal of the course is not just to teach C–other sources do it already quite well. But there are virtually no courses that would step down to the machine level and show you exactly what happens inside a microcontroller.

So, starting from Lesson 1 you will actually see how the ARM Cortex-M processor executes your code, how it manipulates registers, and how an embedded microcontroller can “do” things in the real world, such as turn on and off an LED.

This deeper understanding will allow you to use the C language more efficiently and with greater confidence. You will gain understanding not just what your program does, but also how the C statements translate to machine instructions and get a sense for how fast the processor can execute them. Also, you will get some familiarity with the ARM Cortex-M core, which will look really good on your resume.

The course has been going from January 2013, but it is never too late to join. Stay tuned…

Course Resources

The following list provides links to useful resources about the embedded board and the development toolchains used in the course.

Embedded Board: TivaC LaunchPad

This course is based on the inexpensive and widely available EK-TM4C123GXL board from Texas Instruments, also known under the name TivaC LaunchPad.

The board is based on the TM4C123GH6PM microcontroller (ARM Cortex-M4 CPU). The TM4C123GH6PM Data Sheet in PDF is available for download.

To be able to run the projects provided below, you need to use the exact board. No other board, even if based on the same ARM Cortex-M4 CPU, will allow you to run the projects prepared for the TivaC LaunchPad.

The TivaC LaunchPad board was previously called EK-LM4F120XL "Stellaris LaunchPad" and the first segment of lessons refers to the board by its old name. But the two boards (TivaC LaunchPad and Stellaris LaunchPad) are essentially equivalent and both are equally suitable for this course.

Troubleshooting TivaC LaunchPad

Application Note describing how to fix common problems with TivaC LaunchPad and related software.

LM-FLASH programmer

The LM-FLASH tool can be used to recover an unresponsive TivaC Lauchpad board. Please see the "Troubleshooting TivaC LaunchPad" for details.

Tiva/Stellaris USB Drivers

Tiva/Stellaris USB drivers for Windows.

Tiva/Stellaris In-Circuit ICDI Manual

USB drivers installation instructions.

Tiva™ TM4C123GH6PM Microcontroller Data Sheet

Documentation of the TM4C123GH6PM MCU on the TivaC LauchPad board. This is the most frequently referenced document is the video course.

Tiva TM4C123GXL LaunchPad User Manual

(applies also for Stellaris EK-LM4F120XL LaunchPad)

ARM Cortex™-M4 Users Guide

Describes ARM Cortex-M4 instruction set.

Tiva TM4C123GH6PM header file

(also applies to LM4F120H5QR)

Logic Analyzer: USB Logic Analyzer (8ch, 24MHz)

Some of the lessons in the video course use a logic analyzer to demonstrate various aspects of real-time code execution. One, very inexpensive option, is a clone of the CWAV USBee AX-Pro, but without analog (only 8-channel digital) sampling capabilities. The device is available under various brand names and prices (from $5 to $12):

PulseView Software from sigrok

The generic USB Logic Analyzer works with the open-source PulseView software from sigrok.org, which has version for Windows, Linux and macOS.

Modern Embedded Systems Programming
Videos and Projects

Lesson NumberRunning TimeVideo Title (watch on YouTube)TranscriptToolchainProject DownloadsVideo Download
4815:57#48 Assertions and Design by Contract, Part-2lesson-48.txtARM-KEIL uVisionlesson-48.zip
qpc.zip
qm-windows.exe
video48
4713:35#47 Assertions and Design by Contract, Part-1lesson-47.txtGCC for Desktoplesson-47.zipvideo47
4626:36#46 Software Tracing with QP/Spylesson-46.txtARM-KEIL uVisionlesson-46.zip
qpc.zip
qm-windows.exe
video46
4527:52#45 Software Tracing with printflesson-45.txtARM-KEIL uVisionlesson-45.zip
qpc.zip
qm-windows.exe
video45
4422:32#44 Active Objects in Real-Time Part-2: Mutable Eventslesson-44.txtARM-KEIL uVisionlesson-44.zip
qpc.zip
qm-windows.exe
video44
4314:10#43 Active Objects in Real-Time Part-1: Run-to-Completion and RMS/RMAlesson-43.txtARM-KEIL uVisionlesson-43.zip
qpc.zip
qm-windows.exe
video43
4223:02#42 State Machines Part-8:
Semantics of Hierarchical State Machines
lesson-42.txtARM-KEIL uVisionlesson-42.zip
qpc.zip
qm-windows.exe
video42
4130:56#41 State Machines Part-7:
Automatic Code Generation
lesson-41.txtARM-KEIL uVisionlesson-41.zip
qpc.zip
qm-windows.exe
video41
4031:59#40 State Machines Part-6:
What is a Hierarchical State Machine?
lesson-40.txtARM-KEIL uVisionlesson-40.zip
qpc.zip
qm-windows.exe
video40
3933:09#39 State Machines Part-5:
Optimal Implementation in C
lesson-39.txtARM-KEIL uVisionlesson-39.zip
qpc.zip
qm-windows.exe
video39
3826:36#38 State Machines Part-4:
State Tables and Entry/Exit Actions
lesson-38.txtARM-KEIL uVisionlesson-38.zip
qpc.zip
qm-windows.exe
video38
3731:55#37 State Machines Part-3:
Input-Driven State Machines
lesson-37.txtARM-KEIL uVisionlesson-37.zip
qpc.zip
video37
3614:11#36 State Machines Part-2:
Guard conditions
lesson-36.txtARM-KEIL uVisionlesson-36.zip
qpc.zip
video36
3524:15#35 State Machines Part-1:
What is a state machine?
lesson-35.txtARM-KEIL uVisionlesson-35.zip
qpc.zip
video35
3439:11#34 Event-Driven Programming Part-2:
Best practices for concurrency & Active Object pattern
lesson-34.txtARM-KEIL uVisionlesson-34.zip
qpc.zip
video34
3329:33#33 Event-Driven Programming Part-1:
GUI example, events, event-loop, run-to-completion, no-blocking
lesson-33.txtARM-KEIL uVisionlesson-33.zip
qpc.zip
video33
3227:30#32 OOP Part-4:
Polymorphism in C
lesson-32.txtARM-KEIL uVisionlesson-32.zip
qpc.zip
video32
3123:42#31 OOP Part-3:
Polymorphism in C++
lesson-31.txtARM-KEIL uVisionlesson-31.zip
qpc.zip
video31
3024:02#30 OOP Part-2:
Inheritance in C and C++
lesson-30.txtARM-KEIL uVisionlesson-30.zip
qpc.zip
video30
2931:29#29 OOP Part-1:
Encapsulation (classes) in C and C++
lesson-29.txtARM-KEIL uVisionlesson-29.zip
qpc.zip
video29
2838:02#28 RTOS Part-7:
Mutual exclusion mechanisms
lesson-28.txtARM-KEIL uVisionlesson-28.zip
qpc.zip
video28
2743:03#27 RTOS Part-6:
Synchronization and communication among concurrent threads
lesson-27.txtARM-KEIL uVisionlesson-27.zip
qpc.zip
video27
2629:31#26 RTOS Part-5:
What is "real-time"? Preemptive, priority-based scheduling
lesson-26.txtARM-KEIL uVisionlesson-26.zip
qpc.zip
video26
2525:35#25 RTOS Part-4:
Efficient blocking of threads
lesson-25.txtARM-KEIL uVision
lesson-25.zip
qpc.zip
video25
2419:15#24 RTOS Part-3:
Automating the scheduling process
lesson-24.txtARM-KEIL uVisionlesson-24.zip
qpc.zip
video24
2337:36#23 RTOS Part-2:
Automating the context switch
lesson-23.txtARM-KEIL uVisionlesson-23.zip
qpc.zip
video23
2223:26#22 RTOS Part-1:
What is a Real-Time Operating System?
lesson-22.txtARM-KEIL uVisionlesson-22.zip
qpc.zip
video22
2118:37#21 Foreground-Background Architecture
("Superloop")
lesson-21.txtARM-KEIL uVisionlesson-21.zip
qpc.zip
video21
2016:58#20 Race Conditions:
What are they and how to avoid them?
lesson-20.txtTI CCS (Eclipse)lesson-20.zip
CMSIS.zip
video20
1922:19#19 GNU-ARM Toolchain and Eclipse IDElesson-19.txtTI CCS (Eclipse)lesson-19.zip
CMSIS.zip
video19
1815:28#18 interrupts Part-3:
How interrupts work on ARM Cortex-M?
lesson-18.txtIAR EWARMlesson-18.zip
CMSIS.zip
video18
1719:52#17 interrupts Part-2:
How most CPUs (e.g. MSP430) handle interrupts?
lesson-17.txtIAR EWARMlesson-17.zip
CMSIS.zip
video17
1615:59#16 Interrupts Part-1:
What are interrupts and how they work?
lesson-16.txtIAR EWARMlesson-16.zip
CMSIS.zip
video16
1527:35#15 Startup Code Part-3:
Vector table initialization, exception handlers, interrupt handlers
lesson-15.txtIAR EWARMlesson-15.zip
CMSIS.zip
video15
1425:44#14 Startup Code Part-2:
Replacing the vector-table, embedded software build process
lesson-14.txtIAR EWARMlesson-14.zip
CMSIS.zip
video14
1323:27#13 Startup Code Part-1:
What is startup code and how the CPU gets from reset to main?
lesson-13.txtIAR EWARMlesson-13.zip
CMSIS.zip
video13
1232:11#12 Structures in C and
Cortex Microcontroller Software Interface Standard (CMSIS)
lesson-12.txtIAR EWARMlesson-12.zip
CMSIS.zip
video12
1128:34#11 Standard integers (stdint.h)
and mixing integer types
lesson-11.txtIAR EWARMlesson-11.zipvideo11
1027:42#10 Stack Overflow and
Other Pitfalls of Functions
lesson-10.txtIAR EWARMlesson-10.zipvideo10
919:08#9 Modules, Recursion,
ARM Application Procedure Call Standard (AAPCS)
lesson-09.txtIAR EWARMlesson-09.zipvideo09
817:06#8 Functions in C and the call stacklesson-08.txtIAR EWARMlesson-08.zipvideo08
715:22#7 Arrays and Pointer Arithmeticlesson-07.txtIAR EWARMlesson-07.zipvideo07
617:06#6 Bit-wise operators in Clesson-06.txtIAR EWARMlesson-06.zipvideo06
514:30#5 Preprocessor and
the "volatile" keyword in C
lesson-05.txtIAR EWARMlesson-05.zipvideo05
416:45#4 How a computer can change anything outside,
like blinking an LED?
lesson-04.txtIAR EWARMlesson-04.zipvideo04
312:23#3 Variables and Pointerslesson-03.txtIAR EWARMlesson-03.zipvideo03
211:00#2 How to change the flow of control
through your code
lesson-02.txtIAR EWARMlesson-02.zipvideo02
117:06#1 How computers count?lesson-01.txtIAR EWARMlesson-01.zipvideo01
09:17#0 Modern Embedded Systems Programming:
Getting Started
lesson-00.txtIAR EWARMvideo00