Skip to content

Commit

Permalink
Merge branch 'mega' into dallas_esp32
Browse files Browse the repository at this point in the history
  • Loading branch information
TD-er authored Apr 15, 2020
2 parents 2d51667 + 89355b0 commit 2161a16
Show file tree
Hide file tree
Showing 142 changed files with 5,367 additions and 1,080 deletions.
17 changes: 17 additions & 0 deletions .github/stale.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Number of days of inactivity before an issue becomes stale
daysUntilStale: 60
# Number of days of inactivity before a stale issue is closed
daysUntilClose: 14
# Issues with these labels will never be considered stale
exemptLabels:
- pinned
- security
# Label to use when marking an issue as stale
staleLabel: stale
# Comment to post when marking an issue as stale. Set to `false` to disable
markComment: >
This issue has been automatically marked as stale because it has not had
recent activity. It will be closed if no further activity occurs. Thank you
for your contributions.
# Comment to post when closing a stale issue. Set to `false` to disable
closeComment: true
95 changes: 48 additions & 47 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,47 +1,48 @@
## OS Specific Hidden Files ####

# MacOSX Finder *****
.DS_Store

# Fuse FileSystem ***
.fuse_hidden*


## PlatformIO ##################
.pioenvs
.clang_complete
.gcc-flags.json
.piolibdeps
pre_extra_script.py
*.code-workspace

## Project #####################
lib/readme.txt
src/Custom.h
/ESPEasy
test/output_export.cpp
.vscode
.vscode/.browse.c_cpp.db*
.vscode/c_cpp_properties.json
.vscode/launch.json
src/ESPEasy.ino.cpp

docs/build/

\.pio/

docs/source/_build/

venv/

.idea/

tools/vagrant/.vagrant/

tools/vagrant/build/

tools/vagrant/Custom.h

.buildcache/

tools/vagrant/pio_envlist.txt
## OS Specific Hidden Files ####

# MacOSX Finder *****
.DS_Store

# Fuse FileSystem ***
.fuse_hidden*


## PlatformIO ##################
.pioenvs
.clang_complete
.gcc-flags.json
.piolibdeps
pre_extra_script.py
*.code-workspace
.pio

## Project #####################
lib/readme.txt
src/Custom.h
/ESPEasy
test/output_export.cpp
.vscode
.vscode/.browse.c_cpp.db*
.vscode/c_cpp_properties.json
.vscode/launch.json
src/ESPEasy.ino.cpp

docs/build/

\.pio/

docs/source/_build/

venv/

.idea/

tools/vagrant/.vagrant/

tools/vagrant/build/

