1 \emph{mTask
}s are written in a shallowly embedded class-based DSL that due to
2 the nature of it can be easily extended in language and in view. Currently
3 there is a view for generating
\emph{C
}-code and a view for simulating
4 \emph{mTasks
} using
\iTasks{}. Currently the
\emph{mTask
} code includes
5 functionality for running a small task server on the embedded device. These
6 features will not be used in this project as the microcontroller will serve a
7 slightly different purpose, namely serve as a task executioner instead of a
8 server. The bytecode compilation also adds a class that represents all things
9 compilable in bytecode to make sure all the basic types can be compiled. Both
10 signatures are shown in Listing~
\ref{lst:bytecode
}.
12 In the future a state will probably need to be added to the
\CI{Bytecode
}
13 type to keep track of some information during bytecode compilation.
15 \begin{lstlisting
}[language=Clean,label=
{lst:bytecode
}]
16 :: ByteCode a p = BC
[BC
]
17 class toByteCode a :: a ->
[Char
]