package TopSim where import GetPut import Top import Uart mkTopSim :: Module Empty mkTopSim = module timer :: Reg (Bit 8) <- mkReg 0 uart <- mkUart 1 rules when True ==> do timer := timer + 1 when (timer == 0x00) ==> uart.send.put 0x81 when (timer == 0x01) ==> uart.send.put 0x18 when (timer == 0x02) ==> uart.send.put 0x81 when (timer == 0x40) ==> do $finish -- vim: set ft=haskell :