You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+2Lines changed: 2 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -19,6 +19,7 @@ We are using a custom object, named `LedRGB`. Next, we need to declare a new obj
19
19
### Functions in the library
20
20
21
21
-`setColor(redValue, greenValue, blueValue);` sets the values from 0 to 255 for each of the three colors.
22
+
-`defaultColor(colorName);` chooses among different color Strings, e.g. `"white"` or `"yellow"`. If the color you write is not supported, the LED will be set to black.
22
23
-`add(addRed, addGreen, addBlue);` adds the specified value to the current one in the LED, up to 255.
23
24
-`substract(subRed, subGreen, subBlue);` substracts the specified value, all the way down to 0.
24
25
-`off();` sets every value to 0.
@@ -41,6 +42,7 @@ El objeto que utilizaremos será de tipo `LedRGB`. A continuación deberemos def
41
42
### Funciones de la librería
42
43
43
44
-`ponerColor(valorRojo, valorVerde, valorAzul);` asigna los valores de 0 a 255 para cada uno de los tres colores.
45
+
-`colorPredefinido(nombreDelColor);` acepta algunos Strings de colores, como `"blanco"` or `"amarillo"`. Si el color que introduces no está en nuestra lista, el LED se pondrá negro.
44
46
-`sumar(sumarRojo, sumarVerde, sumarAzul);` suma el valor dado al valor actual del LED (hasta llegar a 255).
45
47
-`restar(quitarRojo, quitarVerde, quitarAzul);` resta desde el valor al que está puesto el LED (hasta llegar a cero).
0 commit comments