arduino-copilot: Arduino programming in haskell using the Copilot stream DSL

[ bsd3, embedded, language, library ] [ Propose Tags ]

arduino-copilot contains the basic building blocks to program your Arduino Nano, Arduino Uno or compatible hardware using Haskell and Functional Reactive Programming (FRP).

arduino-copilot uses the Copilot stream DSL (domain-specific language) to generate an Arduino sketch, which can be loaded in the Arduino IDE and uploaded to the board. Other methods of deploying sketches to the Arduino, such as the Arduino-Makefile, can also be used with a sketch generated by arduino-copilot.

All the messy details are abstracted away, letting you focus on the desired behavior of the Arduino.

Copilot is a stream (i.e., infinite lists) domain-specific language (DSL) in Haskell that compiles into embedded C. Copilot contains an interpreter, multiple back-end compilers, and other verification tools. https://copilot-language.github.io/


[Skip to Readme]

Downloads

Maintainer's Corner

Package maintainers

For package maintainers and hackage trustees

Candidates

  • No Candidates
Versions [RSS] 0.0.1, 1.0.0, 1.0.1, 1.1.1, 1.2.0, 1.3.0, 1.4.0, 1.5.0, 1.5.1, 1.5.2, 1.5.3, 1.5.4, 1.5.5, 1.5.6, 1.5.7, 1.6.0, 1.7.0, 1.7.1, 1.7.2, 1.7.3, 1.7.4, 1.7.5, 1.7.6, 1.7.7, 1.7.8
Change log CHANGELOG
Dependencies base (>=4.5 && <5), containers, copilot (>=3.18 && <3.19), copilot-c99 (>=3.18 && <3.19), copilot-language (>=3.18 && <3.19), directory, filepath, mtl, optparse-applicative (>=0.14.1), sketch-frp-copilot (==1.0.10), temporary [details]
License BSD-3-Clause
Copyright 2020 Joey Hess
Author Joey Hess
Maintainer Joey Hess <id@joeyh.name>
Category Embedded, Language
Source repo head: git clone git://git.joeyh.name/arduino-copilot.git
Uploaded by JoeyHess at 2024-02-22T18:24:00Z
Distributions
Downloads 4849 total (73 in the last 30 days)
Rating 2.0 (votes: 1) [estimated by Bayesian average]
Your Rating
  • λ
  • λ
  • λ
Status Docs available [build log]
Last success reported on 2024-02-22 [all 1 reports]

Readme for arduino-copilot-1.7.8

[back to package description]
Arduino programming in haskell using the Copilot stream DSL

See Copilot.Arduino for details on how to use write a program using this
library.

For example, to make an Arduino blink its LED:

	import Copilot.Arduino
	main = arduino $ do
		led =: blinking
		delay =: MilliSeconds (constant 100)

This and other examples are included in the Examples/ directory, each
with their own README explaining how to build and use them.

## Contributing

Contributions are welcome, including adding support for more
Arduino C libraries, provided that the C library is reasonably commonly
used, and is licensed with a free software license.

Contributors of such libraries will be expected to maintain them,
otherwise they may get removed if they are blocking changes to
arduino-copilot or are buggy.

Any contribution should have well documented functions and types.