This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| {-#LANGUAGE LinearTypes#-} | |
| {-#LANGUAGE ScopedTypeVariables#-} | |
| {-#LANGUAGE BlockArguments#-} | |
| {-#LANGUAGE ViewPatterns#-} | |
| {-#OPTIONS_GHC -Wno-unused-top-binds#-} | |
| module Main where | |
| import qualified Data.IntMap as IM | |
| import qualified Data.IntMap.Linear as IML | |
| import qualified Data.Array.Mutable.Linear as AML |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Dependencies | |
| // esp-idf-sys = { version = "0.31.11", features = ["binstart"] } | |
| // esp-idf-svc = "0.43.4" | |
| // esp-idf-hal = "0.39.3" | |
| // embedded-hal = "0.2.7" | |
| // embedded-svc = "0.23.1" | |
| use std::{ | |
| thread::sleep, | |
| time::Duration, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| {-# LANGUAGE FlexibleContexts #-} | |
| {-# LANGUAGE GeneralizedNewtypeDeriving #-} | |
| {-# LANGUAGE StandaloneDeriving #-} | |
| {-# LANGUAGE TypeOperators #-} | |
| {-# LANGUAGE UndecidableInstances #-} | |
| {-# LANGUAGE ViewPatterns #-} | |
| import Data.Foldable as F | |
| import Data.Traversable as T | |
| import Data.Monoid | |
| import Control.Monad.State |