Safe Haskell | None |
---|---|
Language | Haskell2010 |
You should not need to import this module unless you're adding support for a new model of Arduino, or an Arduino library.
Documentation
Indicates that you're programming an arduino, and not some other kind of hardware. The similar library zephyr-copilot allows programming other embedded boards in a very similar style to this one.
Instances
A pin on the Arduino board.
For definitions of pins like pin12
,
load a module such as Copilot.Arduino.Uno, which provides the pins of a
particular board.
A type-level list indicates how a Pin can be used, so the haskell compiler will detect impossible uses of pins.
Instances
IsAnalogInputPin t => Input Arduino (Pin t) ADC Source # | |
IsDigitalIOPin t => Input Arduino (Pin t) Bool Source # | |
IsPWMPin t => Output Arduino (Pin t) (Event 'PWM (Stream Word8)) Source # | |
IsDigitalIOPin t => Output Arduino (Pin t) (Event () (Stream Bool)) Source # | |
Eq (Pin t) Source # | |
Ord (Pin t) Source # | |
Show (Pin t) Source # | |
type Framework = GenFramework Arduino Source #
The framework of a sketch.
type Sketch = GenSketch Arduino Source #
An Arduino sketch, implemented using Copilot.
It's best to think of the Sketch
as a description of the state of the
board at any point in time.
Under the hood, the Sketch
is run in a loop. On each iteration, it first
reads inputs and then updates outputs as needed.
While it is a monad, a Sketch's outputs are not updated in any particular order, because Copilot does not guarantee any order.
module Sketch.FRP.Copilot.Internals
module Sketch.FRP.Copilot.Types
module Sketch.FRP.Copilot