Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions docs/make.bat
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
@ECHO OFF

set PYTHONUTF8=1

pushd %~dp0

REM Command file for Sphinx documentation
Expand Down
142 changes: 142 additions & 0 deletions docs/source/Plugin/P187.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,142 @@
.. include:: ../Plugin/_plugin_substitutions_p18x.repl
.. _P187_page:

|P187_typename|
==================================================

|P187_shortinfo|

Plugin details
--------------

Type: |P187_type|

Name: |P187_name|

Status ESP32: |P187_status|

Status ESP8266: |P187_status_lb|

GitHub: |P187_github|_

Maintainer: |P187_maintainer|

Used libraries: |P187_usedlibraries|

Introduction
------------

The Dummy Data Injector plugin simulates peripheral data output. It can be used e.g. to test IOT backend systems by providing input data for debugging.

The plugin can be applied multiple times in the devices list. Up to four synchronized data streams can be generated per deployment of the plugin, but the outputs of multiple plugins are not synchronized across the plugin boundaries.

Currently, there are following output configurations supported:

* **Sinus**: produces sinus shaped output values. The data stream can be configured in Amplitude, Offset, Period and Phase.

* **Trapezoid**: trapezoid shaped output values are created. The data stream's On-Level, Off-Level, Period, On-Time, Rise-Time and Fall-Time can be configured.

* **Random**: generates random output values. Minimum and Maximum values can be configured.

.. image:: P187_OutputCombined.png
:alt: Output view


Configuration
-------------

.. image:: P187_DeviceConfiguration.png
:alt: Device configuration

* **Name**: Required by ESPEasy, must be unique within the list of available devices/tasks.

* **Enabled**: The device can be disabled or enabled. When not enabled, no output data is generated.

Device Settings
^^^^^^^^^^^^^^^

Depending on the selected 'Number Output values', up to four sections are used to configure the output values (press 'Submit' after changing) :

.. image:: P187_OutputConfiguration.png
:alt: Output configuration

Output Sinus
~~~~~~~~~~~~

.. image:: P187_OutputConfigurationSinus.png
:alt: Output sinus configuration

* **Amplitude**: Amplitude of the signal (integer value 0 to +65537)
* **Offset**: Offset from 0-Line (integer value -65537 to +65537)
* **Period**: period time in seconds (integer value 30 - 3600)
* **Phase**: phase offset in degrees (integer value 0 - 359)

.. image:: P187_OutputSinus.png
:alt: Output sinus view

- for floating value output, use formula to divide the output levels (e.g. for floating value output with 2 decimals use the formula '%value%/100').

Output Trapezoid
~~~~~~~~~~~~~~~~

.. image:: P187_OutputConfigurationTrapezoid.png
:alt: Output trapezoid configuration

* **On-Level**: output level during On-Time period (integer value -65537 to +65537)
* **Off-Level**: output level during Off-Time period (integer value -65537 to +65537)
* **Period**: period time in seconds (integer value 30 - 3600)
* **On-Time**: duration of On-Time period in seconds (integer value 0 - 3600)
* **Rise-Time**: duration of linear slope from Off-Level to On-Level (integer value 0 - 3600)
* **Fall-Time**: duration of linear slope from On-Level to Off-Level (integer value 0 - 3600)

.. image:: P187_OutputTrapezoid.png
:alt: Output trapezoid view

- for inverted output, swap On-Level value with Off-Level value.
- Period must be greater or equal than the sum of On-Time, Rise-Time and Fall-Time. If not, some automatic adjustments are made to these values to meet this rule.
- for floating value output, use formula to divide the output levels (e.g. for floating value output with 2 decimals use the formula '%value%/100').

Output Random
~~~~~~~~~~~~~

.. image:: P187_OutputConfigurationRandom.png
:alt: Output random configuration

* **Max-Level**: maximum output level (integer value -65537 to +65537)
* **Min-Level**: minimum output level (integer value -65537 to +65537)

.. image:: P187_OutputRandom.png
:alt: Output random view

- for floating value output, use formula to divide the output levels (e.g. for floating value output with 2 decimals use the formula '%value%/100').


Performance
-----------

For performance measurement, an ESP32 development board was reset to factory default settings via Wi-Fi.

One 'System Info' device was added with a single output measuring the system load each 30s.

Furthermore 3 Dummy Data Injector plugins were added to the devices:
- Number one generates 4 sinus outputs, interval was set to 1 second, 'Stats' box was activated for all four outputs.
- Number two generates 4 trapezoid outputs, interval was set to 1 second, 'Stats' box was activated for all four outputs.
- Number three generates 4 random outputs, interval was set to 1 second, 'Stats' box was activated for all four outputs.

The devices page was open in one browser window, and the device was left idling for 5 minutes. Afterwards the System load shows ~29%

In comparison, the same ESP32 system, after deleting the three Dummy Data Injector plugins showed an idle System load of ~23%.

Change log
----------

.. versionadded:: 1.0
...

|added|
Initial release version.





Binary file added docs/source/Plugin/P187_DeviceConfiguration.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/source/Plugin/P187_OutputCombined.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/source/Plugin/P187_OutputConfiguration.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/source/Plugin/P187_OutputRandom.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/source/Plugin/P187_OutputSinus.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/source/Plugin/P187_OutputTrapezoid.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions docs/source/Plugin/_Plugin.rst
Original file line number Diff line number Diff line change
Expand Up @@ -509,6 +509,7 @@ There are different released versions of ESP Easy:
":ref:`P177_page`","|P177_status|","|P177_status_lb|","P177"
":ref:`P178_page`","|P178_status|","|P178_status_lb|","P178"
":ref:`P180_page`","|P180_status|","|P180_status_lb|","P180"
":ref:`P187_page`","|P187_status|","|P187_status_lb|","P187"


.. include:: <isonum.txt>
Expand Down
2 changes: 1 addition & 1 deletion docs/source/Plugin/_plugin_categories.repl
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
.. |Plugin_Environment| replace:: :ref:`P004_page`, :ref:`P005_page`, :ref:`P006_page`, :ref:`P014_page`, :ref:`P024_page`, :ref:`P028_page`, :ref:`P030_page`, :ref:`P031_page`, :ref:`P032_page`, :ref:`P034_page`, :ref:`P039_page`, :ref:`P047_page`, :ref:`P051_page`, :ref:`P068_page`, :ref:`P069_page`, :ref:`P072_page`, :ref:`P103_page`, :ref:`P105_page`, :ref:`P106_page`, :ref:`P122_page`, :ref:`P150_page`, :ref:`P151_page`, :ref:`P153_page`, :ref:`P154_page`, :ref:`P163_page`, :ref:`P167_page`, :ref:`P169_page`, :ref:`P172_page`, :ref:`P173_page`, :ref:`P177_page`
.. |Plugin_Extra_IO| replace:: :ref:`P011_page`, :ref:`P022_page`, :ref:`P178_page`
.. |Plugin_Gases| replace:: :ref:`P049_page`, :ref:`P052_page`, :ref:`P083_page`, :ref:`P090_page`, :ref:`P117_page`, :ref:`P127_page`, :ref:`P135_page`, :ref:`P145_page`, :ref:`P147_page`, :ref:`P164_page`
.. |Plugin_Generic| replace:: :ref:`P003_page`, :ref:`P026_page`, :ref:`P033_page`, :ref:`P037_page`, :ref:`P081_page`, :ref:`P100_page`, :ref:`P146_page`, :ref:`P180_page`
.. |Plugin_Generic| replace:: :ref:`P003_page`, :ref:`P026_page`, :ref:`P033_page`, :ref:`P037_page`, :ref:`P081_page`, :ref:`P100_page`, :ref:`P146_page`, :ref:`P180_page`, :ref:`P187_page`
.. |Plugin_Gesture| replace:: :ref:`P064_page`
.. |Plugin_Gyro| replace:: :ref:`P045_page`, :ref:`P119_page`
.. |Plugin_Hardware| replace:: :ref:`P046_page`
Expand Down
Loading