rhine-1.4: Functional Reactive Programming with type-level clocks
Safe HaskellSafe-Inferred
LanguageHaskell2010

FRP.Rhine.Clock.Realtime.Millisecond

Description

Provides a clock that ticks at every multiple of a fixed number of milliseconds.

Synopsis

Documentation

newtype Millisecond (n :: Nat) Source #

A clock ticking every n milliseconds, in real time.

Since n is in the type signature, it is ensured that when composing two signals on a Millisecond clock, they will be driven at the same rate.

For example, Millisecond 100 ticks every 0.1 seconds, so 10 times per seconds.

The tag of this clock is 'Maybe Double', where Nothing represents successful realtime, and Just lag a lag (in seconds).

Instances

Instances details
Clock IO (Millisecond n) Source # 
Instance details

Defined in FRP.Rhine.Clock.Realtime.Millisecond

Associated Types

type Time (Millisecond n) Source #

type Tag (Millisecond n) Source #

GetClockProxy (Millisecond n) Source # 
Instance details

Defined in FRP.Rhine.Clock.Realtime.Millisecond

type Tag (Millisecond n) Source # 
Instance details

Defined in FRP.Rhine.Clock.Realtime.Millisecond

type Time (Millisecond n) Source # 
Instance details

Defined in FRP.Rhine.Clock.Realtime.Millisecond

waitClock :: KnownNat n => Millisecond n Source #

Tries to achieve real time by using waitUTC, see its docs.