Skip to content

The Node server for running the LiteBrite including the Peggy API

Notifications You must be signed in to change notification settings

nchrysler/Peggy

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

87 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

API

There are two routes to the API. They respond to any HTTP verb. All example query paramaters are required.

	/peggy/write/
	e.g. /peggy/write?board=1&x=0&y0&text=hello%20world

To change the colors in the text add either {r} for red {o} for orange or {g} for green. All subsequent characters will be that color. You can use multiple colors in the the text param. E.g. "{o}Hello {r}World{g}!" will have "Hello" in red "World" in Orange and "!" in green.

	/peggy/clear
	e.g. /peggy/clear?board=1

Modules

Any .js files in the modules subdirectory will be forked and executed immediately. Scripts there are responsible for keeping themselves alive.


Boards are in the following order

	0 1 4
	2 3 5

Boards 0-3 have 80 columns and 12 rows each. Boards 4 and 5 have 32 columns and 12 rows. A request that extends a write request beyond a board will probably, maybe fail.

About

The Node server for running the LiteBrite including the Peggy API

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 96.5%
  • CSS 2.3%
  • HTML 1.2%