mirror of
https://github.com/letscontrolit/ESPEasy.git
synced 2026-07-28 04:07:47 +00:00
Merge pull request #2129 from Grovkillen/DocumentationUpdate
[docs] look and feel (headlines css) + P001 hardware + script for screenshots of GUI
This commit is contained in:
@@ -0,0 +1,22 @@
|
||||
These scripts are used to render screenshots of the GUI.
|
||||
We use phantomJS (available on Win/Mac/Linux http://phantomjs.org/quick-start.html)
|
||||
and you control the script by passing arguments to the JavaScript files:
|
||||
|
||||
########## rasterize.js ##########
|
||||
argument1: url (ampersand & need to be closed with "&")
|
||||
argument2: output file name (you can use .png or .pdf as output format)
|
||||
argument3: horisontalXvertical size (OPTIONAL)
|
||||
argument4: zoom ("entire page" or "window" or <value> OPTIONAL)
|
||||
....Example CLI....
|
||||
|
||||
phantomjs rasterize.js http://95.143.204.227/devices?index=1"&"page=1 P001_Setup_Switch_1.png
|
||||
|
||||
or
|
||||
|
||||
phantomjs rasterize.js http://95.143.204.227/devices?index=1"&"page=1 P001_Setup_Switch_1.png 1200px 2
|
||||
|
||||
WE USE THE SECOND EXAMPLE by default (you might need to change zoomFactor if the page is too big).
|
||||
|
||||
If the rendering is not working you can use this CLI (arg --debug=true):
|
||||
|
||||
phantomjs --debug=true rasterize.js http://95.143.204.227/devices?index=1"&"page=1 P001_Setup_Switch_1.png 1200px 2
|
||||
@@ -0,0 +1,52 @@
|
||||
//removed use strict GROVKILLEN
|
||||
var page = require('webpage').create(),
|
||||
system = require('system'),
|
||||
address, output, size;
|
||||
|
||||
if (system.args.length < 3 || system.args.length > 5) {
|
||||
console.log('Usage: rasterize.js URL filename [paperwidth*paperheight|paperformat] [zoom]');
|
||||
console.log(' image (png/jpg output) examples: "1920px" entire page, window width 1920px');
|
||||
console.log(' "800px*600px" window, clipped to 800x600');
|
||||
phantom.exit(1);
|
||||
} else {
|
||||
address = system.args[1];
|
||||
output = system.args[2];
|
||||
page.viewportSize = { width: 600, height: 600 };
|
||||
if (system.args.length > 3 && system.args[2].substr(-4) === ".pdf") {
|
||||
size = system.args[3].split('*');
|
||||
page.paperSize = size.length === 2 ? { width: size[0], height: size[1], margin: '0px' }
|
||||
: { format: system.args[3], orientation: 'portrait', margin: '1cm' };
|
||||
} else if (system.args.length > 3 && system.args[3].substr(-2) === "px") {
|
||||
size = system.args[3].split('*');
|
||||
if (size.length === 2) {
|
||||
pageWidth = parseInt(size[0], 10);
|
||||
pageHeight = parseInt(size[1], 10);
|
||||
page.viewportSize = { width: pageWidth, height: pageHeight };
|
||||
page.clipRect = { top: 0, left: 0, width: pageWidth, height: pageHeight };
|
||||
} else {
|
||||
console.log("size:", system.args[3]);
|
||||
pageWidth = parseInt(system.args[3], 10);
|
||||
pageHeight = parseInt(pageWidth * 3/4, 10); // it's as good an assumption as any
|
||||
console.log ("pageHeight:",pageHeight);
|
||||
page.viewportSize = { width: pageWidth, height: pageHeight };
|
||||
}
|
||||
}
|
||||
if (system.args.length > 4) {
|
||||
page.zoomFactor = system.args[4];
|
||||
}
|
||||
page.open(address, function (status) {
|
||||
if (status !== 'success') {
|
||||
console.log('Unable to load the address!');
|
||||
phantom.exit(1);
|
||||
} else {
|
||||
window.setTimeout(function () {
|
||||
//This is injected because of bug in phantomjs (rendering black background: http://phantomjs.org/tips-and-tricks.html) GROVKILLEN
|
||||
page.evaluate(function() {
|
||||
document.body.bgColor = 'white';
|
||||
});
|
||||
page.render(output);
|
||||
phantom.exit();
|
||||
}, 200);
|
||||
}
|
||||
});
|
||||
}
|
||||
@@ -89,7 +89,7 @@ No device is needed.
|
||||
Commands
|
||||
--------
|
||||
|
||||
.. include:: P001_commands_RTTTL.rst
|
||||
.. include:: P001_commands_RTTTL.repl
|
||||
|
||||
Where to buy
|
||||
------------
|
||||
|
||||
@@ -86,7 +86,7 @@ No device is needed.
|
||||
Commands
|
||||
--------
|
||||
|
||||
.. include:: P001_commands_RTTTL.rst
|
||||
.. include:: P001_commands_RTTTL.repl
|
||||
|
||||
Where to buy
|
||||
------------
|
||||
|
||||
@@ -19,6 +19,8 @@ You may use it by simply connect it to either a GPIO that is normally high (pull
|
||||
|
||||
Specifications:
|
||||
* Give a high or low signal to a GPIO
|
||||
* Power needed: 3.3V (typically)
|
||||
* Output voltage: same as input (typically)
|
||||
|
||||
Wiring
|
||||
------
|
||||
@@ -37,7 +39,73 @@ Wiring
|
||||
Setup
|
||||
-----
|
||||
|
||||
Selecting the plugin "Switch input - Switch" gives you the options to setup a switch.
|
||||
.. image:: P001_Setup_Door_switch_1.png
|
||||
|
||||
Task settings
|
||||
~~~~~~~~~~~~~
|
||||
|
||||
* **Device**: Name of plugin
|
||||
* **Name**: Name of the task (example name **Door**)
|
||||
* **Enable**: Should the task be enabled or not
|
||||
|
||||
Sensor
|
||||
^^^^^^
|
||||
|
||||
* **Internal pull-up**: Check if you want to use the internal pull-up of the ESP (not all GPIO pins have this internal pull-up.)
|
||||
* **Inverse logic**: Sometimes you may want the physical high value to be published as a low value. For example if the button is
|
||||
triggering a high (1) value when you push it you maybe use it to turn of a LED so the :code:`Switch#State` would then logically be
|
||||
preferred to be set as 0 and thus used as a variable for controlling that LED. See rules example below.
|
||||
|
||||
* **GPIO**: Which GPIO should be used, recommended to not use a latching switch that may set the ESP into flash mode if left
|
||||
to high/low.
|
||||
|
||||
* **Switch type**: Set the switch type to either "Switch" or "Dimmer". Door (reed) switch is a "Switch".
|
||||
|
||||
* Switch: The default way of handling a switch is by a on/off button. It's either on (:code:`1`) or off (:code:`0`).
|
||||
|
||||
* Dimmer: Not used by door (reed) switches, if you still want to use it you can have a look at the
|
||||
:ref:`P001_Switch_page` page.
|
||||
|
||||
* **Switch button type**: Set the type of switch, "Normal switch", "Push button active low", or "Push button active high".
|
||||
* Normal switch: This is the general setting to use for a PIR switch.
|
||||
|
||||
* Push button active low: Not used by door (reed) switches (in general), if you still want to use it you can have a look at the
|
||||
:ref:`P001_Switch_page` page.
|
||||
|
||||
* **Send boot state**: If checked the unit will publish the switch state when booting. If not checked you may find yourself
|
||||
with a latching switch caught in limbo. This means that the unit is registering a low/high value but the physical state of
|
||||
the switch might be the opposite. If you use a mechanical switch that may be physically set to a state you should check this
|
||||
option.
|
||||
|
||||
Advanced event management
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
* **De-bounce (ms)**: How long should the pulse (the time you press the button) be, if set to high you need to have it published
|
||||
for a longer time before the unit will register it as an state change. You could experiment with this setting to find a good
|
||||
behavior of the button if you feel that it's not responding according to your preferences.
|
||||
|
||||
* **Double click event**: Not used by door (reed) switches (in general), if you still want to use it you can have a look at the
|
||||
:ref:`P001_Switch_page` page.
|
||||
|
||||
* **Double click max interval (ms)**: Same as above..
|
||||
* **Long press event**: Same as above..
|
||||
* **Long press min interval (ms)**: Same as above..
|
||||
* **Use safe button (slower)**: Same as above..
|
||||
|
||||
Data acquisition
|
||||
^^^^^^^^^^^^^^^^
|
||||
|
||||
* **Send to controller** 1..3: Check which controller (if any) you want to publish to. All or no controller can be used.
|
||||
* **Interval**: How often should the task publish its value (optional for switch plugins).
|
||||
|
||||
Indicators/values (recommended settings)
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
.. csv-table::
|
||||
:header: "Indicator", "Value Name", "Interval", "Decimals", "Extra information"
|
||||
:widths: 8, 5, 5, 5, 40
|
||||
|
||||
"State", "State", "0", "N/A", "Usually you just want the state being published when door is actually being opened/closed. If you want a continuous publishing of the state you may use the interval setting to do so."
|
||||
|
||||
|
||||
Rules examples
|
||||
@@ -58,15 +126,6 @@ Rules examples
|
||||
endon
|
||||
|
||||
|
||||
Indicators (recommended settings)
|
||||
---------------------------------
|
||||
|
||||
.. csv-table::
|
||||
:header: "Indicator", "Value Name", "Interval", "Decimals", "Extra information"
|
||||
:widths: 8, 5, 5, 5, 40
|
||||
|
||||
"XXXXXX", "N/A", "", "", ""
|
||||
|
||||
Where to buy
|
||||
------------
|
||||
|
||||
@@ -74,11 +133,11 @@ Where to buy
|
||||
:header: "Type", "Link"
|
||||
:widths: 5, 40
|
||||
|
||||
"Door switch","`AliExpress 1 ($) <http://s.click.aliexpress.com/e/ccCdXCVi>`_"
|
||||
"Reed switch","`AliExpress 2 ($) <http://s.click.aliexpress.com/e/0gMmOoY>`_"
|
||||
"Door switch","`AliExpress 1 ($) <http://s.click.aliexpress.com/e/ccCdXCVi>`_ `Banggood 1 ($) <https://www.banggood.com/search/reed-door.html?p=V3270422659778201806&custlinkid=76099>`_ `eBay 1 ($) <http://rover.ebay.com/rover/1/711-53200-19255-0/1?ff3=4&pub=5575404073&toolid=10001&campid=5338336929&customid=&mpre=https%3A%2F%2Fwww.ebay.com%2Fsch%2Fi.html%3F_odkw%3Ddoor%2Bswitch%26_osacat%3D0%26_from%3DR40%26_trksid%3Dm570.l1313%26_nkw%3Dreed%2Bdoor%26_sacat%3D0>`_"
|
||||
"Reed switch","`AliExpress 2 ($) <http://s.click.aliexpress.com/e/0gMmOoY>`_ `Banggood 2 ($) <https://www.banggood.com/search/reed-switch.html?p=V3270422659778201806&custlinkid=76096>`_ `eBay 2 ($) <http://rover.ebay.com/rover/1/711-53200-19255-0/1?ff3=4&pub=5575404073&toolid=10001&campid=5338336929&customid=&mpre=https%3A%2F%2Fwww.ebay.com%2Fsch%2Fi.html%3F_odkw%3Dreed%2Bdoor%26_osacat%3D0%26_from%3DR40%26_trksid%3Dm570.l1313%26_nkw%3Dreed%2Bswitch%26_sacat%3D0>`_"
|
||||
|
||||
|affiliate|
|
||||
|
||||
|
||||
More pictures
|
||||
-------------
|
||||
.. More pictures
|
||||
.. -------------
|
||||
|
||||
@@ -7,33 +7,111 @@ PIR sensor
|
||||
|P001_typename|
|
||||
|P001_status|
|
||||
|
||||
.. image:: P001_PIR_sensor_1.jpg
|
||||
|
||||
Introduction
|
||||
------------
|
||||
|
||||
A big difference from the regular tactile buttons and a PIR is that a PIR will output a high or low Signal
|
||||
without someone actually pushing a physical button. The PIR uses a pyro detector which will detect change
|
||||
in radiated heat. A person or an animal is always radiating some level of heat and when someone enters
|
||||
the vision of the PIR the amount of heat will change and the PIR will trigger a signal.
|
||||
|
||||
Specifications:
|
||||
* Motion (change in heat)
|
||||
* Power needed: 5V (typically)
|
||||
* Output voltage: 3.3V (typically)
|
||||
|
||||
.. note::
|
||||
Some PIR sensor boards have a jumper which will allow you to have the unit send a single pulse when
|
||||
the motion is detected or send a single repeatedly as long as motion is detected. Good boards also
|
||||
have a sensitivity adjustment and time delay setting which lets you tweak the way the unit is behaving,
|
||||
that could be really helpful if the default settings are triggering too much or not enough.
|
||||
|
||||
Wiring
|
||||
------
|
||||
|
||||
|
||||
.. code-block:: html
|
||||
|
||||
ESP PIR
|
||||
GPIO (X) <--> Signal
|
||||
GPIO (X) <--> I/O or OUT
|
||||
|
||||
Power
|
||||
3.3V <--> Signal
|
||||
or
|
||||
GND <--> Signal
|
||||
5V <--> VCC
|
||||
GND <--> GND
|
||||
|
||||
|
||||
Setup
|
||||
-----
|
||||
|
||||
.. image:: P001_Setup_PIR_sensor_1.png
|
||||
|
||||
Task settings
|
||||
~~~~~~~~~~~~~
|
||||
|
||||
* **Device**: Name of plugin
|
||||
* **Name**: Name of the task (example name **Motion**)
|
||||
* **Enable**: Should the task be enabled or not
|
||||
|
||||
Sensor
|
||||
^^^^^^
|
||||
|
||||
* **Internal pull-up**: Check if you want to use the internal pull-up of the ESP (not all GPIO pins have this internal pull-up.)
|
||||
* **Inverse logic**: Sometimes you may want the physical high value to be published as a low value. For example if the button is
|
||||
triggering a high (1) value when you push it you maybe use it to turn of a LED so the :code:`Switch#State` would then logically be
|
||||
preferred to be set as 0 and thus used as a variable for controlling that LED. See rules example below.
|
||||
|
||||
* **GPIO**: Which GPIO should be used, recommended to not use a latching switch that may set the ESP into flash mode if left
|
||||
to high/low.
|
||||
|
||||
* **Switch type**: Set the switch type to either "Switch" or "Dimmer". PIR is a "Switch".
|
||||
|
||||
* Switch: The default way of handling a switch is by a on/off button. It's either on (:code:`1`) or off (:code:`0`).
|
||||
|
||||
* Dimmer: Not used by PIR switches, if you still want to use it you can have a look at the
|
||||
:ref:`P001_Switch_page` page.
|
||||
|
||||
|
||||
* **Switch button type**: Set the type of switch, "Normal switch", "Push button active low", or "Push button active high".
|
||||
* Normal switch: This is the general setting to use for a door (reed) switch.
|
||||
|
||||
* Push button active low: Not used by PIR switches (in general), if you still want to use it you can have a look at the
|
||||
:ref:`P001_Switch_page` page.
|
||||
|
||||
* **Send boot state**: If checked the unit will publish the switch state when booting. If not checked you may find yourself
|
||||
with a latching switch caught in limbo. This means that the unit is registering a low/high value but the physical state of
|
||||
the switch might be the opposite. If you use a mechanical switch that may be physically set to a state you should check this
|
||||
option.
|
||||
|
||||
Advanced event management
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
* **De-bounce (ms)**: How long should the pulse (the time you press the button) be, if set to high you need to have it published
|
||||
for a longer time before the unit will register it as an state change. You could experiment with this setting to find a good
|
||||
behavior of the button if you feel that it's not responding according to your preferences.
|
||||
|
||||
* **Double click event**: Not used by PIR switches (in general), if you still want to use it you can have a look at the
|
||||
:ref:`P001_Switch_page` page.
|
||||
|
||||
* **Double click max interval (ms)**: Same as above..
|
||||
* **Long press event**: Same as above..
|
||||
* **Long press min interval (ms)**: Same as above..
|
||||
* **Use safe button (slower)**: Same as above..
|
||||
|
||||
Data acquisition
|
||||
^^^^^^^^^^^^^^^^
|
||||
|
||||
* **Send to controller** 1..3: Check which controller (if any) you want to publish to. All or no controller can be used.
|
||||
* **Interval**: How often should the task publish its value (optional for switch plugins).
|
||||
|
||||
Indicators/values (recommended settings)
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
.. csv-table::
|
||||
:header: "Indicator", "Value Name", "Interval", "Decimals", "Extra information"
|
||||
:widths: 8, 5, 5, 5, 40
|
||||
|
||||
"State", "Detection", "0", "N/A", "Usually you just want the state being published when door is actually being opened/closed. If you want a continuous publishing of the state you may use the interval setting to do so."
|
||||
|
||||
|
||||
Rules examples
|
||||
@@ -41,17 +119,18 @@ Rules examples
|
||||
|
||||
.. code-block:: html
|
||||
|
||||
//Code below...
|
||||
on Motion#Detection=1 do
|
||||
timerSet,1,1
|
||||
endon
|
||||
|
||||
on rules#timer=1 do
|
||||
if [Motion#Detection]=0
|
||||
//Action if NO motion is detected
|
||||
else
|
||||
//Action if motion is detected
|
||||
endif
|
||||
endon
|
||||
|
||||
Indicators (recommended settings)
|
||||
---------------------------------
|
||||
|
||||
.. csv-table::
|
||||
:header: "Indicator", "Value Name", "Interval", "Decimals", "Extra information"
|
||||
:widths: 8, 5, 5, 5, 40
|
||||
|
||||
"XXXXXX", "N/A", "", "", ""
|
||||
|
||||
Where to buy
|
||||
------------
|
||||
@@ -60,7 +139,9 @@ Where to buy
|
||||
:header: "Store", "Link"
|
||||
:widths: 5, 40
|
||||
|
||||
"AliExpress","`Link 1 ($) <http://s.click.aliexpress.com/e/cg1fhDDI>`_"
|
||||
"AliExpress","`Link 1 ($) <http://s.click.aliexpress.com/e/j0xC1UU>`_"
|
||||
"Banggood","`Link 2 ($) <https://www.banggood.com/RobotDyn-5V-PIR-Motion-Sensor-Adjustable-Time-Delay-Sensitive-Module-For-Arduino-p-1244536.html?p=V3270422659778201806>`_"
|
||||
"eBay","`Link 3 ($) <https://rover.ebay.com/rover/1/711-53200-19255-0/1?icep_id=114&ipn=icep&toolid=20004&campid=5338336929&mpre=https%3A%2F%2Fwww.ebay.com%2Fitm%2FNew-HC-SR501-Infrared-PIR-Motion-Sensor-Module-for-Arduino-Raspberry-pi%2F132113984394%3Fepid%3D14013121702%26hash%3Ditem1ec29b6b8a%3Ag%3AkusAAOSwT5xZTInL>`_"
|
||||
|
||||
|affiliate|
|
||||
|
||||
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 128 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 128 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 129 KiB |
@@ -18,11 +18,12 @@ types of switches are door switches (reed switch), sound activated switches and
|
||||
|
||||
Specifications:
|
||||
* Give a high or low signal to a GPIO
|
||||
* Power needed: 3.3V (typically)
|
||||
* Output voltage: same as input (typically)
|
||||
|
||||
Wiring
|
||||
------
|
||||
|
||||
|
||||
.. code-block:: html
|
||||
|
||||
ESP Switch/button
|
||||
@@ -37,35 +38,108 @@ Wiring
|
||||
Setup
|
||||
-----
|
||||
|
||||
.. image:: P001_Setup_Switch_1.png
|
||||
|
||||
Task settings
|
||||
~~~~~~~~~~~~~
|
||||
|
||||
* **Device**: Name of plugin
|
||||
* **Name**: Name of the task (recommended name **SwitchN**, where N is a number)
|
||||
* **Enable**: Should the task be enabled or not
|
||||
|
||||
Sensor
|
||||
^^^^^^
|
||||
|
||||
* **Internal pull-up**: Check if you want to use the internal pull-up of the ESP (not all GPIO pins have this internal pull-up.)
|
||||
* **Inverse logic**: Sometimes you may want the physical high value to be published as a low value. For example if the button is
|
||||
triggering a high (1) value when you push it you maybe use it to turn of a LED so the :code:`Switch#State` would then logically be
|
||||
preferred to be set as 0 and thus used as a variable for controlling that LED. See rules example below.
|
||||
|
||||
* **GPIO**: Which GPIO should be used, recommended to not use a latching switch that may set the ESP into flash mode if left
|
||||
to high/low.
|
||||
|
||||
* **Switch type**: Set the switch type to either "Switch" or "Dimmer". Dimmer is used if you have a knob that can be turned and
|
||||
thus give multiple switch trigger signals.
|
||||
|
||||
* Switch: The default way of handling a switch is by a on/off button. It's either on (:code:`1`) or off (:code:`0`).
|
||||
* Dimmer: If you use the dimmer option you will be able to control the device using a dimmer (knob that can be turned).
|
||||
The value allowed for dimmers are :code:`0..255` and a new setting is added to the web form (Dim value).
|
||||
|
||||
|
||||
* **Switch button type**: Set the type of switch, "Normal switch", "Push button active low", or "Push button active high".
|
||||
* Normal switch: If you use a normal switch you should use this (you can always start with this setting).
|
||||
|
||||
* Push button active low: If you use a momentary switch you may want the state to be activated when you have it published
|
||||
and not wait for it to be released. Depending on your setup you can then experiment with the active low / active high
|
||||
to make it behave as you want.
|
||||
|
||||
* Push button active high: See bullet point above.
|
||||
|
||||
* **Send boot state**: If checked the unit will publish the switch state when booting. If not checked you may find yourself
|
||||
with a latching switch caught in limbo. This means that the unit is registering a low/high value but the physical state of
|
||||
the switch might be the opposite. If you use a mechanical switch that may be physically set to a state you should check this
|
||||
option.
|
||||
|
||||
Advanced event management
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
* **De-bounce (ms)**: How long should the pulse (the time you press the button) be, if set to high you need to have it published
|
||||
for a longer time before the unit will register it as an state change. You could experiment with this setting to find a good
|
||||
behavior of the button if you feel that it's not responding according to your preferences.
|
||||
|
||||
* **Double click event**: If enabled the unit will detect double clicks which are within the set interval (see below). The double
|
||||
click event is identified as :code:`Switch#State=3`. There's three options for the double click:
|
||||
* Active only on low: the double clicks will be counted by how many low signals that is triggered within the set time.
|
||||
* Active only on high: the double clicks will be counted by how many high signals that is triggered within the set time.
|
||||
|
||||
* Active on high & low: the double clicks will be counted by how many high and low signals that is triggered within the set time.
|
||||
This means that a double click could be registered as a press and release of a button. So not actually double click.
|
||||
|
||||
* **Double click max interval (ms)**: This is the interval that you need to perform the double click within.
|
||||
|
||||
* **Long press event**: If enabled the unit will detect a long press of a button. There's three different behaviors of the long press:
|
||||
|
||||
* Active only on low: this means that the unit will only be triggering the long press event if the signal is low. Two different event
|
||||
values are used, :code:`10` if the state goes from 0 to 1 (:code:`Switch#State=10`), and :code:`11` if the state goes
|
||||
from 1 to 0 (:code:`Switch#State=11`).
|
||||
|
||||
* Active only on high: same as above but only triggered on high signal.
|
||||
* Active on high & low: the long press will be triggered both on high and low signals.
|
||||
|
||||
* **Long press min interval (ms)**: This is the interval that you need to press the button before the long press event is triggered.
|
||||
|
||||
* **Use safe button (slower)**:
|
||||
|
||||
Data acquisition
|
||||
^^^^^^^^^^^^^^^^
|
||||
|
||||
* **Send to controller** 1..3: Check which controller (if any) you want to publish to. All or no controller can be used.
|
||||
* **Interval**: How often should the task publish its value (optional for switch plugins).
|
||||
|
||||
Indicators/values (recommended settings)
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
.. csv-table::
|
||||
:header: "Indicator", "Value Name", "Interval", "Decimals", "Extra information"
|
||||
:widths: 8, 5, 5, 5, 40
|
||||
|
||||
"State", "State", "0", "N/A", "Usually you just want the state being published when an actual push has been happening. If you want a continuous publishing of the state you may use the interval setting to do so."
|
||||
|
||||
Rules examples
|
||||
--------------
|
||||
|
||||
.. code-block:: html
|
||||
|
||||
on Button#State=1 do
|
||||
timerSet,1,1
|
||||
endon
|
||||
|
||||
on rules#timer=1 do
|
||||
if [Button#State]=0
|
||||
//Action if button is short pressedbuild
|
||||
on Switch#State do
|
||||
if [Switch#State]=3
|
||||
//double click triggered!
|
||||
GPIO,12,0
|
||||
else
|
||||
//Action if button is still pressed
|
||||
GPIO,2,[Switch#State]
|
||||
GPIO,12,1
|
||||
endif
|
||||
endon
|
||||
|
||||
|
||||
Indicators (recommended settings)
|
||||
---------------------------------
|
||||
|
||||
.. csv-table::
|
||||
:header: "Indicator", "Value Name", "Interval", "Decimals", "Extra information"
|
||||
:widths: 8, 5, 5, 5, 40
|
||||
|
||||
"XXXXXX", "N/A", "", "", ""
|
||||
|
||||
Where to buy
|
||||
------------
|
||||
|
||||
@@ -73,16 +147,15 @@ Where to buy
|
||||
:header: "Store", "Link"
|
||||
:widths: 5, 40
|
||||
|
||||
"Toggle switch","`AliExpress 1 ($) <http://s.click.aliexpress.com/e/fY7OgXO>`_"
|
||||
"Float switch","`AliExpress 2 ($) <http://s.click.aliexpress.com/e/clw6aFEY>`_"
|
||||
"Membrane switch","`AliExpress 3 ($) <http://s.click.aliexpress.com/e/ZkI1ov6>`_"
|
||||
"Capacitive switch","`AliExpress 4 ($) <http://s.click.aliexpress.com/e/cMIem1Nq>`_"
|
||||
"Limit switch","`AliExpress 5 ($) <http://s.click.aliexpress.com/e/bWOekFqo>`_"
|
||||
"Momentary switch","`AliExpress 6 ($) <http://s.click.aliexpress.com/e/bPEYQDfw>`_ `Banggood 1 ($) <https://www.banggood.com/420pcs-14-Types-Momentary-Tact-Tactile-Push-Button-Switch-SMD-Assortment-Kit-Set-p-1154674.html?p=V3270422659778201806>`_ `Banggood 2 ($) <https://www.banggood.com/100-Pcs-Micro-Switch-Tact-Cap-Slim-Cap-Tactile-Push-Button-Switch-Momentary-Tact-p-1277707.html?p=V3270422659778201806>`_ `Banggood 3 ($) <https://www.banggood.com/36V-2A-12mm-Momentary-Push-Button-Switch-LED-Switch-Waterproof-Switch-p-994547.html?p=V3270422659778201806>`_ `eBay ($) <https://rover.ebay.com/rover/1/711-53200-19255-0/1?icep_id=114&ipn=icep&toolid=20004&campid=5338336929&mpre=https%3A%2F%2Fwww.ebay.com%2Fsch%2Fi.html%3F_from%3DR40%26_trksid%3Dm570.l1313%26_nkw%3DMomentary%2Bswitch%26_sacat%3D0%26LH_TitleDesc%3D0%26_osacat%3D0%26_odkw%3DLimit%2Bswitch>`_"
|
||||
"Toggle switch","`AliExpress 1 ($) <http://s.click.aliexpress.com/e/fY7OgXO>`_ `Banggood 1 ($) <https://www.banggood.com/5pcs-12V-Round-Rocker-Toggle-ONOFF-Switch-3-Pins-p-1046835.html?p=V3270422659778201806>`_ `Banggood 2 ($) <https://www.banggood.com/Red-3-Pin-ON-ON-SPDT-Mini-Toggle-Switch-AC-6A125V-3A250V-p-967014.html?p=V3270422659778201806>`_ `eBay 1 ($) <https://rover.ebay.com/rover/1/711-53200-19255-0/1?icep_id=114&ipn=icep&toolid=20004&campid=5338336929&mpre=https%3A%2F%2Fwww.ebay.com%2Fsch%2Fi.html%3F_from%3DR40%26_trksid%3Dm570.l1313%26_nkw%3Dtoggle%2Bswitch%26_sacat%3D0%26LH_TitleDesc%3D0%26_osacat%3D0%26_odkw%3DMomentary%2Bswitch>`_"
|
||||
"Float switch","`AliExpress 2 ($) <http://s.click.aliexpress.com/e/clw6aFEY>`_ `Banggood 3 ($) <https://www.banggood.com/10W-Black-Side-Mount-Water-Level-Sensor-Controller-Liquid-Float-Switch-p-961256.html?p=V3270422659778201806>`_ `Banggood 4 ($) <https://www.banggood.com/Side-mounted-Liquid-Water-Level-Sensor-Right-Angle-Float-Switch-p-945298.html?p=V3270422659778201806>`_ `eBay 2 ($) <https://rover.ebay.com/rover/1/711-53200-19255-0/1?icep_id=114&ipn=icep&toolid=20004&campid=5338336929&mpre=https%3A%2F%2Fwww.ebay.com%2Fsch%2Fi.html%3F_from%3DR40%26_trksid%3Dm570.l1313%26_nkw%3DFloat%2Bswitch%26_sacat%3D0%26LH_TitleDesc%3D0%26_osacat%3D0%26_odkw%3DMembrane%2Bswitch>`_"
|
||||
"Membrane switch","`AliExpress 3 ($) <http://s.click.aliexpress.com/e/ZkI1ov6>`_ `Banggood 5 ($) <https://www.banggood.com/4-x-3-Matrix-12-Key-Array-Membrane-Switch-Keypad-Keyboard-For-Arduino-p-87370.html?p=V3270422659778201806>`_ `Banggood 6 ($) <https://www.banggood.com/5Pcs-DC-4-Key-Matrix-Membrane-Switch-Control-Keypad-Keyboard-With-LED-p-965091.html?p=V3270422659778201806>`_ `eBay 3 ($) <https://rover.ebay.com/rover/1/711-53200-19255-0/1?icep_id=114&ipn=icep&toolid=20004&campid=5338336929&mpre=https%3A%2F%2Fwww.ebay.com%2Fsch%2Fi.html%3F_from%3DR40%26_trksid%3Dm570.l1313%26_nkw%3DMembrane%2Bswitch%26_sacat%3D0%26LH_TitleDesc%3D0%26_osacat%3D0%26_odkw%3DCapacitive%2Btouch%2Bswitch>`_"
|
||||
"Capacitive (touch) switch","`AliExpress 4 ($) <http://s.click.aliexpress.com/e/cMIem1Nq>`_ `Banggood 7 ($) <https://www.banggood.com/TTP223B-Digital-Touch-Sensor-Capacitive-Touch-Switch-Module-For-Arduino-p-1158322.html?p=V3270422659778201806>`_ `Banggood 8 ($) <https://www.banggood.com/Jog-Type-Touch-Sensor-Module-Capacitive-Touch-Switch-Module-p-916212.html?p=V3270422659778201806>`_ `Banggood 9 ($) <https://www.banggood.com/2_7V-6V-HTTM-Series-Capacitive-Touch-Switch-Button-Module-p-1245166.html?p=V3270422659778201806>`_ `eBay 4 ($) <https://rover.ebay.com/rover/1/711-53200-19255-0/1?icep_id=114&ipn=icep&toolid=20004&campid=5338336929&mpre=https%3A%2F%2Fwww.ebay.com%2Fsch%2Fi.html%3F_from%3DR40%26_trksid%3Dm570.l1313%26_nkw%3DCapacitive%2Btouch%2Bswitch%26_sacat%3D0>`_"
|
||||
"Limit switch","`AliExpress 5 ($) <http://s.click.aliexpress.com/e/bWOekFqo>`_ `Banggood 10 ($) <https://www.banggood.com/10Pcs-Micro-Limit-Switch-Roller-Lever-5A-125V-Open-Close-Switch-p-945733.html?p=V3270422659778201806>`_ `Banggood 11 ($) <https://www.banggood.com/10-Types-250VAC-Limit-Switch-IP65-Adjustable-Actuator-Roller-Arm-Rod-Spring-Coil-Endstop-Switch-p-1297617.html?p=V3270422659778201806>`_ `eBay 5 ($) <https://rover.ebay.com/rover/1/711-53200-19255-0/1?icep_id=114&ipn=icep&toolid=20004&campid=5338336929&mpre=https%3A%2F%2Fwww.ebay.com%2Fsch%2Fi.html%3F_from%3DR40%26_trksid%3Dm570.l1313%26_nkw%3DLimit%2Bswitch%26_sacat%3D0%26LH_TitleDesc%3D0%26_osacat%3D0%26_odkw%3DMagnetic%2Breed%2Bswitch>`_"
|
||||
"Momentary switch","`AliExpress 6 ($) <http://s.click.aliexpress.com/e/bPEYQDfw>`_ `Banggood 12 ($) <https://www.banggood.com/420pcs-14-Types-Momentary-Tact-Tactile-Push-Button-Switch-SMD-Assortment-Kit-Set-p-1154674.html?p=V3270422659778201806>`_ `Banggood 13 ($) <https://www.banggood.com/100-Pcs-Micro-Switch-Tact-Cap-Slim-Cap-Tactile-Push-Button-Switch-Momentary-Tact-p-1277707.html?p=V3270422659778201806>`_ `Banggood 14 ($) <https://www.banggood.com/36V-2A-12mm-Momentary-Push-Button-Switch-LED-Switch-Waterproof-Switch-p-994547.html?p=V3270422659778201806>`_ `eBay 6 ($) <https://rover.ebay.com/rover/1/711-53200-19255-0/1?icep_id=114&ipn=icep&toolid=20004&campid=5338336929&mpre=https%3A%2F%2Fwww.ebay.com%2Fsch%2Fi.html%3F_from%3DR40%26_trksid%3Dm570.l1313%26_nkw%3DMomentary%2Bswitch%26_sacat%3D0%26LH_TitleDesc%3D0%26_osacat%3D0%26_odkw%3DLimit%2Bswitch>`_"
|
||||
|
||||
|
||||
|affiliate|
|
||||
|
||||
|
||||
More pictures
|
||||
-------------
|
||||
.. More pictures
|
||||
.. -------------
|
||||
|
||||
@@ -48,13 +48,49 @@ use the Wemos D1 mini as the host of the 5V input to the S8 and connect the Wemo
|
||||
Setup
|
||||
-----
|
||||
|
||||
Set up the device according to:
|
||||
.. image:: P052_Setup_S8_1.png
|
||||
|
||||
1st GPIO: :blue:`GPIO-13 (D7)`
|
||||
Task settings
|
||||
~~~~~~~~~~~~~
|
||||
|
||||
2st GPIO: :blue:`GPIO-15 (D8)`
|
||||
* **Device**: Name of plugin
|
||||
* **Name**: Name of the task (example name **CO2**)
|
||||
* **Enable**: Should the task be enabled or not
|
||||
|
||||
Sensor: :blue:`Carbon Dioxide`
|
||||
Sensor
|
||||
^^^^^^
|
||||
|
||||
* **GPIO ← TX**: TX is generally set to **GPIO 13 (D7)**.
|
||||
* **GPIO → RX**: RX is generally set to **GPIO 15 (D8)**.
|
||||
* **Sensor**: Only **Carbond Dioxide** is supported by the S8.
|
||||
|
||||
.. note:: TX GPIO 1 (D10) and RX GPIO 3 (D9) is hardware serial and have been reported to work better for some users over time compared to the
|
||||
bit-banging (soft) serial used over GPIO 13 and 15.
|
||||
|
||||
Data acquisition
|
||||
^^^^^^^^^^^^^^^^
|
||||
|
||||
* **Send to controller** 1..3: Check which controller (if any) you want to publish to. All or no controller can be used.
|
||||
* **Interval**: How often should the task publish its value (5..15 seconds is normal).
|
||||
|
||||
Indicators (recommended settings)
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
.. csv-table::
|
||||
:header: "Indicator", "Value Name", "Interval", "Decimals", "Extra information"
|
||||
:widths: 8, 5, 5, 5, 40
|
||||
|
||||
"Error status", "N/A", "", "", "Used for tSense (K70), K30, K33"
|
||||
"Carbon dioxide", "ppm", "15", "0", ""
|
||||
"Temperature", "N/A", "", "", "Used for tSense (K70), K30, K33"
|
||||
"Humidity", "N/A", "", "", "Used for tSense (K70), K30, K33"
|
||||
"Relay status", "N/A", "", "", "Used for tSense (K70), K30, K33"
|
||||
"Temperature adjustment", "N/A", "", "", "Used for tSense (K70), K30, K33"
|
||||
"ABC period", "N/A", "", "", "Used for tSense (K70), K30, K33"
|
||||
|
||||
.. note:: If you want to use the relative carbon dioxide percentage (2000ppm = 100% and 350ppm = 0%) you should use this
|
||||
:code:`100-(2000-%value%)/(2000-350)*100` as a formula. And instead of :code:`ppm` as value name you should use
|
||||
:code:`RCO2` (relative CO2) and 1 decimal.
|
||||
|
||||
Rules examples
|
||||
--------------
|
||||
@@ -67,17 +103,6 @@ Rules examples
|
||||
endif
|
||||
endon
|
||||
|
||||
Indicators (recommended settings)
|
||||
---------------------------------
|
||||
|
||||
.. csv-table::
|
||||
:header: "Indicator", "Value Name", "Interval", "Decimals", "Extra information"
|
||||
:widths: 8, 5, 5, 5, 40
|
||||
|
||||
"Status", "N/A", "", "", ""
|
||||
"Carbon Dioxide", "ppm", "15", "0", ""
|
||||
"Temperature", "N/A", "", "", "Used for tSense (K70), K30, K33"
|
||||
"Humidity", "N/A", "", "", "Used for tSense (K70), K30, K33"
|
||||
|
||||
Where to buy
|
||||
------------
|
||||
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 88 KiB |
@@ -104,122 +104,129 @@ There's three different released versions of ESP Easy:
|
||||
":ref:`P080_page`","|P080_status|","P080"
|
||||
":ref:`P081_page`","|P081_status|","P081"
|
||||
|
||||
|
||||
|
||||
Internal GPIO handling
|
||||
----------------------
|
||||
|
||||
Plugins: :ref:`P000_page`
|
||||
|
||||
Analog input
|
||||
============
|
||||
------------
|
||||
|
||||
Plugins: |Plugin_Analog_input|
|
||||
|
||||
Color
|
||||
=====
|
||||
-----
|
||||
|
||||
Plugins: |Plugin_Color|
|
||||
|
||||
Communication
|
||||
=============
|
||||
-------------
|
||||
|
||||
Plugins: |Plugin_Communication|
|
||||
|
||||
Display
|
||||
=======
|
||||
-------
|
||||
|
||||
Plugins: |Plugin_Display|
|
||||
|
||||
Distance
|
||||
========
|
||||
--------
|
||||
|
||||
Plugins: |Plugin_Distance|
|
||||
|
||||
Dust
|
||||
====
|
||||
----
|
||||
|
||||
Plugins: |Plugin_Dust|
|
||||
|
||||
Energy (AC)
|
||||
===========
|
||||
-----------
|
||||
|
||||
Plugins: |Plugin_Energy_AC|
|
||||
|
||||
Energy (DC)
|
||||
===========
|
||||
-----------
|
||||
|
||||
Plugins: |Plugin_Energy_DC|
|
||||
|
||||
Environment
|
||||
===========
|
||||
-----------
|
||||
|
||||
Plugins: |Plugin_Environment|
|
||||
|
||||
Extra IO
|
||||
========
|
||||
--------
|
||||
|
||||
Plugins: |Plugin_Extra_IO|
|
||||
|
||||
Gases
|
||||
=====
|
||||
-----
|
||||
|
||||
Plugins: |Plugin_Gases|
|
||||
|
||||
Generic
|
||||
=======
|
||||
-------
|
||||
|
||||
Plugins: |Plugin_Generic|
|
||||
|
||||
Gesture
|
||||
=======
|
||||
-------
|
||||
|
||||
Plugins: |Plugin_Gesture|
|
||||
|
||||
Gyro
|
||||
====
|
||||
----
|
||||
|
||||
Plugins: |Plugin_Gyro|
|
||||
|
||||
Hardware
|
||||
========
|
||||
--------
|
||||
|
||||
Plugins: |Plugin_Hardware|
|
||||
|
||||
Keypad
|
||||
======
|
||||
------
|
||||
|
||||
Plugins: |Plugin_Keypad|
|
||||
|
||||
Light/Lux
|
||||
=========
|
||||
---------
|
||||
|
||||
Plugins: |Plugin_Light_Lux|
|
||||
|
||||
Motor
|
||||
=====
|
||||
-----
|
||||
|
||||
Plugins: |Plugin_Motor|
|
||||
|
||||
Notify
|
||||
======
|
||||
------
|
||||
|
||||
Plugins: |Plugin_Notify|
|
||||
|
||||
Output
|
||||
======
|
||||
------
|
||||
|
||||
Plugins: |Plugin_Output|
|
||||
|
||||
Regulator
|
||||
=========
|
||||
---------
|
||||
|
||||
Plugins: |Plugin_Regulator|
|
||||
|
||||
RFID
|
||||
====
|
||||
----
|
||||
|
||||
Plugins: |Plugin_RFID|
|
||||
|
||||
Switch input
|
||||
============
|
||||
------------
|
||||
|
||||
Plugins: |Plugin_Switch_input|
|
||||
|
||||
Weight
|
||||
======
|
||||
------
|
||||
|
||||
Plugins: |Plugin_Weight|
|
||||
|
||||
@@ -65,6 +65,9 @@ img {
|
||||
box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2), 0 6px 20px 0 rgba(0, 0, 0, 0.19);
|
||||
margin-bottom: 15px;
|
||||
}
|
||||
.navbar-brand img {
|
||||
margin-bottom: 5px;
|
||||
}
|
||||
h2 {
|
||||
background-color: #3492E2;
|
||||
color: #FFFFFF;
|
||||
@@ -72,17 +75,20 @@ h2 {
|
||||
padding: 4px 7px;
|
||||
}
|
||||
h3 {
|
||||
background-color: #3492E2;
|
||||
color: #FFFFFF;
|
||||
background-color: none;
|
||||
color: #3492E2;
|
||||
font-size: 15px;
|
||||
padding: 4px 7px;
|
||||
border-bottom-style: solid;
|
||||
border-bottom-color: #3492E2;
|
||||
}
|
||||
h4 {
|
||||
background-color: #A8A8A8;
|
||||
background-color: none;
|
||||
color: #000000;
|
||||
font-size: 15px;
|
||||
padding: 4px 7px;
|
||||
margin-left: 10px;
|
||||
border-bottom-style: solid;
|
||||
border-bottom-color: #000000;
|
||||
}
|
||||
.headerlink {
|
||||
color: #FFFFFF;
|
||||
|
||||
+2
-1
@@ -18,7 +18,6 @@
|
||||
from recommonmark.parser import CommonMarkParser
|
||||
import sphinx_bootstrap_theme
|
||||
|
||||
|
||||
# -- Project information -----------------------------------------------------
|
||||
|
||||
project = u'ESP Easy'
|
||||
@@ -307,4 +306,6 @@ rst_prolog = """
|
||||
.. |removed| replace:: :red:`removed`
|
||||
.. |fixed| replace:: :purple:`fixed`
|
||||
|
||||
.. |unit_url| replace:: http://<esp easy ip/host name>/
|
||||
|
||||
"""
|
||||
|
||||
Reference in New Issue
Block a user