greenhouse
a creative coding toolkit for spatial interfaces

Message-passing with Plasma

The Plasma message-passing system makes it painless to communicate within a program, between different programs, or between different machines in a network.

Plasma messages are called proteins. They’re sent according to a simple variation on publish-subscribe.

In brief, to send a message, one party puts it in an intermediate container called a pool. Any number of other clients can listen for the messages that arrive in a pool (we call this “metabolizing” a protein). And everybody can put messages into a pool (we call this “depositing”).

  • Proteins
  • Pools
  • FAQ

Example

//in the terminal

//to create a pool called 'book':
$ p-create book

//To know the pool size and status:
$ p-info book

//To list all the local pools:
$ p-list

//To look at what is going on in a pool (very useful to test your code):
$ peek book

//To destroy a pool:
$ p-stop book