LayerFocus plugin exposes a number of layer-related commands via
Focus, to allow controlling layers from the host side.
Using the plugin¶
To use the plugin, we need to include the header, and let the firmware know we want to use it:
#include <Kaleidoscope.h> #include <Kaleidoscope-FocusSerial.h> #include <Kaleidoscope-LayerFocus.h> KALEIDOSCOPE_INIT_PLUGINS( Focus, LayerFocus );
The plugin provides the following Focus commands:
layer.activate N /
layer.deactivate N /
Activates, deactivates, or queries the state of layer
Moves to layer
N, deactivating all other layers in the process.
Without arguments, display the state of all layers, from lower to higher. Each active layer will be represented by
1, while inactive layers will be represented by
With arguments, override the state of layers with the