tools/vagrant/Custom.h
.buildcache/
tools/vagrant/pio_envlist.txt
Expand Down
9 changes: 9 additions & 0 deletions before_deploy
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,9 @@ if [ -d "docs/build" ]; then
cp -r docs/build/* ${TMP_DIST}/docs/
fi

FBINDIR="${TMP_DIST}/factory_bin"
mkdir -p ${TMP_DIST}/memstats
mkdir -p ${FBINDIR}

# Must look into all possible env definitions.
# Exclude so called "spec_" (special) builds
Expand All @@ -62,6 +64,7 @@ do
fi

FIRMWARE_BIN=`echo "${BINARY_PATH}/${ENV}/firmware.bin"`
FIRMWARE_FACTORY_BIN=`echo "${BINARY_PATH}/${ENV}/firmware-factory.bin"`

if [ -f $FIRMWARE_BIN ]; then
FILESIZE=$(stat -c%s `echo "${FIRMWARE_BIN}"` )
Expand All @@ -72,6 +75,12 @@ do
cp ${FIRMWARE_BIN} $BIN
python2 crc2.py $BIN
mv $BIN "${TMP_DIST}/bin/ESP_Easy_${VERSION}_${ENV}.bin"
if [ -f $FIRMWARE_FACTORY_BIN ]; then
FBIN=${BINARY_PATH}/${ENV}/ESP_Easy_${VERSION}_${ENV}_factory.bin
cp ${FIRMWARE_FACTORY_BIN} $FBIN
#python2 crc2.py $FBIN
mv $FBIN "${FBINDIR}/ESP_Easy_${VERSION}_${ENV}_factory.bin"
fi
else
echo "FAILED: too large $FILESIZE > $MAX_FILESIZE Bytes. (${ENV})" >> ${BUILD_LOG}
fi
Expand Down
7 changes: 3 additions & 4 deletions crc2.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@


import sys
import binascii
import struct
import md5
from hashlib import md5
import os
MD5DUMMY = "MD5_MD5_MD5_MD5_BoundariesOfTheSegmentsGoHere..." #48 chars
FILENAMEDUMMY = "ThisIsTheDummyPlaceHolderForTheBinaryFilename64ByteLongFilenames" #64 chars
Expand Down Expand Up @@ -102,8 +102,7 @@ def showParts(fileContent, offset):
print("ERROR: MD5 dummy not found in binary")
else:
hashString=hashString.replace (MD5DUMMY,"",1)
m = md5.new()
m.update (hashString) #use segment 1
m = md5(hashString) #use segment 1
md5hash = m.digest()
print("MD5 hash: "+ m.hexdigest())
print("\nwriting output file:\n" + FileName)
Expand Down
43 changes: 43 additions & 0 deletions dist/Release_notes.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,46 @@
-------------------------------------------------
Changes in release mega-20200410 (since mega-20200328)
-------------------------------------------------

Release date: vr 10 apr 2020 21:23:29 CEST

Bartlomiej Zimon (1):
ESP32: add subtarget for genuine units firmware-factory.bin Resolves #2964 #2941 #2486

Gijs Noorlander (16):
[Frontend] Fix reload on change for selectors (#2974 )
[Frontend] Fix crash when loading config + controller page
[CUL Reader] P094_CULReader
[CUL Reader] Clean up code
[CUL Reader] Add 4th filter parameter
[CUL Reader] Fix bug in save/load settings
[CUL Reader] Add positional match
[Sysvar] Fix show %ip% and %ip4% instead of %ip4% twice
[CUL Reader] Add basic docs
[Webserver] Fix ambiguous function definitions for selectors
[Serial Plugins] Share more code among plugins using serial
[Build] Fix build issue
[build] New attempt to fix build for unused static function
[PulseCounter] Restore from RTC before initializing pin triggers
[WiFi] Fix problem with static IP and reconnect ESP32 (#2997)
[WiFi] Switch to default PIO_FRAMEWORK_ARDUINO_ESPRESSIF_SDK22x_190703

Michael Schröder (2):
Fix DeepSleep0 command
Update deepsleep-command docs

TD-er (2):
[P020_Ser2Net] Fix missing break; PLUGIN_SERIAL_IN
[CUL Reader] 12 items per filter line + extra chars on filter whitelist

tonhuisman (5):
[P036] Added setting for 'Keep display off receiving text'
[P036] Added setting for 'Wake display on receiving text'
[P036] Added new setting to plugin documentation
Fixed note wording
Made note wording more functional


-------------------------------------------------
Changes in release mega-20200328 (since mega-20200310)
-------------------------------------------------
Expand Down
11 changes: 1 addition & 10 deletions docs/source/Plugin/P000_commands.repl
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,7 @@
:red:`Internal`","
Switch the node to deep sleep.
Max sleep time depends on library version and differs from roughly 71 minutes to 3h46.
If you specify a Min sleep time of 0, you'll have to wake the device yourself by pulling RST to GND.

``DeepSleep,<sleep time in seconds>``"
"
Expand Down Expand Up @@ -228,16 +229,6 @@

``meminfoDetail``"
"
MessageDelay","
:red:`Internal`","
Get or set the MQTT message delay.

``MessageDelay``

``MessageDelay,<value in ms>``

Example output: ``MQTT message delay:100``"
"
Name","
:red:`Internal`","
Set the name of the unit
Expand Down
8 changes: 7 additions & 1 deletion docs/source/Plugin/P003_commands.repl
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,14 @@
:widths: 20, 30

"
``resetpulsecounter,<taskIndex>``
``ResetPulseCounter,<taskIndex>``
","
Reset the counters (pulse counter and total counter) of P003 Pulse Counter.
The taskIndex parameter is optional. When not given, only the first task with this plugin will be cleared.
"
"
``SetPulseCounterTotal,value,<taskIndex>``
","
Set the value of the total count of P003 Pulse Counter.
The taskIndex parameter is optional. When not given, only the total count of the first task with this plugin will be set.
"
2 changes: 2 additions & 0 deletions docs/source/Plugin/P036.rst
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,8 @@ Please note that scrolling may need more resources of the ESP, which can have an

The plugin allows for a header and footer line, which may show some user selectable information.

Checkbox 'Wake display on receiving text' (default: on) allows to not wake up the display when a text is sent from a remote source, and Display Timeout is set.

All user defined texts may contain references to system variables or task values which will be interpreted when displayed on screen.

For example: ``[bme#T#D2.1] {D}C [bme#H]%``
Expand Down
36 changes: 36 additions & 0 deletions docs/source/Plugin/P092.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
.. include:: ../Plugin/_plugin_substitutions_p09x.repl
.. _P092_page:

|P092_typename|
==================================================

|P092_shortinfo|

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

Type: |P092_type|

Name: |P092_name|

Status: |P092_status|

GitHub: |P092_github|_

Maintainer: |P092_maintainer|

Used libraries: |P092_usedlibraries|

Supported hardware
------------------

|P092_usedby|

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

.. versionadded:: 1.0
...

|added|
Initial release version.
Binary file added docs/source/Plugin/P092_12V_Wiring.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/P092_24V_Wiring.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/P092_DL_bus_databyte.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/P092_DL_bus_dataframe.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/P092_DL_bus_dataframelog.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/P092_DL_bus_displayclock.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/P092_DL_bus_outputwiring.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
50 changes: 50 additions & 0 deletions docs/source/Plugin/P092_DLbus.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
.. include:: ../Plugin/_plugin_substitutions_p09x.repl
.. _P092_DLbus_page:

DL bus
======

|P092_typename|
|P092_status|

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

The DL-Bus is used in control units e.g. sold by `Technische Alternative <http://www.ta.co.at/>`_.
The DL-Bus serves as a bus line for various external sensors and modules.
The DL-Bus is a bidirectional data line and only compatible with products of Technische Alternative.

The data transmission looks as follows:
* In an infinite loop, a logging data frame is created by the control one after the others on the data line.

Up to 4 sensor measured value queries (master/slave) can be made between the individual logging data frames on the DL bus.
* So that the beginning of a data frame can be detected, a SYNC of 16 high bits is sent before the first data byte.
* The data transmission is carried out as Manchester code (EXOR linked) with a display clock of 50 or 488Hz (depending on control type).

This is necessary to ensure the supply voltage of the logger and DL sensors from the data signal.
If the receiver is synchronized to the display clock, the correct bit value appears always during the second half period of the data bit (inverted in the first half period).

Wiring
------

The DL-Bus consists of 2 wires: DL and GND (sensor ground).
The power supply for the DL-Bus sensors is supplied via the DL-Bus itself.
Some DL-Bus devices can/must be powered via a 12V source, e.g. that of the CAN bus (this is explicitly noted in the operating manual of that sensor).
The cable routing can be star-shaped or serial (from one device to the next).
Any cable with a cross-section of 0.75 mm2 up to a maximum length of 30 m can be used as a data cable.
Over 30 m, the use of shielded cables is recommended, which increases the permissible length of the cable to 100 m.

Protocol
--------

Transmission of a data byte
.. image:: P092_DL_bus_databyte.png

Transmission of a data frame
.. image:: P092_DL_bus_dataframe.png

Data frame on the DL bus
.. image:: P092_DL_bus_dataframelog.png

Display clock
.. image:: P092_DL_bus_displayclock.png
Binary file added docs/source/Plugin/P092_ESR21.PNG
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit 2161a16

Please sign in to comment.