EC-9.6 Concurrency, Real Time and the RTOS
You can say where a single loop stops being adequate, share data safely between a handler and the main flow, state a real-time requirement in a testable way, and decide whether a small operating system earns its place.
Before:S5-2. Computer Architecture and MicroprocessorsEC-7. Signals and SystemsUnlocks:PE1-4. Embedded C ProgrammingEC-13. Laboratory Practice, in Sequence
Real time does not mean fast, it means on time, and the distinction is the whole subject. This topic is also where the standard advice is most often wrong: a small operating system solves some problems and creates others, and knowing which is which saves a great deal of effort on systems that never needed one.
Work through these
The super-loop, and where it breaks
One loop calling each piece of work in turn is predictable and open to inspection. It breaks when one piece of work is slow and another cannot wait for it, which is a scheduling problem rather than a speed problem.
NPTEL: Embedded Systems Design (IIT Kharagpur) · CourseShared data between a handler and the main flow
A variable written by a handler and read by the main flow can be read half-updated if it takes more than one instruction. The usual fixes are a single-byte flag, a short section with interrupts held off, or a ring buffer.
NPTEL: Embedded Systems Design (IIT Kharagpur) · CourseWhat real time actually means
A real-time requirement names a deadline and what happens if it is missed. Hard means a missed deadline is a failure of the system, soft means the result is merely degraded, and most systems contain both kinds.
NPTEL: Introduction to Embedded System Design (NSUT and IIT Jammu) · CourseTasks, the scheduler and the context switch
An operating system gives each piece of work its own stack and saves and restores registers to swap between them. That swap has a cost in time and memory, and it is what buys you independent pieces of work.
NPTEL: Embedded System Design with ARM (IIT Kharagpur) · CourseSemaphores, mutexes and priority inversion
A mutex protects shared data by making other work wait. If low-priority work holds a mutex that urgent work needs, the urgent work is stuck behind it, which is priority inversion and is why inheritance schemes exist.
NPTEL: Embedded System Design with ARM (IIT Kharagpur) · CourseWhen an operating system is the wrong answer
It costs memory, adds timing that is harder to predict, and brings a new set of bugs. On a part with two kilobytes of working memory and one job to do, a loop and an interrupt are the better engineering.
NPTEL: Embedded Systems Design (IIT Kharagpur) · Course
Sign in to keep your progress.
Free resources
We haven't checked most of these for screen reader use yet.
- FreeNPTEL / IIT Kharagpur · CourseNPTEL: Embedded Systems Design (IIT Kharagpur)
- FreeNPTEL / Netaji Subhas University of Technology and IIT Jammu · CourseNPTEL: Introduction to Embedded System Design (NSUT and IIT Jammu)
- FreeNPTEL / IIT Kharagpur · CourseNPTEL: Embedded System Design with ARM (IIT Kharagpur)
Links last checked 3 Sept 2026.
Stuck here?
Ask a mentor. A real person answers, and they can see exactly which topic you're on. Usually within a couple of working days.
Checking your session…
Topics shown in module order.