Difference between revisions of "Yampa"

From HaskellWiki
Jump to navigation Jump to search
 
(30 intermediate revisions by 6 users not shown)
Line 1: Line 1:
 
Yampa is a domain-specific embedded language for the programming of hybrid (discrete and continuous time) systems using the concepts of [[Functional Reactive Programming]] (FRP). Yampa is structured using [[Arrow]]s, which greatly reduce the chance of introducing space- and time-leaks into reactive, time-varying systems.
 
Yampa is a domain-specific embedded language for the programming of hybrid (discrete and continuous time) systems using the concepts of [[Functional Reactive Programming]] (FRP). Yampa is structured using [[Arrow]]s, which greatly reduce the chance of introducing space- and time-leaks into reactive, time-varying systems.
   
Yampa was originally developed by the [http://haskell.cs.yale.edu/ Yale Haskell Group] based on the original idea of [http://www.conal.net Conal Elliott's] [[Fran]].
+
Yampa was originally developed by the [http://haskell.cs.yale.edu/ Yale Haskell Group] based on the original idea of [http://www.conal.net Conal Elliott's] [http://conal.net/fran/ Fran].
   
  +
Hackage: {{HackagePackage|id=Yampa}}
'''[https://github.com/eamsden/Animas Download Animas]''' (most up to date Yampa fork, or [http://hackage.haskell.org/cgi-bin/hackage-scripts/package/Yampa download original Yampa])
 
   
 
== Introduction ==
 
== Introduction ==
   
* [http://www.cs.nott.ac.uk/~nhn/FoPAD2007/Talks/nhn-FoPAD2007.pdf Henrik Nilsson - A Brief Introduction to Functional Reactive Programming and Yampa]
+
* [http://www.cs.nott.ac.uk/~psznhn/FoPAD2007/Talks/nhn-FoPAD2007.pdf Henrik Nilsson - A Brief Introduction to Functional Reactive Programming and Yampa]
* [http://www.cs.nott.ac.uk/~nhn/ITU-FRP2010/ Henrik Nilsson - ITU-FRP2010]
+
* [http://www.cs.nott.ac.uk/~psznhn/ITU-FRP2010/ Henrik Nilsson - ITU-FRP2010]
** [http://www.cs.nott.ac.uk/~nhn/ITU-FRP2010/LectureNotes/lecture01.pdf ITU-FRP2010 01]
+
** [http://www.cs.nott.ac.uk/~psznhn/ITU-FRP2010/LectureNotes/lecture01.pdf ITU-FRP2010 01]
** [http://www.cs.nott.ac.uk/~nhn/ITU-FRP2010/LectureNotes/lecture02.pdf ITU-FRP2010 02]
+
** [http://www.cs.nott.ac.uk/~psznhn/ITU-FRP2010/LectureNotes/lecture02.pdf ITU-FRP2010 02]
** [http://www.cs.nott.ac.uk/~nhn/ITU-FRP2010/LectureNotes/lecture03.pdf ITU-FRP2010 03]
+
** [http://www.cs.nott.ac.uk/~psznhn/ITU-FRP2010/LectureNotes/lecture03.pdf ITU-FRP2010 03]
** [http://www.cs.nott.ac.uk/~nhn/ITU-FRP2010/LectureNotes/lecture04.pdf ITU-FRP2010 04]
+
** [http://www.cs.nott.ac.uk/~psznhn/ITU-FRP2010/LectureNotes/lecture04.pdf ITU-FRP2010 04]
** [http://www.cs.nott.ac.uk/~nhn/ITU-FRP2010/LectureNotes/lecture05.pdf ITU-FRP2010 05]
+
** [http://www.cs.nott.ac.uk/~psznhn/ITU-FRP2010/LectureNotes/lecture05.pdf ITU-FRP2010 05]
** [http://www.cs.nott.ac.uk/~nhn/ITU-FRP2010/LectureNotes/lecture06.pdf ITU-FRP2010 06]
+
** [http://www.cs.nott.ac.uk/~psznhn/ITU-FRP2010/LectureNotes/lecture06.pdf ITU-FRP2010 06]
** [http://www.cs.nott.ac.uk/~nhn/ITU-FRP2010/LectureNotes/lecture07.pdf ITU-FRP2010 07]
+
** [http://www.cs.nott.ac.uk/~psznhn/ITU-FRP2010/LectureNotes/lecture07.pdf ITU-FRP2010 07]
* [http://plucky.cs.yale.edu/CS429F04/LectureSlides/YampaForCs429.ppt Paul Hudak - Yampa, Arrows, and Robots]
+
* [http://www.cs.yale.edu/homes/hudak/CS429F04/LectureSlides/YampaForCs429.ppt Paul Hudak - Yampa, Arrows, and Robots]
* Yampa tutorials by [http://lambdor.net Gerold Meisinger]
+
* Yampa tutorials by Gerold Meisinger
  +
** [https://lambdor-net.readthedocs.io/learn.html Learning Yampa and Functional Reactive Programming] [https://web.archive.org/web/20100823084116/http://lambdor.net/?p=44 (archived)]
** [http://lambdor.net/?p=34 Running primitive signal functions in Yampa]
 
  +
** [https://lambdor-net.readthedocs.io/embed.html Running primitive signal functions in Yampa] [https://web.archive.org/web/20100822210238/http://lambdor.net/?p=34 (archived)]
** [http://lambdor.net/?p=59 Yampa/SDL program stub]
 
  +
** [https://lambdor-net.readthedocs.io/sdlstub.html Yampa/SDL program stub] [https://web.archive.org/web/20100823084125/http://lambdor.net/?p=59 (archived)]
** [http://lambdor.net/?p=44 Learning Yampa and Functional Reactive Programming]
 
  +
** [https://lambdor-net.readthedocs.io/dataflow.html Dataflow diagram of Yampa reactimate] [https://web.archive.org/web/20100822074057/http://lambdor.net/?p=117 (archived)]
** [http://lambdor.net/?p=209 Diagrams of Yampa switches]
 
** [http://lambdor.net/?p=117 Dataflow diagram of Yampa reactimate]
+
** [https://lambdor-net.readthedocs.io/activity.html Activity diagram of Yampa reactimate] [https://web.archive.org/web/20100822074010/http://lambdor.net/?p=113 (archived)]
** [http://lambdor.net/?p=113 Activity diagram of Yampa reactimate]
+
** [https://web.archive.org/web/20101008051015/http://lambdor.net/?p=209 Diagrams of Yampa switches]
  +
* [http://yampa-book.rtfd.io Yampa book - Tutorial series for BearRiver Yampa]
* [p
 
* References: [https://frvr.svn.sourceforge.net/svnroot/frvr/AFRP/trunk/src/foo.ps ps], [http://lambdor.net/wp-content/uploads/2010/12/AFRP-Reference.pdf pdf]
+
* library reference sheet: [https://svn.code.sf.net/p/frvr/code/AFRP/trunk/src/foo.ps ps], [http://lambdor.net/wp-content/uploads/2010/12/AFRP-Reference.pdf pdf]
 
* Videos
 
* Videos
** [http://vimeo.com/6632457 Safe Functional Reactive Programming through Dependent Types]
+
** [https://vimeo.com/6632457 Safe Functional Reactive Programming through Dependent Types]
** [http://vimeo.com/6652662 Causal Commutative Arrows and Their Optimization]
+
** [https://vimeo.com/6652662 Causal Commutative Arrows and Their Optimization]
** [http://www.youtube.com/watch?v=xtmo6Bmfahc Euterpea: From signals to symphonies]
+
** [https://www.youtube.com/watch?v=xtmo6Bmfahc Euterpea: From signals to symphonies]
   
 
== Primitive signal functions ==
 
== Primitive signal functions ==
Line 38: Line 38:
   
 
== Switches ==
 
== Switches ==
  +
  +
[https://www.reddit.com/r/haskell/comments/3jqfh7/comment/curnksm/?utm_source=reddit&utm_medium=web2x&context=3 Reddit - How to read Yampa diagram?]
   
 
* [[Yampa/switch|switch]]
 
* [[Yampa/switch|switch]]
 
* [[Yampa/rSwitch|rSwitch]]
 
* [[Yampa/rSwitch|rSwitch]]
* [[Yampa/rSwitch|kSwitch]]
+
* [[Yampa/kSwitch|kSwitch]]
 
* [[Yampa/pSwitchB|pSwitchB]]
 
* [[Yampa/pSwitchB|pSwitchB]]
 
* [[Yampa/pSwitch|pSwitch]]
 
* [[Yampa/pSwitch|pSwitch]]
Line 59: Line 61:
   
 
* [http://mailman.cs.yale.edu/mailman/listinfo/yampa-users Yampa-Users mailing list] - Yampa-related comments, questions, discussions, and announcements. You can also send bug reports to [mailto:yampa-bugs@cs.yale.edu yampa-bugs@cs.yale.edu].
 
* [http://mailman.cs.yale.edu/mailman/listinfo/yampa-users Yampa-Users mailing list] - Yampa-related comments, questions, discussions, and announcements. You can also send bug reports to [mailto:yampa-bugs@cs.yale.edu yampa-bugs@cs.yale.edu].
  +
* [https://wiki.haskell.org/IRC_channel#Projects_using_haskell #yampa] - This is Yampa IRC Channel, please refer to [https://wiki.haskell.org/IRC_channel#Getting_there Getting there] on how to join the channel.
* [http://www.cs.nott.ac.uk/~ggg/ George Giorgidze] created YampaSynth, a modular music synthesizer written in Haskell and using Yampa.
 
  +
* [https://www.youtube.com/watch?feature=player_detailpage&v=T7XwTolu9YI Yampy Cube] - a live coding presentation with Yampa by Konstantin Zudov at Helsinki FRP Meetup May 6, 2015. [https://github.com/helsinki-frp/yampy-cube (Source code on Github)]
* [http://www.cs.yale.edu/homes/hl293] - Hai (Paul) Liu papers and slides
 
 
* [http://db.inf.uni-tuebingen.de/team/GeorgeGiorgidze.html George Giorgidze] created YampaSynth, a modular music synthesizer written in Haskell and using Yampa.
 
* [http://www.thev.net/PaulLiu/#publications Hai (Paul) Liu papers and slides]
 
* [http://lambdor.net Blog about Yampa] - introduction tutorials and diagrams
 
* [http://lambdor.net Blog about Yampa] - introduction tutorials and diagrams
* [http://blog.edwardamsden.com/2011/03/demonstrating-time-leak-in-arrowized.html Demonstrating a Time Leak in Arrowized FRP]
+
* [https://web.archive.org/web/20140820094516/http://blog.edwardamsden.com/2011/03/demonstrating-time-leak-in-arrowized.html Demonstrating a Time Leak in Arrowized FRP] (Web archive)
 
** [http://mailman.cs.yale.edu/pipermail/yampa-users/2011-April/000409.html answer]
 
** [http://mailman.cs.yale.edu/pipermail/yampa-users/2011-April/000409.html answer]
  +
* [https://www.youtube.com/results?search_query=yampa+haskell An overview of Yampa video clips on YouTube]
   
 
== Known users ==
 
== Known users ==
  +
  +
[https://www.google.com/search?hl=en&q=yampa%20site%3Ahackage.haskell.org%2Fpackage&aqi=g10 search Hackage]
 
 
* [http://hackage.haskell.org/cgi-bin/hackage-scripts/package/YampaSynth YampaSynth] - is a software synthesizer implemented in Haskell using Yampa. It contains a framework of sound generating and sound shaping modules (e.g. oscillator, amplifier, mixer, envelope generator, filter, etc.) and example applications.
+
* {{HackagePackage|id=YampaSynth}} - is a software synthesizer implemented in Haskell using Yampa. It contains a framework of sound generating and sound shaping modules (e.g. oscillator, amplifier, mixer, envelope generator, filter, etc.) and example applications.
 
* [http://www.haskell.org/haskellwiki/Frag Frag]; a simple Quake 3 clone, using a very early version of Yampa called arrowized functional reactive programming (AFRP)
 
* [http://www.haskell.org/haskellwiki/Frag Frag]; a simple Quake 3 clone, using a very early version of Yampa called arrowized functional reactive programming (AFRP)
* [http://hackage.haskell.org/cgi-bin/hackage-scripts/package/SpaceInvaders Space Invaders]; a video game, demonstrating the usage of Yampa
+
* {{HackagePackage|id=SpaceInvaders}}; a video game, demonstrating the usage of Yampa
  +
* {{HackagePackage|id=cuboid}}; a small puzzle game
* [http://haskell.cs.yale.edu/?page_id=376 Nettle] - Programming Network Routers
 
  +
* {{HackagePackage|id=Haskelloids}}; asteroids clone
* [http://haskell.cs.yale.edu/?page_id=103 Euterpea] - computer music development (also uses [[CCA]])
 
 
* [http://haskell.cs.yale.edu/nettle/ Nettle] - Programming Network Routers
 
* [http://haskell.cs.yale.edu/euterpea/ Euterpea] - computer music development (also uses [[CCA]])
  +
* {{HackagePackage|id=YFrob}}; robot simulation
  +
* [https://github.com/ivanperez-keera/haskanoid Haskanoid] A breakout-like videogame with SDL graphics and sound that can optionally be controlled with a Wiimote or a Kinect.
  +
* [https://play.google.com/store/apps/details?id=uk.co.keera.games.magiccookies&hl=en Magic Cookies!] An iOS/Android board game implemented in Haskell using Yampa and SDL2.
  +
  +
[https://github.com/search?q=yampa&repo=&langOverride=&start_value=1&type=Everything&language=Haskell search Github]
  +
  +
* [https://github.com/harley/hamball Hamball]
  +
* [https://github.com/werk/YampaShooter YampaShooter]
   
 
== Known forks ==
 
== Known forks ==
   
  +
* [https://github.com/ony/Yampa-core Yampa-core]
  +
** [http://mailman.cs.yale.edu/pipermail/yampa-users/2012-May/ related discussion]
 
* [https://github.com/eamsden/Animas Animas]
 
* [https://github.com/eamsden/Animas Animas]
 
** code cleanup
 
** code cleanup
  +
* [http://imve.informatik.uni-hamburg.de/projects/FRVR Functional Reactive Virtual Reality]
** [http://blog.edwardamsden.com/ Facts and Theories] blog by Edward Amsden
 
* [https://frvr.svn.sourceforge.net/svnroot/frvr/AFRP/trunk FRVR]
+
** [https://svn.code.sf.net/p/frvr/code/AFRP/trunk/ FRVR source code]
** restructuring of modules
 
 
** [http://imve.informatik.uni-hamburg.de/projects/DIVE DIVE project]
 
** [http://imve.informatik.uni-hamburg.de/projects/DIVE DIVE project]
** [http://imve.informatik.uni-hamburg.de/files/71-Blom-Diss-online.pdf Kristopher J. Blom - Dynamic, Interactive Virtual Environments] section 8.3
 
   
 
[[Category:FRP]]
 
[[Category:FRP]]
 
[[Category:Arrow]]
 
[[Category:Arrow]]
  +
[[Category:Music]]
  +
[[Category:Robotics]]

Latest revision as of 13:19, 13 October 2021

Yampa is a domain-specific embedded language for the programming of hybrid (discrete and continuous time) systems using the concepts of Functional Reactive Programming (FRP). Yampa is structured using Arrows, which greatly reduce the chance of introducing space- and time-leaks into reactive, time-varying systems.

Yampa was originally developed by the Yale Haskell Group based on the original idea of Conal Elliott's Fran.

Hackage: Yampa

Introduction

Primitive signal functions

Yampa signal functions.png

(download original Image:Yampa signal functions.svg‎)

Switches

Reddit - How to read Yampa diagram?

Each switch comes in two different flavors:

  1. immediate: switch to the new behaviour immediately and also calculate the return value based on the new behaviour.
  2. delayed: return the value based on the old behaviour, but use the new behaviour afterwards. To use delayed switch prefix the switching functions with the letter 'd', f.e. 'drpSwitchB'.

Reactimation

External Links

Known users

search Hackage

  • YampaSynth - is a software synthesizer implemented in Haskell using Yampa. It contains a framework of sound generating and sound shaping modules (e.g. oscillator, amplifier, mixer, envelope generator, filter, etc.) and example applications.
  • Frag; a simple Quake 3 clone, using a very early version of Yampa called arrowized functional reactive programming (AFRP)
  • SpaceInvaders; a video game, demonstrating the usage of Yampa
  • cuboid; a small puzzle game
  • Haskelloids; asteroids clone
  • Nettle - Programming Network Routers
  • Euterpea - computer music development (also uses CCA)
  • YFrob; robot simulation
  • Haskanoid A breakout-like videogame with SDL graphics and sound that can optionally be controlled with a Wiimote or a Kinect.
  • Magic Cookies! An iOS/Android board game implemented in Haskell using Yampa and SDL2.

search Github

Known forks