update presentation more
authorMart Lubbers <mart@martlubbers.net>
Fri, 7 Jul 2017 18:07:04 +0000 (20:07 +0200)
committerMart Lubbers <mart@martlubbers.net>
Fri, 7 Jul 2017 18:07:04 +0000 (20:07 +0200)
Makefile [new file with mode: 0644]
build
pres.conclusion.tex
pres.intro.tex
pres.mtask.tex
pres.system.tex
presentation.pre
presentation.tex

diff --git a/Makefile b/Makefile
new file mode 100644 (file)
index 0000000..c0fb0a0
--- /dev/null
+++ b/Makefile
@@ -0,0 +1,2 @@
+all:
+       ./build
diff --git a/build b/build
index 685e33f..de903fe 100755 (executable)
--- a/build
+++ b/build
@@ -15,6 +15,16 @@ deps(){
                while read l; do deps "$l"; done
 }
 
                while read l; do deps "$l"; done
 }
 
+graphicdeps(){
+       grep -Pzo '\\includegraphics[%\t\n ]*(\[.*\])?[%\t\n ]*\{.*?\}' $1 |\
+               tr '\0' '\n' | grep -Po '(?<=\{).*?(?=\})' |\
+               while read l; do echo "$2/$l"; done
+}
+
+graphicspath(){
+       :
+}
+
 recompile(){
        for dep in $(deps "$1"); do
                if [ "$dep" -nt "$2" ]; then
 recompile(){
        for dep in $(deps "$1"); do
                if [ "$dep" -nt "$2" ]; then
index 31a14f5..bf626bc 100644 (file)
                \item Interrupts
        \end{itemize}
 \end{frame}
                \item Interrupts
        \end{itemize}
 \end{frame}
+
+\subsection{Demo}
+\begin{frame}
+       \frametitle{And ofcourse\ldots\pause{} a demo}
+       \pause{}
+       \begin{figure}
+               \centering
+               \includegraphics[width=.6\linewidth]{demo}
+       \end{figure}
+\end{frame}
index a87e514..c4f90bf 100644 (file)
                        \item Monitoring (Temperature, Electricity, Humidity, Heartbeat)
                        \item Acting (Servo's, Motors)
                        \item Tracking (GPS, WiFi tracking)
                        \item Monitoring (Temperature, Electricity, Humidity, Heartbeat)
                        \item Acting (Servo's, Motors)
                        \item Tracking (GPS, WiFi tracking)
-                       \item Relaying (SMS, Whatsapp)
+                       \item Communication (SMS, Whatsapp)
                        \pause{}
                        \pause{}
-                       \item Combinations: e.g. Thermostat
-                       \item Smart clothing, smart watches
+                       \item Combinations: e.g. Thermostat, Smart Clothing, Smart Watches
                \end{itemize}
        \end{block}
 \end{frame}
                \end{itemize}
        \end{block}
 \end{frame}
                \pause{}
                \item Heaps of communication methods: LoRa (Sigfox, KPN, TTN), BTLE, WiFi, ZigBee\ldots
                \pause{}
                \pause{}
                \item Heaps of communication methods: LoRa (Sigfox, KPN, TTN), BTLE, WiFi, ZigBee\ldots
                \pause{}
-               \item But\ldots
-               \pause{}
                \item Separated logic
                \item Integration problems
                \item Separated logic
                \item Integration problems
-               \item Reprogramming, write cycles
        \end{itemize}
 \end{frame}
 
        \end{itemize}
 \end{frame}
 
@@ -46,7 +42,7 @@
        \frametitle{And there is TOP/iTasks}
        \begin{block}{iTasks}
                \begin{itemize}[<+->]
        \frametitle{And there is TOP/iTasks}
        \begin{block}{iTasks}
                \begin{itemize}[<+->]
-                       \item Basic blocks
+                       \item Tasks are basic blocks
                        \item Generated web interface
                        \item Type driven
                        \item EDSL
                        \item Generated web interface
                        \item Type driven
                        \item EDSL
                \item iTasks server
                \item IoT device client
                \item EDSL to make IoT tasks
                \item iTasks server
                \item IoT device client
                \item EDSL to make IoT tasks
-               \item Interpreted on the client
-               \item No reprogramming
+               \item Internalship
        \end{itemize}
        \end{itemize}
-       \pause{}
-       Internalship
 \end{frame}
 
 \begin{frame}
 \end{frame}
 
 \begin{frame}
                \item Write client software
                \item Write server software
                \item Connect them up
                \item Write client software
                \item Write server software
                \item Connect them up
+               \item But first some theory
+               \item Reprogramming, write cycles
        \end{itemize}
 \end{frame}
 
        \end{itemize}
 \end{frame}
 
@@ -203,6 +198,7 @@ enterName = enterInformation "Enter your name" []
                \begin{itemize}[<+->]
                        \item Read function
                        \item Write function
                \begin{itemize}[<+->]
                        \item Read function
                        \item Write function
+                       \item Both have access to the world
                \end{itemize}
        \end{block}
 
                \end{itemize}
        \end{block}
 
@@ -221,65 +217,7 @@ wait :: String (r -> Bool) (ReadWriteShared r w) -> Task r
        \end{lstlisting}
 \end{frame}
 
        \end{lstlisting}
 \end{frame}
 
-\begin{frame}[fragile]
-       \frametitle{SDS (2)}
-       \framesubtitle{Parametric Lenses}
-       \begin{block}{What is the \CI{p} for in \CI{RWShared p r w}}
-               \pause{}
-               \begin{itemize}
-                       \item Parameter fixed when writing
-                       \item Used for notifications
-               \end{itemize}
-       \end{block}
-
-       \begin{lstlisting}
-sdsFocus :: p1 (RWShared p1 r w) -> RWShared p2 r w | iTask p
-
-:: SDSNotifyPred p :== p -> Bool
-:: SDSLensRead p r rs     = SDSRead        (p -> rs -> MaybeError TaskException r)
-                          | SDSReadConst   (p -> r)
-:: SDSLensWrite p w rs ws = SDSWrite       (p -> rs -> w -> MaybeError TaskException (Maybe ws))
-                          | SDSWriteConst  (p -> w -> MaybeError TaskException (Maybe ws))
-:: SDSLensNotify p w rs   = SDSNotify      (p -> rs -> w -> SDSNotifyPred p)
-                          | SDSNotifyConst (p -> w -> SDSNotifyPred p)
-
-sdsLens :: String (p -> ps) (SDSLensRead p r rs) (SDSLensWrite p w rs ws)
-       (SDSLensNotify p w rs) (RWShared ps rs ws) -> RWShared p r w | iTask ps
-       \end{lstlisting}
-\end{frame}
-
 \begin{frame}
 \begin{frame}
-       \frametitle{Why add IoT devices to iTasks}
-       \begin{block}{Why?}
-               \begin{itemize}
-                       \item Execute Tasks
-                       \item Monitoring
-                       \item Hardware
-               \end{itemize}
-       \end{block}
-
-       \pause{}
-
-       \begin{block}{Current possibilities}
-               \begin{itemize}
-                       \item Implement a device as an SDS
-                       \pause{}
-                       \item Tailor made SDS for every task
-                       \item Difficult to get logic in
-                       \pause{}
-                       \item Arjan's Distributed iTasks
-                       \pause{}
-                       \item Requires fast hardware
-                       \pause{}
-               \end{itemize}
-       \end{block}
-\end{frame}
-
-\begin{frame}
-       \frametitle{Solution}
-       \pause{}
-       \begin{block}{EDSL to the rescue}
-               \pause{}
-               After the break.
-       \end{block}
+       \frametitle{But not all Tasks or SDSs are suitable for microcontrollers\ldots}
+       \pause\centering\Large EDSLs to the rescue
 \end{frame}
 \end{frame}
index ef80aaf..ec40ae4 100644 (file)
@@ -10,6 +10,8 @@
                \item Language in a language
                \item Use the properties of the host
                \item E.g., Ivory, \ldots\pause{} and iTasks
                \item Language in a language
                \item Use the properties of the host
                \item E.g., Ivory, \ldots\pause{} and iTasks
+               \pause{}
+               \item Different embedding techniques
        \end{itemize}
 \end{frame}
 
        \end{itemize}
 \end{frame}
 
@@ -137,6 +139,7 @@ instance intArith PrettyPrinter where
        \pause{}
        \begin{block}{What is mTask}
                \begin{itemize}
        \pause{}
        \begin{block}{What is mTask}
                \begin{itemize}
+                       \item Created by Pieter Koopman and Rinus Plasmeijer
                        \item EDSL
                        \item Arduino C++ generation, iTasks simulation
                \end{itemize}
                        \item EDSL
                        \item Arduino C++ generation, iTasks simulation
                \end{itemize}
@@ -154,17 +157,17 @@ instance intArith PrettyPrinter where
 \begin{frame}[fragile]
        \frametitle{Expressions}
        \begin{block}{mTask}
 \begin{frame}[fragile]
        \frametitle{Expressions}
        \begin{block}{mTask}
-               \begin{itemize}
-                       \item Two phantom types
-                       \item Hierarchy
+               \begin{itemize}[<+->]
+                       \item Of the form \CI{v t p}
+                       \item \CI{p} is hierarchical
                \end{itemize}
        \end{block}
        \pause{}
        \begin{lstlisting}
 class arith v where
   lit           :: t -> v t Expr
                \end{itemize}
        \end{block}
        \pause{}
        \begin{lstlisting}
 class arith v where
   lit           :: t -> v t Expr
-  (+.) infixl 6 :: (v t p) (v t q) -> v t Expr          | +, zero t    & isExpr p & isExpr q
-  (-.) infixl 6 :: (v t p) (v t q) -> v t Expr          | -, zero t    & ...
+  (+.) infixl 6 :: (v t p) (v t q) -> v t Expr | +, zero t & isExpr p & isExpr q
+  (-.) infixl 6 :: (v t p) (v t q) -> v t Expr | -, zero t & ...
   ...
 class boolExpr v where
   Not           :: (v Bool p) -> v Bool Expr            | ...
   ...
 class boolExpr v where
   Not           :: (v Bool p) -> v Bool Expr            | ...
@@ -177,18 +180,10 @@ class boolExpr v where
 \begin{frame}[fragile]
        \frametitle{Control flow}
        \begin{lstlisting}
 \begin{frame}[fragile]
        \frametitle{Control flow}
        \begin{lstlisting}
-class If v q r ~s where
-  If :: (v Bool p) (v t q) (v t r) -> v t s | ...
-
 class IF v where
   IF :: (v Bool p) (v t q) (v s r) -> v () Stmt | ...
   (?) infix 1 :: (v Bool p) (v t q) -> v () Stmt | ...
 
 class IF v where
   IF :: (v Bool p) (v t q) (v s r) -> v () Stmt | ...
   (?) infix 1 :: (v Bool p) (v t q) -> v () Stmt | ...
 
-instance If Code Stmt Stmt Stmt
-instance If Code e    Stmt Stmt
-instance If Code Stmt e    Stmt
-instance If Code x    y    Expr
-
 class seq v where
   (:.) infixr 0 :: (v t p) (v u q) -> v u Stmt | ...
        \end{lstlisting}
 class seq v where
   (:.) infixr 0 :: (v t p) (v u q) -> v u Stmt | ...
        \end{lstlisting}
@@ -232,8 +227,8 @@ class assign v where
        \begin{lstlisting}
 blink = task \blink=(\x.
             IF (x ==. lit True)
        \begin{lstlisting}
 blink = task \blink=(\x.
             IF (x ==. lit True)
-               (ledOn led)
-               (ledOff led) :.
+               (ledOn LED1)
+               (ledOff LED2) :.
             blink (lit 1000) (Not x))
         In {main=blink (lit 1000) True}
 
             blink (lit 1000) (Not x))
         In {main=blink (lit 1000) True}
 
index 4c8b2fb..b4a1504 100644 (file)
@@ -1,25 +1,26 @@
 \subsection{Overview}
 \subsection{Overview}
+\begin{frame}
+       \frametitle{Current state of mTask}
+       \begin{itemize}
+               \item It all seems perfect
+               \item \ldots\pause{} but\ldots
+               \pause{}
+               \item No interaction
+               \item Compilation requires reprogramming
+               \item Entire system is created and fixed
+       \end{itemize}
+\end{frame}
+
 \begin{frame}
        \frametitle{Solution}
 \begin{frame}
        \frametitle{Solution}
-       \begin{block}{Downsides of the current mTask view}
-               \begin{itemize}
-                       \item It all seems perfect
-                       \item \ldots\pause{} but\ldots
-                       \pause{}
-                       \item No interaction
-                       \item Compilation requires reprogramming
-               \end{itemize}
-       \end{block}
-       \pause{}
-       \begin{block}{Solution}
-               \begin{itemize}[<+->]
-                       \item New bytecode backend for mTask
-                       \item Interpreter on client
-                       \item Server in iTasks with integration
-                       \item No taskserver generation, onetime programming
-                       \item Explicit SDS publishing
-               \end{itemize}
-       \end{block}
+       \begin{itemize}[<+->]
+               \item New bytecode backend for mTask
+               \item Interpreter on client
+               \item Server in iTasks with integration
+               \item No taskserver generation, onetime programming
+               \item Dynamic task sending
+               \item Explicit SDS publishing
+       \end{itemize}
 \end{frame}
 
 \subsection{Extending mTask}
 \end{frame}
 
 \subsection{Extending mTask}
@@ -82,27 +83,26 @@ BCIfStmt (BC b) (BC t) (BC e) = BC (
        \end{lstlisting}
 \end{frame}
 
        \end{lstlisting}
 \end{frame}
 
-\begin{frame}[fragile]
-       \frametitle{Functionality}
-       \begin{block}{SDS scope and naming}
-               \begin{itemize}
-                       \item SDS is lost
-                       \item State per device
-                       \item Tasks are sent and gone
-                       \item Save bandwidth
-               \end{itemize}
-               \pause{}
-               \begin{lstlisting}
-class namedsds v where
-       namedsds :: ((v t Upd) -> In (Named t String) (Main (v c s)))
-               -> (Main (v c s)) | ...
-:: Named a b = Named infix 1 a b
-
-instance sdspub ByteCode where
-       pub (BC x) = BC (censor (\[BCSdsFetch s]->[BCSdsPublish s]) x)
-               \end{lstlisting}
-       \end{block}
-\end{frame}
+%\begin{frame}[fragile]
+%      \frametitle{Functionality}
+%      \begin{block}{SDS scope and naming}
+%              \begin{itemize}
+%                      \item SDS is lost
+%                      \item State per device
+%                      \item Tasks are sent and gone
+%              \end{itemize}
+%              \pause{}
+%              \begin{lstlisting}
+%class namedsds v where
+%      namedsds :: ((v t Upd) -> In (Named t String) (Main (v c s)))
+%              -> (Main (v c s)) | ...
+%:: Named a b = Named infix 1 a b
+%
+%instance sdspub ByteCode where
+%      pub (BC x) = BC (censor (\[BCSdsFetch s]->[BCSdsPublish s]) x)
+%              \end{lstlisting}
+%      \end{block}
+%\end{frame}
 
 \begin{frame}[fragile]
        \frametitle{Assignment}
 
 \begin{frame}[fragile]
        \frametitle{Assignment}
@@ -118,11 +118,15 @@ instance sds ByteCode where
 instance assign ByteCode where
        (=.) (BC v) (BC e) = BC (e >>| censor makeStore v)
 
 instance assign ByteCode where
        (=.) (BC v) (BC e) = BC (e >>| censor makeStore v)
 
+instance sdspub ByteCode where
+       pub (BC x) = BC (censor (\[BCSdsFetch s]->[BCSdsPublish s]) x)
+
 makeStore [BCSdsFetch i]    = [BCSdsStore i]
 makeStore [BCDigitalRead i] = [BCDigitalWrite i]
 makeStore [...]             = [...]
        \end{lstlisting}
 \end{frame}
 makeStore [BCSdsFetch i]    = [BCSdsStore i]
 makeStore [BCDigitalRead i] = [BCDigitalWrite i]
 makeStore [...]             = [...]
        \end{lstlisting}
 \end{frame}
+
 \begin{frame}[fragile]
        \frametitle{Task scheduling}
        \begin{block}{Old}
 \begin{frame}[fragile]
        \frametitle{Task scheduling}
        \begin{block}{Old}
@@ -171,4 +175,31 @@ class retrn v where
 \end{frame}
 
 \subsection{Server}
 \end{frame}
 
 \subsection{Server}
+\begin{frame}[fragile]
+       \frametitle{SDS (2)}
+       \framesubtitle{Parametric Lenses}
+       \begin{block}{What is the \CI{p} for in \CI{RWShared p r w}}
+               \pause{}
+               \begin{itemize}
+                       \item Parameter fixed when writing
+                       \item Used for notifications
+                       \item On write the SDS returns \CI{p -> Bool}
+               \end{itemize}
+       \end{block}
+%
+%      \begin{lstlisting}
+%sdsFocus :: p1 (RWShared p1 r w) -> RWShared p2 r w | iTask p
+%
+%:: SDSNotifyPred p :== p -> Bool
+%:: SDSLensRead p r rs     = SDSRead        (p -> rs -> MaybeError TaskException r)
+%                          | SDSReadConst   (p -> r)
+%:: SDSLensWrite p w rs ws = SDSWrite       (p -> rs -> w -> MaybeError TaskException (Maybe ws))
+%                          | SDSWriteConst  (p -> w -> MaybeError TaskException (Maybe ws))
+%:: SDSLensNotify p w rs   = SDSNotify      (p -> rs -> w -> SDSNotifyPred p)
+%                          | SDSNotifyConst (p -> w -> SDSNotifyPred p)
+%
+%sdsLens :: String (p -> ps) (SDSLensRead p r rs) (SDSLensWrite p w rs ws)
+%      (SDSLensNotify p w rs) (RWShared ps rs ws) -> RWShared p r w | iTask ps
+%      \end{lstlisting}
+\end{frame}
 \subsection{Examples}
 \subsection{Examples}
index 654b89b..4c9df64 100644 (file)
@@ -1,4 +1,4 @@
-\documentclass{beamer}
+\documentclass[handout]{beamer}
 
 \usepackage{listings}              % Source code
 \usepackage{subcaption}            % Subcaptions
 
 \usepackage{listings}              % Source code
 \usepackage{subcaption}            % Subcaptions
index fe6b5b8..044b4dc 100644 (file)
 \section{Introduction}
 \input{pres.intro}
 
 \section{Introduction}
 \input{pres.intro}
 
-%\section{EDSLs \& mTask}
-%\input{pres.mtask}
-%
-%\section{System Overview}
-%\input{pres.system}
+\section{EDSLs \& mTask}
+\input{pres.mtask}
+
+\section{System Overview}
+\input{pres.system}
 
 \section{Conclusion}
 \input{pres.conclusion}
 
 
 \section{Conclusion}
 \input{pres.conclusion}
 
-\section{Demo}
-\begin{frame}
-       \frametitle{And ofcourse\ldots\pause{} a demo}
-       \pause{}
-       \begin{figure}
-               \centering
-               \includegraphics[width=.6\linewidth]{demo}
-       \end{figure}
-\end{frame}
-
 \end{document}
 \end{document}