|
3815 | 3815 | ] |
3816 | 3816 | ] |
3817 | 3817 | }, |
3818 | | - { |
3819 | | - "id": "f0775525.cf806", |
3820 | | - "type": "ui_multistate_switch", |
3821 | | - "z": "bccd1f23.87219", |
3822 | | - "name": "light_control", |
3823 | | - "group": "4248342d.e55fac", |
3824 | | - "order": 1, |
3825 | | - "width": 6, |
3826 | | - "height": 1, |
3827 | | - "label": "Light ", |
3828 | | - "stateField": "payload", |
3829 | | - "enableField": "enable", |
3830 | | - "passthroughField": "passthrough", |
3831 | | - "inputMsgField": "inputmsg", |
3832 | | - "rounded": true, |
3833 | | - "useThemeColors": true, |
3834 | | - "hideSelectedLabel": false, |
3835 | | - "multilineLabel": false, |
3836 | | - "passThrough": "never", |
3837 | | - "inputMsg": "all", |
3838 | | - "userInput": "enabled_show", |
3839 | | - "options": [ |
3840 | | - { |
3841 | | - "label": "Off", |
3842 | | - "value": "off", |
3843 | | - "valueType": "str", |
3844 | | - "color": "#009933" |
3845 | | - }, |
3846 | | - { |
3847 | | - "label": "On", |
3848 | | - "value": "on", |
3849 | | - "valueType": "str", |
3850 | | - "color": "#999999" |
3851 | | - } |
3852 | | - ], |
3853 | | - "topic": "", |
3854 | | - "x": 350, |
3855 | | - "y": 160, |
3856 | | - "wires": [ |
3857 | | - [ |
3858 | | - "99ae4886.8d43c" |
3859 | | - ] |
3860 | | - ] |
3861 | | - }, |
3862 | | - { |
3863 | | - "id": "99ae4886.8d43c", |
3864 | | - "type": "function", |
3865 | | - "z": "bccd1f23.87219", |
3866 | | - "name": "Prepare message", |
3867 | | - "func": "msg.topic = \"light\"\nmsg.payload = {\"action\":msg.payload}\n\nreturn msg;", |
3868 | | - "outputs": 1, |
3869 | | - "timeout": "", |
3870 | | - "noerr": 0, |
3871 | | - "initialize": "", |
3872 | | - "finalize": "", |
3873 | | - "libs": [], |
3874 | | - "x": 530, |
3875 | | - "y": 160, |
3876 | | - "wires": [ |
3877 | | - [ |
3878 | | - "d31fcead.7e2ef" |
3879 | | - ] |
3880 | | - ] |
3881 | | - }, |
3882 | | - { |
3883 | | - "id": "d31fcead.7e2ef", |
3884 | | - "type": "mqtt out", |
3885 | | - "z": "bccd1f23.87219", |
3886 | | - "name": "", |
3887 | | - "topic": "", |
3888 | | - "qos": "", |
3889 | | - "retain": "", |
3890 | | - "respTopic": "", |
3891 | | - "contentType": "", |
3892 | | - "userProps": "", |
3893 | | - "correl": "", |
3894 | | - "expiry": "", |
3895 | | - "broker": "8dc3722c.06efa8", |
3896 | | - "x": 690, |
3897 | | - "y": 160, |
3898 | | - "wires": [] |
3899 | | - }, |
3900 | 3818 | { |
3901 | 3819 | "id": "8ea9dc9a.c7d87", |
3902 | 3820 | "type": "function", |
|
4705 | 4623 | ] |
4706 | 4624 | ] |
4707 | 4625 | }, |
4708 | | - { |
4709 | | - "id": "ac2b9d1604a13a35", |
4710 | | - "type": "function", |
4711 | | - "z": "bccd1f23.87219", |
4712 | | - "name": "Set Led Status", |
4713 | | - "func": "msg.payload = msg.payload.status.toLowerCase();\n\nreturn msg;", |
4714 | | - "outputs": 1, |
4715 | | - "timeout": 0, |
4716 | | - "noerr": 0, |
4717 | | - "initialize": "", |
4718 | | - "finalize": "", |
4719 | | - "libs": [], |
4720 | | - "x": 160, |
4721 | | - "y": 160, |
4722 | | - "wires": [ |
4723 | | - [ |
4724 | | - "f0775525.cf806" |
4725 | | - ] |
4726 | | - ] |
4727 | | - }, |
4728 | 4626 | { |
4729 | 4627 | "id": "310ee70930b17fae", |
4730 | 4628 | "type": "mqtt in", |
4731 | 4629 | "z": "bccd1f23.87219", |
4732 | 4630 | "name": "", |
4733 | | - "topic": "status/#", |
| 4631 | + "topic": "status/light", |
4734 | 4632 | "qos": "0", |
4735 | 4633 | "datatype": "json", |
4736 | 4634 | "broker": "8dc3722c.06efa8", |
4737 | 4635 | "nl": false, |
4738 | 4636 | "rap": false, |
4739 | 4637 | "inputs": 0, |
4740 | | - "x": 1470, |
| 4638 | + "x": 1480, |
4741 | 4639 | "y": 180, |
4742 | 4640 | "wires": [ |
4743 | 4641 | [ |
|
4753 | 4651 | "property": "payload", |
4754 | 4652 | "action": "obj", |
4755 | 4653 | "pretty": true, |
4756 | | - "x": 1610, |
| 4654 | + "x": 1630, |
4757 | 4655 | "y": 180, |
4758 | 4656 | "wires": [ |
4759 | 4657 | [ |
|
4810 | 4708 | "type": "function", |
4811 | 4709 | "z": "bccd1f23.87219", |
4812 | 4710 | "name": "Prepare message", |
4813 | | - "func": "msg.topic = \"light\"\nmsg.payload = {\"action\":msg.payload}\n\nreturn msg;", |
| 4711 | + "func": "msg.topic = \"light\"\nmsg.payload = {\"action\": msg.payload}\n\nreturn msg;", |
4814 | 4712 | "outputs": 1, |
4815 | 4713 | "timeout": "", |
4816 | 4714 | "noerr": 0, |
|
0 commit comments