Commit graph

2554 commits

Author SHA1 Message Date
Maurice Makaay
5a2984d03a
Fix attach_interrupt(...) for esp-idf framework (#2416)
Co-authored-by: Maurice Makaay <mmakaay1@xs4all.net>
2021-10-01 10:11:07 +02:00
Maurice Makaay
c89018a431
Option to ignore CRC for EFuse MAC address (#2399)
* Accept changes as proposed by black.

* Added test and implemented optional correctly.

* Disable PHY RF full calibration (because it calls the breaking MAC retrieval function).

* Disable CONFIG_ESP32_PHY_CALIBRATION_AND_DATA_STORAGE instead of enable, dummy!

* Rename CONF_IGNORE_EFUSE_MAC_CRC to CONF_ESP32_IGNORE_EFUSE_MAC_CRC.

* Removed unused import.

* Fix ordering of constants.

* Moved all MAC address logic to core helpers.

* Use pretty MAC address for the log.

* Use standard MAC formatter function for debug component.

* Fix clang-formatting.

* Fix clang-formatting.

* Brought wording of comments in line with other function-describing comments.

* Processed code review by @OttoWinter

* Add USE_ESP32_IGNORE_EFUSE_MAC_CRC to defines.h

Co-authored-by: Maurice Makaay <mmakaay1@xs4all.net>
2021-09-30 18:08:15 +02:00
Oxan van Leeuwen
1031ea4313
Fix line endings normalization (#2407)
* Strip CRLF line endings from modbus controller files

* Normalize all line endings to LF
2021-09-30 18:07:28 +02:00
Oxan van Leeuwen
5b0fbbaada
Replace std::move() with const references where possible (#2421)
* Replace std::move() with const references where possible

* Fix formatting
2021-09-30 16:25:08 +02:00
Oxan van Leeuwen
0e4f1ac40d
Fix default environment for clang-tidy (#2420)
* Drop unnecessary platformio call from script/lint-cpp

* Default environment for clang-tidy to esp32-tidy
2021-09-30 16:24:02 +02:00
Andy Allsopp
946db3fd50
Add viewport meta tag to web server layout (#2419)
* Update web_server.cpp

Added viewport meta tag to web_server.cpp in order to better control layout on mobile browsers. Adds 70 characters. Vastly improves accessibility on mobile devices.

* Update web_server.cpp

split line to meet clang format requirement.

* Update web_server.cpp

Reworked line break for clangtidy
2021-09-30 13:03:30 +02:00
WeekendWarrior1
3dfc8d4291
String manipulation filters for text sensors (#2393)
* initial text sensor filter POC

* fixed verbose logging

* add append, prepend, substitute filters

* add to lower, get to upper working without dummy

* clang lint

* more linting...

* std::move append and prepend filters

* fix verbose filter::input logging

* value.c_str() in input print

* lambda filter verbose log fix

* correct log tag, neaten to upper and to lower

* add on_raw_value automation/trigger
2021-09-29 23:25:06 +02:00
Oxan van Leeuwen
4f5e4f3b86
Move #ifdef to after header include (#2417)
defines.h needs to be included first.

Fixes esphome/issues#2490.
2021-09-29 23:21:52 +02:00
Jesse Hills
505d1d78fb
Remove default initializations from tuya cover (#2415) 2021-09-29 12:19:19 +13:00
Otto Winter
7af1c04493
Bump debian base to 5.1.0 / 20210902 (#2413) 2021-09-28 23:16:00 +02:00
Otto Winter
855c98d815
Fix tuya cover lint checks (#2414) 2021-09-28 23:15:52 +02:00
Marek Marczykowski-Górecki
c26ea7e4e0
Tuya: add cover component (#2279) 2021-09-29 10:02:13 +13:00
irtimaled
c39ac9edfe
Support HSV-based color support on tuya light (#2400)
* fix: stop tuya light state getting reset

* fix typo

* Support for HSV color in Tuya

* Clamp formatting
2021-09-28 22:19:17 +02:00
Stephen Tierney
af04f565cf
Add support for SCD4X (#2217)
* Initial commit

* clang-format fixes

* Update CODEOWNERS

* clang-format fixes

* Fix merge error

* Fix missing return

Co-authored-by: Otto winter <otto@otto-winter.com>
2021-09-28 22:10:25 +02:00
Paul Monigatti
2b9054d3b2
Initialised ESPPreferenceObject::backend_ to nullptr (#2411) 2021-09-28 16:26:46 +02:00
Jesse Hills
2234f6aacf
Fix lint issues in web_server_base (#2409) 2021-09-28 15:33:30 +13:00
Otto Winter
be965a60eb
Merge pull request from GHSA-48mj-p7x2-5jfm
* Move web_server auth to web_server_base

* Fix

* Fix

* Add middleware system
2021-09-28 13:53:38 +13:00
Oxan van Leeuwen
5596751c2c
Add str_sprintf function that returns std::string (#2408) 2021-09-28 10:24:55 +13:00
Paulus Schoutsen
6417d8132d
bump dashboard to 20210927.0 (#2405) 2021-09-27 23:08:21 +02:00
0hax
5624fafb3a
Fix handling of timestamps in Teleinfo component. (#2392)
* teleinfo: avoid a buffer overflow.

When reading tag or values, data is written to the buffer even if the
size if bigger than the buffer. Add a new 'max_len' argument to
get_field() to avoid this error.

Signed-off-by: 0hax <0hax@protonmail.com>

* teleinfo: read extra timestamp field for some tags.

Some tags has an extra timestamp field that need to be read before the
actual data.
The code is inspired by Jpsy work:

29339c14f9

Signed-off-by: 0hax <0hax@protonmail.com>

* teleinfo: increase MAX_BUF_SIZE to suffice for 3-phase Linky in Standard mode.

* teleinfo: handle DATE tag correctly.

The DATE tag is special due its format and need to be handled
separately.
Fix from DrCoolzic.

Signed-off-by: 0hax <0hax@protonmail.com>

Co-authored-by: Jörg Wagner <jwagner@digilog.de>
2021-09-27 22:32:08 +02:00
Daniel Müller
2eb5f89d82
Add cover toggle support (#1809)
* Add cover toggle support

Step through open/stop/close/stop sequence with every toggle

* Move the cover toggle logic to perform()

* Add clang-tidy CI suggestion

* Implement cover toggle action as cover trait

* Handle toggle correctly if cover fully closed on POR

* Fix CI finding

* Add deprecated warning

* Don't add already deprecated interface

Co-authored-by: Oxan van Leeuwen <oxan@oxanvanleeuwen.nl>

* Don't add already deprecated interface

Co-authored-by: Oxan van Leeuwen <oxan@oxanvanleeuwen.nl>

* Don't add already deprecated interface

Co-authored-by: Oxan van Leeuwen <oxan@oxanvanleeuwen.nl>

Co-authored-by: Mueller, Daniel <daniel.mueller@karlstorz.com>
Co-authored-by: Oxan van Leeuwen <oxan@oxanvanleeuwen.nl>
2021-09-27 22:31:15 +02:00
Marcos Pérez Ferro
e30f17f64f
Add Current based cover (#1439)
* Adding first version of current_base cover. No Interlock yet.

* simplifying code

* Implementing malfunction protection

* Adding test

* Fixing too long lines

* Fixing test sensor names

* Adding missing id's in ade7953 tests

* Adding code owners as requested

* Fixing issue setting position when stop reached

* Fixing issue setting position when stop reached

* Black formatting

* Fixing format issues

* Fix for concurrent changes

Co-authored-by: Oxan van Leeuwen <oxan@oxanvanleeuwen.nl>
2021-09-27 22:22:45 +02:00
irtimaled
1ba560dc9e
fix: stop tuya light state getting reset (#2401)
* fix: stop tuya light state getting reset

* fix typo
2021-09-27 21:54:51 +02:00
Maurice Makaay
8c86a18dc6
Add missing include for defines.h. (#2403)
Co-authored-by: Maurice Makaay <mmakaay1@xs4all.net>
2021-09-27 21:53:47 +02:00
Christian Taedcke
b2d516c70a
ccs811: Skip reading data if it is not available (#2404)
On bootup the ccs811 reports that no data is available. No error flag
is set in that case. The current implementation ignores this, reads
and publishes the invalid data, which is 0xFDFD for both tvoc and co2
in my case.
This commit fixes this and does not read and publish invalid data.
2021-09-27 21:53:05 +02:00
Otto Winter
45940b0514
Dashboard node import and render in browser (#2374) 2021-09-27 10:10:53 -07:00
Otto Winter
97e76d64d6
Re-enable TCP nodelay for ESP32 (#2390) 2021-09-27 11:40:28 +02:00
Jesse Hills
756c6721e9
Fix NDEF URI casing (#2397) 2021-09-27 11:11:27 +13:00
JonasEr
4c390d9f9f
Extend nfc ndef records with Text (#2191)
Co-authored-by: Oxan van Leeuwen <oxan@oxanvanleeuwen.nl>
2021-09-27 09:38:08 +13:00
Sergey V. DUDANOV
0d0954d74b
Midea fix (#2395) 2021-09-27 09:32:33 +13:00
Martin
7672ba2c8d
Modbus controller (#1779)
Co-authored-by: Jesse Hills <3060199+jesserockz@users.noreply.github.com>
2021-09-27 09:27:24 +13:00
WeekendWarrior1
4d28afc153
add fan.cycle_speed action (#2329) 2021-09-27 08:32:46 +13:00
irtimaled
7246f42a8e
Tuya rgb support (#2278)
Co-authored-by: Oxan van Leeuwen <oxan@oxanvanleeuwen.nl>
Co-authored-by: Jesse Hills <3060199+jesserockz@users.noreply.github.com>
2021-09-26 21:34:06 +13:00
irtimaled
bdcffc7ba9
fix: Setting Tuya string DP value (#2394) 2021-09-26 21:27:43 +13:00
rbaron
95a6715b2b
Adds light sensor support for b-parasites (#2391) 2021-09-25 13:16:27 +02:00
Otto Winter
5342edf04a
Misc fixes for esp-idf (#2386) 2021-09-25 10:05:32 +02:00
Otto Winter
d344b1ca0e
Fix arduino esp32 wifi v2 (#2389) 2021-09-25 10:04:57 +02:00
Otto Winter
278863d027
Fix some issues with wifi driver after IDF refactor (#2387) 2021-09-25 09:16:32 +02:00
Otto Winter
8503e08ee6
Fix InterruptLock on ESP-IDF (#2388) 2021-09-25 09:14:07 +02:00
Otto Winter
aec02afcdc
Fix clang-tidy header filter (#2385)
* Fix clang-tidy header filter

* Allow private members

* Fix clang-tidy detections

* Run clang-format

* Fix remaining detections

* Fix graph

* Run clang-format
2021-09-24 18:02:28 +02:00
Maurice Makaay
52dd79691b
Read unencrypted DSMR telegrams in chunks (#2382)
Co-authored-by: Maurice Makaay <mmakaay1@xs4all.net>
2021-09-24 14:15:22 +02:00
dependabot[bot]
aea2491fa4
Bump voluptuous from 0.12.1 to 0.12.2 (#2381) 2021-09-23 23:36:19 +02:00
Christian Taedcke
963b28181f
Always execute i2c bus recovery on setup (#2379) 2021-09-23 20:11:40 +02:00
Christian Taedcke
210a9a4162
Fix esp-idf pinmask bit-shift overflow (#2380) 2021-09-23 18:24:29 +02:00
Otto Winter
a27a884191
Add missing MockObj operators (#2378) 2021-09-23 11:53:10 +02:00
Paul Monigatti
17dcba8f8a
Fix: Pin flags code generation returning FLAG_NONE (#2377)
Co-authored-by: Otto winter <otto@otto-winter.com>
2021-09-23 11:19:17 +02:00
Paul Monigatti
ea6a7a22ff
Fix ESP8266 ADC (#2376) 2021-09-23 10:45:41 +02:00
Stijn Tintel
5ddba719c5
Fix ir_climate on ESP32-C3 (#2314)
Co-authored-by: Otto winter <otto@otto-winter.com>
2021-09-22 20:13:24 +02:00
Otto Winter
b398d826c1
Fix two i2c error code return errors (#2375) 2021-09-22 20:07:43 +02:00
Philipp Riederer
edb557f79e
ledc: do not try to write_state to an uninitialized output (#1732)
Co-authored-by: Philipp Tölke <ptoelke@tecracer.de>
Co-authored-by: Otto winter <otto@otto-winter.com>
2021-09-22 19:50:19 +02:00