update hardware nodes info style

This commit is contained in:
Dave Conway-Jones
2016-03-02 13:25:52 +00:00
parent 88985f4fe7
commit 81c532fdce
42 changed files with 130 additions and 125 deletions

View File

@@ -17,8 +17,7 @@ Pimoroni Getting Started with Unicorn HAT</a> page.
Install
-------
Run the following command in the root directory of your Node-RED install.
Usually this is `~/.node-red`
Run the following command in your Node-RED user directory - typically `~/.node-red`
npm install node-red-node-pi-neopixel
@@ -28,7 +27,7 @@ The data pin of the pixels should be connected to physical pin 12 - GPIO 18 of t
Usage
-----
To set the background just set **msg.payload** to an `html_colour` name.
To set the background just set `msg.payload` to an `html_colour` name.
<a href="http://html-color-codes.info/color-names/" target="_top">Here
is a list</a> of html_colour names.
@@ -36,31 +35,34 @@ It also accepts a string triple `rrr,ggg,bbb` or `#rrggbb`
#### Bar Chart
Defaults style mode using configured foreground and background colours. The foreground colour is used to indicate the number of pixels or length required.
Defaults style mode using configured foreground and background colours. The
foreground colour is used to indicate the number of pixels or length required.
It accepts a number in **msg.payload** that can be either the number of pixels,
It accepts a number in `msg.payload` that can be either the number of pixels,
or a percentage of the total length.
If you want to change the foreground colour, you can set **msg.payload** to a
comma separated string of `html_colour,length` or `length,html_colour`. The foreground will then remain that colour until changed again.
If you want to change the foreground colour, you can set `msg.payload` to a
comma separated string of `html_colour,length` or `length,html_colour`. The
foreground will then remain that colour until changed again.
#### Needle
It can also display a needle (single pixel) type gauge.
The rest of the pixels are set to the background colour on one side, and the foreground colour on the other side of the indicated pixel.
If you want to change the needle colour, you can set **msg.payload** to a
If you want to change the needle colour, you can set `msg.payload` to a
comma separated string of `html_colour,length` or `length,html_colour`.
#### Shift left and Shift right
You can also select shift modes where a single colour pixel is added to either
the start or the end of the strip, shifting all the others along by one. In this mode the `msg.payload` can be specified as either an html colour name, an r,g,b triple or #rrggbb.
the start or the end of the strip, shifting all the others along by one. In this
mode the `msg.payload` can be specified as either an html colour name, an r,g,b triple or #rrggbb.
#### Low level "API"
The `nth` pixel of the string can be set by **msg.payload** with a CSV string `n,r,g,b` ,
The `nth` pixel of the string can be set by `msg.payload` with a CSV string `n,r,g,b` ,
where r, g and b are 0-255.
A range of pixels from position `x` to `y` can be set by **msg.payload**
A range of pixels from position `x` to `y` can be set by `msg.payload`
with a CSV string `x,y,r,g,b`

View File

@@ -1,6 +1,6 @@
{
"name" : "node-red-node-pi-neopixel",
"version" : "0.0.10",
"version" : "0.0.11",
"description" : "A Node-RED node to output to a neopixel (ws2812) string of LEDS from a Raspberry Pi.",
"dependencies" : {
},