retroclash-lib 0.1.0.1 → 0.1.1
raw patch · 4 files changed
+16/−11 lines, 4 filesdep −th-orphansdep ~clash-ghcdep ~clash-libdep ~clash-prelude
Dependencies removed: th-orphans
Dependency ranges changed: clash-ghc, clash-lib, clash-prelude, template-haskell
Files
- retroclash-lib.cabal +5/−8
- src/RetroClash/Memory.hs +0/−1
- src/RetroClash/PS2.hs +5/−0
- src/RetroClash/VGA.hs +6/−2
retroclash-lib.cabal view
@@ -3,11 +3,9 @@ -- This file has been generated from package.yaml by hpack version 0.34.4. -- -- see: https://github.com/sol/hpack------ hash: aa099865dc012dbd6398d27ca852c4156d87b4f2a135826025a0d3774d5fff80 name: retroclash-lib-version: 0.1.0.1+version: 0.1.1 synopsis: Code shared across the code samples in the book "Retrocomputing with Clash" description: Clash components useful when implementing, or interfacing with, retro-computers:@@ -99,9 +97,9 @@ build-depends: barbies >=2.0.1 && <2.1 , base >=4.14 && <5- , clash-ghc >=1.4.2 && <1.5- , clash-lib >=1.4.2 && <1.5- , clash-prelude >=1.4.2 && <1.5+ , clash-ghc >=1.4.2 && <1.5 || >=1.6.1 && <1.7+ , clash-lib >=1.4.2 && <1.5 || >=1.6.1 && <1.7+ , clash-prelude >=1.4.2 && <1.5 || >=1.6.1 && <1.7 , containers , ghc-typelits-extra , ghc-typelits-knownnat@@ -110,7 +108,6 @@ , lift-type ==0.1.* , monoidal-containers ==0.6.* , mtl- , template-haskell >=2.16 && <3- , th-orphans >=0.13+ , template-haskell , transformers default-language: Haskell2010
src/RetroClash/Memory.hs view
@@ -37,7 +37,6 @@ import Data.Map.Monoidal as Map import Language.Haskell.TH hiding (Type)-import Language.Haskell.TH.Instances import LiftType import Type.Reflection (Typeable)
src/RetroClash/PS2.hs view
@@ -1,4 +1,5 @@ {-# LANGUAGE RecordWildCards, LambdaCase #-}+{-# LANGUAGE UndecidableInstances #-} module RetroClash.PS2 ( PS2(..) , samplePS2@@ -15,6 +16,7 @@ ) where import Clash.Prelude+import Clash.Class.HasDomain import RetroClash.Utils import RetroClash.Clock import Control.Monad.State@@ -26,6 +28,9 @@ { ps2Clk :: "CLK" ::: Signal dom Bit , ps2Data :: "DATA" ::: Signal dom Bit }++type instance HasDomain dom1 (PS2 dom2) = DomEq dom1 dom2+type instance TryDomain t (PS2 dom) = Found dom samplePS2 :: forall dom. (HiddenClockResetEnable dom, KnownNat (ClockDivider dom (Microseconds 1)))
src/RetroClash/VGA.hs view
@@ -1,8 +1,8 @@-{-# LANGUAGE ScopedTypeVariables, NumericUnderscores, PartialTypeSignatures #-}+{-# LANGUAGE ScopedTypeVariables, NumericUnderscores #-} {-# LANGUAGE DuplicateRecordFields, RecordWildCards, ApplicativeDo #-} {-# LANGUAGE ExistentialQuantification, StandaloneDeriving #-} {-# LANGUAGE LambdaCase #-}-{-# OPTIONS_GHC -Wno-partial-type-signatures #-}+{-# LANGUAGE UndecidableInstances #-} module RetroClash.VGA ( VGASync(..) , VGADriver(..)@@ -18,6 +18,7 @@ ) where import Clash.Prelude+import Clash.Class.HasDomain import RetroClash.Clock import RetroClash.Utils import Data.Maybe (isJust)@@ -34,6 +35,9 @@ , vgaG :: "GREEN" ::: Signal dom (Unsigned g) , vgaB :: "BLUE" ::: Signal dom (Unsigned b) }++type instance HasDomain dom1 (VGAOut dom2 r g b) = DomEq dom1 dom2+type instance TryDomain t (VGAOut dom r g b) = Found dom data VGADriver dom w h = VGADriver { vgaSync :: VGASync dom