wled-json 0.1.0.4 → 0.1.0.5
raw patch · 3 files changed
+16/−2 lines, 3 filesdep ~rhinePVP ok
version bump matches the API change (PVP)
Dependency ranges changed: rhine
API changes (from Hackage documentation)
Files
- CHANGELOG.md +4/−0
- app/Main.hs +10/−0
- wled-json.cabal +2/−2
CHANGELOG.md view
@@ -8,6 +8,10 @@ - Awesome upcoming features! +## 0.1.0.5 - Unlash `rhine` - 2026-06-26++- Support `rhine-1.8`.+ ## 0.1.0.4 - Unlash `crypton` - 2026-06-25 - No longer restrict transient dependency `crypton`.
app/Main.hs view
@@ -37,14 +37,24 @@ switchFlags frequency = arr (\t -> allFlags !! (floor (t * frequency) `mod` length allFlags)) where allFlags = ($ octocatSpec) <$> [bulgaria, belgium, cameroon, chad, france, guatemala, guinea, ireland, italy, ivoryCoast, mali, nigeria, peru] +#if MIN_VERSION_rhine(1,7,0)+animation :: (Monad m, TimeDomain (Time cl), Diff (Time cl) ~ Seconds Double) => ClSF m cl () StatePatch+animation = sinceStart >>> arr getSeconds >-> proc time -> do+#else animation :: (Monad m, TimeDomain (Time cl), Diff (Time cl) ~ Double) => ClSF m cl () StatePatch animation = sinceStart >-> proc time -> do+#endif brightness <- brightnessSinus 0.1 -< time flag <- switchFlags 0.2 -< time returnA -< brightness <> flag +#if MIN_VERSION_rhine(1,7,0)+traverseLed :: (Monad m, TimeDomain (Time cl), Diff (Time cl) ~ Seconds Double) => ClSF m cl () StatePatch+traverseLed = sinceStart >>> arr getSeconds >-> arr (\t -> (mempty :: StatePatch) { stateBri = Just 255, stateSeg = Just [segment (floor (t / 3.0)) (floor (t / 3.0) + 1 ) [255, 255, 255]]})+#else traverseLed :: (Monad m, TimeDomain (Time cl), Diff (Time cl) ~ Double) => ClSF m cl () StatePatch traverseLed = sinceStart >-> arr (\t -> (mempty :: StatePatch) { stateBri = Just 255, stateSeg = Just [segment (floor (t / 3.0)) (floor (t / 3.0) + 1 ) [255, 255, 255]]})+#endif main :: IO () main = do
wled-json.cabal view
@@ -5,7 +5,7 @@ -- see: https://github.com/sol/hpack name: wled-json-version: 0.1.0.4+version: 0.1.0.5 synopsis: Convenient interface for interacting with WLED devices description: Please see the README on GitHub at <https://github.com/alaendle/wled-json#readme> category: Interfaces@@ -68,7 +68,7 @@ ghc-options: -O0 -Weverything -Wno-unsafe -Wno-missing-import-lists -Wno-prepositive-qualified-module -Wno-implicit-prelude -Wno-missing-safe-haskell-mode -Wno-safe -Wno-missing-role-annotations -threaded -rtsopts -with-rtsopts=-N build-depends: base >=4.7 && <5- , rhine >=1.4.0.1 && <1.7+ , rhine >=1.4.0.1 && <1.9 , wled-json default-language: Haskell2010 if impl(ghc > 9.12)