]> Git — Sourcephile - tmp/julm/arpeggigon.git/blob - RMCA/tests/testClock.hs
Generalized reactive value types.
[tmp/julm/arpeggigon.git] / RMCA / tests / testClock.hs
1 import RMCA.Global.Clock
2 import RMCA.Auxiliary.Auxiliary
3 import RMCA.Semantics
4 import FRP.Yampa
5
6 main :: IO ()
7 main = do
8 putStr "Testing metronome: "
9 print testMetronome
10
11 tempo' :: SF () Tempo
12 tempo' = switch ((constant 30)
13 &&&
14 (after 20 10)) (\t -> switch ((constant t)
15 &&&
16 (after 20 60)) (constant))
17
18 testMetronome = embed (metronome (tempo'))
19 ((), take 120 $ repeat (1, Nothing))