Update README for 0.4
This commit is contained in:
parent
787aec6f95
commit
10b2bc6938
10
README.md
10
README.md
|
@ -47,6 +47,10 @@ Lambdas can also be applied anonymously, as in `((fn (a) (* a a)) 5)`, which als
|
||||||
|
|
||||||
Uses an anonymous lambda to square each element in the list. This is particularly useful on a low-memory device like the Pebble, where it may be useful to avoid storing the named lambda object in the environment.
|
Uses an anonymous lambda to square each element in the list. This is particularly useful on a low-memory device like the Pebble, where it may be useful to avoid storing the named lambda object in the environment.
|
||||||
|
|
||||||
|
Lambdas may also have no arguments:
|
||||||
|
|
||||||
|
`(fn () 9001)`
|
||||||
|
|
||||||
## Cat
|
## Cat
|
||||||
`cat` returns its arguments concatenated as strings. It has the same general form as arithmetic operators
|
`cat` returns its arguments concatenated as strings. It has the same general form as arithmetic operators
|
||||||
|
|
||||||
|
@ -95,14 +99,14 @@ There are several functions for fetching invidual elements of the current time
|
||||||
|
|
||||||
For example
|
For example
|
||||||
|
|
||||||
`(mnt 0 0)`
|
`(mnt)`
|
||||||
|
|
||||||
would return 16, if called at 5:16
|
would return 16, if called at 5:16
|
||||||
|
|
||||||
## Vibrating
|
## Vibrating
|
||||||
`vibe` calls the vibration engine to start, following a given pattern. The pattern should be a list, composed of alternating on/off durations, in milliseconds. For example
|
`vibe` calls the vibration engine to start, following a given pattern. The pattern should be a list, composed of alternating on/off durations, in milliseconds. For example
|
||||||
|
|
||||||
`(vibe (100 200 200 400 200 800) 0)`
|
`(vibe (100 200 200 400 200 800))`
|
||||||
|
|
||||||
would cause a sort of *Bz. Bzz. Bzzzz. Bzzzzzzzz.* pattern.
|
would cause a sort of *Bz. Bzz. Bzzzz. Bzzzzzzzz.* pattern.
|
||||||
|
|
||||||
|
@ -113,7 +117,7 @@ Basic Window and TextLayer manipulations are enabled in PebbLisp.
|
||||||
|
|
||||||
`pw` is the function responsible for pushing a window onto the stack. For example
|
`pw` is the function responsible for pushing a window onto the stack. For example
|
||||||
|
|
||||||
`(def win (cw 0 0)) (pw win 0)`
|
`(def win (cw)) (pw win)`
|
||||||
|
|
||||||
Creates and pushes to the screen a blank white window. Note that windows can be exited by tapping the back button. Getting something useful to display requires the use of a TextLayer.
|
Creates and pushes to the screen a blank white window. Note that windows can be exited by tapping the back button. Getting something useful to display requires the use of a TextLayer.
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue