From: Mart Lubbers Date: Thu, 1 Dec 2016 14:15:15 +0000 (+0100) Subject: update ignore en update itask gedeelte X-Git-Url: https://git.martlubbers.net/?a=commitdiff_plain;h=1c97288ebbdc9ff0a75ded8e57b13eedd1bb6c5e;p=ri1617.git update ignore en update itask gedeelte --- diff --git a/.gitignore b/.gitignore index 454d0cb..de98cae 100644 --- a/.gitignore +++ b/.gitignore @@ -6,3 +6,5 @@ *.fmt *.out *.dvi +*.tdo +*.toc diff --git a/architecture/a.tex b/architecture/a.tex index d555177..32f0924 100644 --- a/architecture/a.tex +++ b/architecture/a.tex @@ -25,7 +25,10 @@ We can divide the communication up into two parts. Communication from the \iTasks{} server to the microcontroller and vice versa. The means of communicating are unimportant, this can be TCP, Serial or any other -communication method that sends data in a linear way. +communication method that sends data in a linear way. It must be noted that the +communication is not necessarily fast and thus these resources are scarce. +Therefore the architecture tries to minimize the usage of communication +resources. \subsubsection{\iTasks{} $\rightarrow$ microcontroller} \input{commim.tex} diff --git a/architecture/conclusion.tex b/architecture/conclusion.tex index 783f276..3d3e145 100644 --- a/architecture/conclusion.tex +++ b/architecture/conclusion.tex @@ -1 +1,5 @@ +Added to the repository with code is a reference implementation of the +\mTasks{} engine written in \emph{C}. Without too much implementation this +program can be ported to any microcontroller. + \todo{Conclusie} diff --git a/architecture/itasks.tex b/architecture/itasks.tex index 8747721..98683e7 100644 --- a/architecture/itasks.tex +++ b/architecture/itasks.tex @@ -1,2 +1,26 @@ +\subsubsection{\iTasks{} task} To make the integration of \mTask{}s in \iTasks{} more orthogonal we need a -special kind of task that serves as a mothertask +special kind of task that serves as a mothertask that has the type visible in +Listing~\ref{lst:mothertask}. At first the system must be initialized with the +first given function. This will setup the necessary communication tasks and +SDSs used for interal storage and communication. This task is automatically +started when the system boots up. To add a task one has to call \CI{addmTask} +which will send the task to the system and evaluate it. Currently the only way +of getting info back is through SDSs that are used in the \mTask. Some tasks +are designed to run indefinite, for example temperature monitoring, and to +remove them the \CI{delmTask} function is introduced that will remove the task +and return a success value. + +\begin{lstlisting}[language=Clean,label={lst:mothertask}] +mTask :: DeviceSpec -> Task () +addmTask :: (ByteCode a p) -> Task Int +delmTask :: Int -> Task Bool +\end{lstlisting} + +\subsubsection{Shared Data Sources} +\mTask{}s can use SDSs for means of storing information and for communicating +with the server. Communication can be slow and therefore SDSs are only updated +when a task specifically asks for it through the bytecode instructions for +publishing and getting SDS values. + +\todo{Uitleg over synchronisatie als de sds op de server veranderd}