This module serves as an example for module maintainers to implement their own modules outside reserved range of modules and does not serve any role in the production environment. For usage of this module, see the README.
The module number/ID: 1000.
| Device Name | Device Type | Device Roles | Comment |
|---|---|---|---|
| button1 | 0 | test | Button driving a state of a dedicated LED |
| button1 | 10 | test | Button driving a state of a dedicated LED |
| button2 | 0 | test2 | Button driving a state of a dedicated LED |
Each device (button) expects a status message containing a single key pressed with a boolean value indicating whether the button is pressed.
{
"pressed": true
}Status errors are not defined for this module.
Each device (button) expects a command message containing a single key lit_up with a boolean value indicating whether the LED should be lit up.
{
"lit_up": true
}Button is a simple button device which has one LED attached to it. As status, it sends JSON with key "pressed" indicating whether button is pressed. As command, it expects JSON with key "lit_up" indicating the desired state of internal LED.
See the state transition diagram below:
