Commit c9590ef3 authored by Jonas Künzli's avatar Jonas Künzli Committed by overleaf
Browse files

Update on Overleaf.

parent faf1bd5d
......@@ -10,8 +10,11 @@ fertig\\
\item Add Polling and Interrupt (Slide 3-55)
\ownsubsection{Kapitel 4: Programming Paradigms}
fertig!!:D \\
\ownsubsection{Kapitel 5: OS}
fertig!!:D \\
\ownsubsection{Kapitel 6: aperiodic, periodic scheduling}
fertig!!:D \\
\ownsubsection{Kapitel 9: Power and Energy}
\item Add Application control (Slide 9-53)
......@@ -21,7 +21,7 @@ Advantages and properties of embedded OS
\item Protection mechanisms not always necessary (Processes tested and considered reliable). $\implies$ Tasks can do their own I/O, including interrupts
\ownsection{Real-Time OS (5-6)}
\ownsubsection{Real-Time OS (5-6)}
\item The timing behaviour of the OS must be predictable
\subitem For all services upper bound on execution time
......@@ -48,31 +48,13 @@ Advantages and properties of embedded OS
\item \textbf{Run:} A task enters this state when it starts executing on the processor
\item \textbf{Ready:} State of tasks that are ready to execute but cannot be executed because processor is assigned to another task
\item \textbf{Wait:} A task enters this state when it executes a synchronization primitive to wait for an event, e.g. a wait primite or a semaphore.
\item \textbf{Idle:} A periodic job enters this state when it completes its execution and has to wait for the beginning of the next period.
\textbf{Blocked}: A task enters this state when it executes a synchronization primitive to wait for an event, e.g. a wait primite or a semaphore.
\ownsubsection{Threads (5-16)}
A thread is the smallest sequence of programmed instructions that can be managed independently by a scheduler. Multiple threads can exist within the same process and share resources such as memory, while different processes do not share these resource
s. The \textcolor{red}{Thread Control Block (TCB)} stores information needed to manage and schedule a thread.
\ownsubsection{Communication Mechanisms}
\textbf{Problem:} The use of shared resources for implementing message passing schemes may cause priority inversion and blocking.
\textbf{Synchronous communication:}
\item Synchronization for a message transfer (\textcolor{red}{rendez-vous}) $\implies$ They have to wait for each other
\item When off-line scheduling: Transformation into precedence constraints.
\textbf{Asynchronous communication:}
\item Usage of \textbf{Mailbox} (shared memory buffer, FIFO-queue with fixed cap.) $\implies$ Tasks do not have to wait for each other
\item Better suited for real-time systems than synchronous communication
\item Problem: Blocking behaviour if channel is full or empty
\ownsubsection{Classes of embedded OS (5-18)}
\textbf{Class 1: Fast Proprietary Kernels}: For hard real-time systems, these kernels are questionable, because they are designed to be fast, rather than to be predictable in every respect. ~\newline
......@@ -94,5 +76,15 @@ Typical Research questions:
\item formally verified kernel properties
%\ownsubsection{FreeRTOS (5-25)}
\ownsubsection{FreeRTOS (5-25)}
\begin{tabularx}{\columnwidth}{|p{1.7cm} | X|}
5-28 & Task Management \\
5-32 & Timers \\
5-35 & Task States \\
5-39 & Interrupts \\
% !TeX root = ../main.tex
\ownsection{Aperiodic and Periodic Scheduling (6)}
\ownsubsection{Real-Time Systems (6-3)}
\item A real-time task is said to be \textcolor{red}{hard}, if missing its deadline may cause catastrophic consequences on the environment under control.
......@@ -194,7 +193,7 @@ This condition is both necessary and sufficient.
\ownsubsection{EDF Scheduling (4-42)}
\ownsubsection{EDF Scheduling (6-56)}
Dynamic priority assignment, intrinsically preemptive, deadlines can be smaller than periods: $D_i \leq T_i$
\textbf{Algorithm:} The currently executing task is preempted whenever another periodic instance with earlier deadline becomes active
......@@ -207,3 +206,49 @@ EDF is optimal w.r.t. schedulability (no set of periodic tasks can be scheduled
\item if $T_i\neq D_i$:
$$U=\sum_{i=1}^{n}\frac{C_i}{D_i}\leq1$$ is only sufficient.
\ownsection{Real‐Time Scheduling of Mixed Task Sets (6-63)}
For applications with both aperiodic and periodic tasks.
\item \textcolor{red}{Periodic Tasks:} time-driven, hard timing constraints
\item \textcolor{red}{Aperiodic Tasks:} event-driven, may have hard, soft or no real-time requirements
\item \textcolor{red}{Sporadic Tasks:} Aperiodic task with a maximum arrival rate (or minimum time between two arrivals) assumed.
\ownsubsection{Background Scheduling (6-65)}
Schedule periodic tasks with RM or EDF. Process aperiodic task in the background, that is, when there is no periodic task request.
\item Good: Periodic tasks not affected
\item Bad: Aperiodic task may have huge response times and cannot be prioritized.
\ownsubsection{RM Polling Server (6-67)}
Introduce an artificial periodic task (\textcolor{red}{server}) to service aperiodic requests. The server is characterized by a period $T_s$ and a computation time $C_s$ and scheduled with the same algorithm used for periodic tasks. \\
Schedulability condition is the same as for normal RM. \\
Disadvantage: If an aperiodic requests arrives just after the server has suspended, it must wait until the beginning of the next polling period. \\
\textbf{Schedulability analysis - sufficient but not necessary}
$$\frac{C_s}{T_s}+\sum_{i=1}^n\frac{C_i}{T_i}\leq \left(n+1\right)\left(2^{1/(n+1)}-1\right)$$
\textbf{Aperiodic Guarantee: }
Assumption: An aperiodic task is finished before a new one arrives. Computation time $C_a$, deadline $D_a$:
$$(1+\Big\lceil\frac{C_a}{C_s}\Big\rceil)T_s\leq D_a$$
\ownsubsection{EDF Total Bandwidth Server (6-71)}
\textbf{Schedulability test}: Given a set of $n$ periodic tasks with processor utilization $U_p$ and a total bandwidth server with utilization $U_s$, the whole set is schedulable by EDF if and only if
$$U_p+U_s\leq 1$$
\shortintertext{Utilization of periodic tasks:}
U_p &= \sum_i \frac{C_i}{T_i}\\
\shortintertext{Utilization of aperiodic tasks:}
U_s &= \frac{C_s}{T_s}
When the $k$-th aperiodic request arrives at time $t=r_k$, it receives a
deadline $$d_k=\max\{r_k,d_{k-1}\}+\frac{C_k}{U_s}$$ where $C_k$ is the
execution time of the request and $U_s $ the server utilization factor
(=bandwidth). $U_S$ can be chosen such that $U_s\leq 1-U_p$ (necessary and
......@@ -28,6 +28,10 @@ Optimize latency, hardware cost, power and energy
A solution $a \in X$ weakly Pareto-dominates a solution $b \in X$ ($a \preceq b$) if it is as least as good in all objectives. Solution is $a$ is better than $b$ ($a \prec b$) iff $(a \preceq b) \land (b \cancel{\preceq} a)$
\begin{definition}{Pareto point}
is a point on a graph (eg. cost vs. latency). For a given architecture if following points are possible (5,11),(5,10),(3,7) and (3,4) then only the points (5,10) and (3,4) are pareto points.
A solution is \textcolor{red}{Pareto-optimal}, if it is not Pareto-dominated by any other solution. \newline
The set of all Pareto-optimal solutions is the \textcolor{red}{Pareto-optimal front}.
......@@ -4,8 +4,8 @@
\lhead{Embedded Systems}
\chead{FS17 }
\rhead{Gian Marti}
\rhead{Very Cool Kids}
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment