Copyright  (C) 20132015, University of Twente 

License  BSD2 (see the file LICENSE) 
Maintainer  Christiaan Baaij <christiaan.baaij@gmail.com> 
Safe Haskell  Unsafe 
Language  Haskell2010 
Extensions 

 data Clock = Clk Symbol Nat
 data SClock clk where
 data Signal' clk a = a : (Signal' clk a)
 register# :: SClock clk > a > Signal' clk a > Signal' clk a
 regEn# :: SClock clk > a > Signal' clk Bool > Signal' clk a > Signal' clk a
 mux :: Applicative f => f Bool > f a > f a > f a
 signal :: Applicative f => a > f a
 (.&&.) :: Applicative f => f Bool > f Bool > f Bool
 (..) :: Applicative f => f Bool > f Bool > f Bool
 not1 :: Functor f => f Bool > f Bool
 simulate :: (Signal' clk1 a > Signal' clk2 b) > [a] > [b]
 sample :: Foldable f => f a > [a]
 sampleN :: Foldable f => Int > f a > [a]
 fromList :: [a] > Signal' clk a
 testFor :: Foldable f => Int > f Bool > Property
 (.==.) :: (Eq a, Applicative f) => f a > f a > f Bool
 (./=.) :: (Eq a, Applicative f) => f a > f a > f Bool
 compare1 :: (Ord a, Applicative f) => f a > f a > f Ordering
 (.<.) :: (Ord a, Applicative f) => f a > f a > f Bool
 (.<=.) :: (Ord a, Applicative f) => f a > f a > f Bool
 (.>=.) :: (Ord a, Applicative f) => f a > f a > f Bool
 (.>.) :: (Ord a, Applicative f) => f a > f a > f Bool
 mapSignal# :: (a > b) > Signal' clk a > Signal' clk b
 signal# :: a > Signal' clk a
 appSignal# :: Signal' clk (a > b) > Signal' clk a > Signal' clk b
 foldr# :: (a > b > b) > b > Signal' clk a > b
 traverse# :: Applicative f => (a > f b) > Signal' clk a > f (Signal' clk b)
 fromEnum1 :: (Enum a, Functor f) => f a > f Int
 toRational1 :: (Real a, Functor f) => f a > f Rational
 toInteger1 :: (Integral a, Functor f) => f a > f Integer
 testBit1 :: (Bits a, Applicative f) => f a > f Int > f Bool
 popCount1 :: (Bits a, Functor f) => f a > f Int
 shift1 :: (Bits a, Applicative f) => f a > f Int > f a
 rotate1 :: (Bits a, Applicative f) => f a > f Int > f a
 setBit1 :: (Bits a, Applicative f) => f a > f Int > f a
 clearBit1 :: (Bits a, Applicative f) => f a > f Int > f a
 shiftL1 :: (Bits a, Applicative f) => f a > f Int > f a
 unsafeShiftL1 :: (Bits a, Applicative f) => f a > f Int > f a
 shiftR1 :: (Bits a, Applicative f) => f a > f Int > f a
 unsafeShiftR1 :: (Bits a, Applicative f) => f a > f Int > f a
 rotateL1 :: (Bits a, Applicative f) => f a > f Int > f a
 rotateR1 :: (Bits a, Applicative f) => f a > f Int > f a
 joinSignal# :: Signal' clk (Signal' clk a) > Signal' clk a
Datatypes
Singleton value for a typelevel Clock
with the given name
and period
A synchronized signal with samples of type a
, explicitly synchronized to
a clock clk
NB: The constructor, (
, is not synthesisable.:
)
Functor (Signal' clk) Source  
Applicative (Signal' clk) Source  
Foldable (Signal' clk) Source  NB: Not synthesisable NB: In "

Traversable (Signal' clk) Source  
Bounded a => Bounded (Signal' clk a) Source  
Enum a => Enum (Signal' clk a) Source  
Eq (Signal' clk a) Source  WARNING: ( 
Fractional a => Fractional (Signal' clk a) Source  
Integral a => Integral (Signal' clk a) Source  WARNING: 
Num a => Num (Signal' clk a) Source  
Ord a => Ord (Signal' clk a) Source  WARNING: 
(Num a, Ord a) => Real (Signal' clk a) Source  WARNING: 
Show a => Show (Signal' clk a) Source  
Arbitrary a => Arbitrary (Signal' clk a) Source  
CoArbitrary a => CoArbitrary (Signal' clk a) Source  
Bits a => Bits (Signal' clk a) Source  WARNING: 
FiniteBits a => FiniteBits (Signal' clk a) Source  
Default a => Default (Signal' clk a) Source  
Lift a => Lift (Signal' clk a) Source  
SaturatingNum a => SaturatingNum (Signal' clk a) Source  
ExtendingNum a b => ExtendingNum (Signal' clk a) (Signal' clk b) Source  
type AResult (Signal' clk a) (Signal' clk b) = Signal' clk (AResult a b) Source  
type MResult (Signal' clk a) (Signal' clk b) = Signal' clk (MResult a b) Source 
Basic circuits
mux :: Applicative f => f Bool > f a > f a > f a Source
signal :: Applicative f => a > f a Source
Boolean connectives
Simulation functions (not synthesisable)
List <> Signal conversion (not synthesisable)
fromList :: [a] > Signal' clk a Source
Create a Signal
from a list
Every element in the list will correspond to a value of the signal for one clock cycle.
>>>
sampleN 2 (fromList [1,2,3,4,5])
[1,2]
NB: This function is not synthesisable
QuickCheck combinators
Type classes
Eq
like
(.==.) :: (Eq a, Applicative f) => f a > f a > f Bool infix 4 Source
(./=.) :: (Eq a, Applicative f) => f a > f a > f Bool infix 4 Source
Ord
like
compare1 :: (Ord a, Applicative f) => f a > f a > f Ordering Source
(.<.) :: (Ord a, Applicative f) => f a > f a > f Bool infix 4 Source
(.<=.) :: (Ord a, Applicative f) => f a > f a > f Bool infix 4 Source
(.>=.) :: (Ord a, Applicative f) => f a > f a > f Bool infix 4 Source
(.>.) :: (Ord a, Applicative f) => f a > f a > f Bool infix 4 Source
Functor
mapSignal# :: (a > b) > Signal' clk a > Signal' clk b Source
Applicative
appSignal# :: Signal' clk (a > b) > Signal' clk a > Signal' clk b Source
Foldable
foldr# :: (a > b > b) > b > Signal' clk a > b Source
NB: Not synthesisable
NB: In "
":foldr#
f z s
 The function
f
should be lazy in its second argument.  The
z
element will never be used.
Traversable
traverse# :: Applicative f => (a > f b) > Signal' clk a > f (Signal' clk b) Source
Enum
like
Rational
like
toRational1 :: (Real a, Functor f) => f a > f Rational Source
Integral
like
toInteger1 :: (Integral a, Functor f) => f a > f Integer Source
Bits
like
shift1 :: (Bits a, Applicative f) => f a > f Int > f a Source
rotate1 :: (Bits a, Applicative f) => f a > f Int > f a Source
setBit1 :: (Bits a, Applicative f) => f a > f Int > f a Source
clearBit1 :: (Bits a, Applicative f) => f a > f Int > f a Source
shiftL1 :: (Bits a, Applicative f) => f a > f Int > f a Source
unsafeShiftL1 :: (Bits a, Applicative f) => f a > f Int > f a Source
shiftR1 :: (Bits a, Applicative f) => f a > f Int > f a Source
unsafeShiftR1 :: (Bits a, Applicative f) => f a > f Int > f a Source
rotateL1 :: (Bits a, Applicative f) => f a > f Int > f a Source
rotateR1 :: (Bits a, Applicative f) => f a > f Int > f a Source