1 definition module mTaskInterpret
3 from Data.Functor.Identity import :: Identity
4 from Control.Monad.State import :: State, :: StateT
5 from Data.Monoid import class Semigroup, class Monoid
18 = MTTask MTaskInterval String
28 instance toString MTaskInterval
29 instance toString MTaskMSGRecv
30 instance toString MTaskMSGSend
31 encode :: MTaskMSGSend -> String
32 decode :: String -> MTaskMSGRecv
59 //Conditionals and jumping
79 :: ByteCode a p = BC (BCState -> ([BC], BCState))
80 instance Semigroup (ByteCode a p)
81 instance Monoid (ByteCode a p)
86 sdss :: [(Int, [Char])]
90 class toByteCode a :: a -> [Char]
91 instance toByteCode Int
92 instance toByteCode Bool
93 instance toByteCode Char
94 instance toByteCode String
95 instance toByteCode Long
96 instance toByteCode Button
97 instance toByteCode UserLED
98 //instance toByteCode MTaskInterval
101 instance arith ByteCode
102 instance boolExpr ByteCode
103 instance analogIO ByteCode
104 instance digitalIO ByteCode
105 instance userLed ByteCode
106 //instance If ByteCode Stmt Stmt Stmt
107 //instance If ByteCode e Stmt Stmt
108 //instance If ByteCode Stmt e Stmt
109 instance If ByteCode x y Stmt
111 instance noOp ByteCode
113 instance sds ByteCode
114 instance assign ByteCode
115 instance seq ByteCode
116 instance serial ByteCode
118 toMessages :: MTaskInterval (String, BCState) -> ([MTaskMSGSend], BCState)
119 toSDSUpdate :: Int Int -> [MTaskMSGSend]
121 toByteVal :: BC -> [Char]
122 toReadableByteCode :: (ByteCode a b) -> (String, BCState)
123 toRealByteCode :: (ByteCode a b) BCState -> (String, BCState)