I am involved in teaching FRP and Reactive-banana, writing what I hope will become a more useful tutorial for those who follow me. You can check my progress in the tutorial here .
I am stuck trying to implement simple sound examples using events. I know that I need to do something like this:
reactimate $ fmap (uncurry playNote) myEvent
in my NetworkDescription , but I can’t understand how simple the network is to repeat the same thing, or to do something once. Ideally, I am looking for things like this:
once :: a -> Event ta repeatWithDelay :: Event ta -> Time -> Event ta concatWithDelay :: Event ta -> Event ta -> Time -> Event ta
The Time type above is just a means of waiting for any measurement of time that we ultimately use. Do I need to connect the system time as a behavior in order to control the "delay" functions? This seems more complicated than necessary.
Thanks in advance,
Echo nolan
EDIT: Well, the types for repeatWithDelay and concatWithDelay do not make sense. This is what I really had in mind.
repeatWithDelay :: a -> Time -> Event ta concatWithDelay :: a -> a -> Time -> Event ta
Echo nolan
source share