|
|
@ -18,11 +18,14 @@ To use the plugin, include the header, and tell `Kaleidoscope` to use the plugin
|
|
|
|
|
|
|
|
|
|
|
|
```c++
|
|
|
|
```c++
|
|
|
|
#include <Kaleidoscope.h>
|
|
|
|
#include <Kaleidoscope.h>
|
|
|
|
|
|
|
|
#include <Kaleidoscope-LEDControl.h>
|
|
|
|
#include <Kaleidoscope-LEDEffect-BootGreeting.h>
|
|
|
|
#include <Kaleidoscope-LEDEffect-BootGreeting.h>
|
|
|
|
|
|
|
|
|
|
|
|
void setup() {
|
|
|
|
KALEIDOSCOPE_INIT_PLUGINS(LEDControl,
|
|
|
|
Kaleidoscope.use(&BootGreetingEffect, &LEDOff);
|
|
|
|
BootGreetingEffect
|
|
|
|
|
|
|
|
LEDOff);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
void setup() {
|
|
|
|
Kaleidoscope.setup();
|
|
|
|
Kaleidoscope.setup();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
```
|
|
|
|
```
|
|
|
@ -32,55 +35,69 @@ You may also set optional parameters.
|
|
|
|
### Specify by search key
|
|
|
|
### Specify by search key
|
|
|
|
```c++
|
|
|
|
```c++
|
|
|
|
#include <Kaleidoscope.h>
|
|
|
|
#include <Kaleidoscope.h>
|
|
|
|
|
|
|
|
#include <Kaleidoscope-LEDControl.h>
|
|
|
|
#include <Kaleidoscope-LEDEffect-BootGreeting.h>
|
|
|
|
#include <Kaleidoscope-LEDEffect-BootGreeting.h>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
KALEIDOSCOPE_INIT_PLUGINS(LEDControl,
|
|
|
|
|
|
|
|
BootGreetingEffect
|
|
|
|
|
|
|
|
LEDOff);
|
|
|
|
|
|
|
|
|
|
|
|
void setup() {
|
|
|
|
void setup() {
|
|
|
|
Kaleidoscope.use(&BootGreetingEffect, &LEDOff);
|
|
|
|
Kaleidoscope.setup();
|
|
|
|
|
|
|
|
|
|
|
|
BootGreetingEffect.search_key = Key_M;
|
|
|
|
BootGreetingEffect.search_key = Key_M;
|
|
|
|
|
|
|
|
|
|
|
|
Kaleidoscope.setup();
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
```
|
|
|
|
```
|
|
|
|
|
|
|
|
|
|
|
|
### Specify by position
|
|
|
|
### Specify by position
|
|
|
|
```c++
|
|
|
|
```c++
|
|
|
|
#include <Kaleidoscope.h>
|
|
|
|
#include <Kaleidoscope.h>
|
|
|
|
|
|
|
|
#include <Kaleidoscope-LEDControl.h>
|
|
|
|
#include <Kaleidoscope-LEDEffect-BootGreeting.h>
|
|
|
|
#include <Kaleidoscope-LEDEffect-BootGreeting.h>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
KALEIDOSCOPE_INIT_PLUGINS(LEDControl,
|
|
|
|
|
|
|
|
BootGreetingEffect
|
|
|
|
|
|
|
|
LEDOff);
|
|
|
|
|
|
|
|
|
|
|
|
void setup() {
|
|
|
|
void setup() {
|
|
|
|
Kaleidoscope.use(&BootGreetingEffect, &LEDOff);
|
|
|
|
Kaleidoscope.setup();
|
|
|
|
|
|
|
|
|
|
|
|
//Butterfly key
|
|
|
|
//Butterfly key
|
|
|
|
BootGreetingEffect.key_col = 7;
|
|
|
|
BootGreetingEffect.key_col = 7;
|
|
|
|
BootGreetingEffect.key_row = 3;
|
|
|
|
BootGreetingEffect.key_row = 3;
|
|
|
|
|
|
|
|
|
|
|
|
Kaleidoscope.setup();
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
```
|
|
|
|
```
|
|
|
|
|
|
|
|
|
|
|
|
### Specify longer timeout
|
|
|
|
### Specify longer timeout
|
|
|
|
```c++
|
|
|
|
```c++
|
|
|
|
#include <Kaleidoscope.h>
|
|
|
|
#include <Kaleidoscope.h>
|
|
|
|
|
|
|
|
#include <Kaleidoscope-LEDControl.h>
|
|
|
|
#include <Kaleidoscope-LEDEffect-BootGreeting.h>
|
|
|
|
#include <Kaleidoscope-LEDEffect-BootGreeting.h>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
KALEIDOSCOPE_INIT_PLUGINS(LEDControl,
|
|
|
|
|
|
|
|
BootGreetingEffect
|
|
|
|
|
|
|
|
LEDOff);
|
|
|
|
|
|
|
|
|
|
|
|
void setup() {
|
|
|
|
void setup() {
|
|
|
|
Kaleidoscope.use(&BootGreetingEffect, &LEDOff);
|
|
|
|
Kaleidoscope.setup();
|
|
|
|
|
|
|
|
|
|
|
|
//Butterfly key
|
|
|
|
//Butterfly key
|
|
|
|
BootGreetingEffect.timeout = 15000;
|
|
|
|
BootGreetingEffect.timeout = 15000;
|
|
|
|
|
|
|
|
|
|
|
|
Kaleidoscope.setup();
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
```
|
|
|
|
```
|
|
|
|
|
|
|
|
|
|
|
|
### Specify different color
|
|
|
|
### Specify different color
|
|
|
|
```c++
|
|
|
|
```c++
|
|
|
|
#include <Kaleidoscope.h>
|
|
|
|
#include <Kaleidoscope.h>
|
|
|
|
|
|
|
|
#include <Kaleidoscope-LEDControl.h>
|
|
|
|
#include <Kaleidoscope-LEDEffect-BootGreeting.h>
|
|
|
|
#include <Kaleidoscope-LEDEffect-BootGreeting.h>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
KALEIDOSCOPE_INIT_PLUGINS(LEDControl,
|
|
|
|
|
|
|
|
BootGreetingEffect
|
|
|
|
|
|
|
|
LEDOff);
|
|
|
|
|
|
|
|
|
|
|
|
void setup() {
|
|
|
|
void setup() {
|
|
|
|
Kaleidoscope.use(&BootGreetingEffect, &LEDOff);
|
|
|
|
Kaleidoscope.setup();
|
|
|
|
|
|
|
|
|
|
|
|
//Butterfly key
|
|
|
|
//Butterfly key
|
|
|
|
BootGreetingEffect.hue = 90;
|
|
|
|
BootGreetingEffect.hue = 90;
|
|
|
|