Commit Graph

284 Commits

Author SHA1 Message Date
Jim Ekman
7708b81ef5
Support fan speed levels (#1541)
* Add fan speed percentage support to the API

* Add float fan speed percentage

* Add percentage support to automation and configuration

* Update Tuya fan

* Fix pylint warning

* Update API to use speed levels instead of percentage

* Use speed levels

* Fix type warnings

* MQTT component now converts between speed levels and enums

* Webserver now supports speed_level

* Update prometheus

* Remove low/medium/high settings from speed fan

* Remove unused enum

* Configurable speed levels for speed fan

* Remove unused import

* Rename speed_level->speed and speed_levels->speed_count

* Rename supported_speed_levels -> supported_speed_count in API and FanTraits

Field id stays the same in the protocol, so the change is not breaking for aioesphome.
2021-03-17 10:40:02 -03:00
Massimiliano Ravelli
28a72fa56b
Fixed component_tests config (#1608) 2021-03-12 19:58:43 -03:00
Guillermo Ruffino
1e227e8051
Schema dump (#1564)
* schema dump idea

accept boolean or anything default

accept null also for full dicts

added some common validators

more simple validators

support multi_conf

better handle automations

updates

updates

handle lists

removed not needed class

move to own folder

generalized for automations lists, etc

updates

updates

clean up

clean up

fix automations

made comment optional

basic docs support

added more docs

fixes docs handling

updates

updates

fix components parent

updates

updates

updates

Fix inkplate 6 registration

updates

Disable logging for vscode add on

better handle buses

keep extended order as in CONFIGs

updates

updates

updates

disable comments

moved to scripts/build_jsonschema

added configurable decorators

path handling

fix handle list_schema

fixes and cleanup

add jschema_extractor to maybe

updates

lint

no schema in git

add generated loggers list

* lint
2021-03-07 21:05:08 -03:00
Guillermo Ruffino
d5cf4b7eac
Improve error checking: too many component id candidates (#1570)
* add error too many candidates

* Improve error checking of ids
2021-03-07 19:59:32 -03:00
Jesse Hills
570ec36fe3
MCP23XXX Refactor (#1560)
* Refactor MCP23XXX classes to consolidate shared code

* Update test mcp23xxx pin schemas
2021-03-07 16:23:54 -03:00
Guillermo Ruffino
69879920eb
add-black (#1593)
* Add black

Update pre commit

Update pre commit

add empty line

* Format with black
2021-03-07 16:03:16 -03:00
needspeed
0f151a8f6b
Extend 'uart:' with 'invert:' for esp32 (#1586) 2021-03-06 10:25:07 -03:00
Gabe Cook
88b46b7487
Add min/max filters (#1569) 2021-03-05 10:10:06 -03:00
Moritz Glöckl
8e93735861
Add support for the SM300D2 7-in-1 sensor module (#1524)
* Added support for SM300D2 sensor module

* Fixed lint errors due to added tvoc config

* add device class

Co-authored-by: Guillermo Ruffino <glm.net@gmail.com>
2021-03-02 21:54:52 -03:00
SenexCrenshaw
ac25b138f5
Migrate ESPColor to Color (#1551)
* Migrate ESPColor to Color

* color.h constructor fix

* Updated componets to use Color
Added a using for ESPColor

* Lint fixes

* Fixed value error

* Update display components to use colorutil

* Updated to latest PR comments

* Fixed COLOR_WHITE

* Moved esp_scale to color_utils

* Rename color_utils to display_color_utils
2021-03-02 11:08:57 -03:00
Seppel Hardt
bdf004867d
Added samsung36 ir protocol (#1438)
* Added samsung36 ir protocol

* Make linter happy

* Added test and fixed python failure

* Sorry for the commits but linter was still not happy :)

* Okay have to run  script/clang-format -i

Co-authored-by: tuxBurner <tuxBurner@boggo.de>
2021-02-27 20:16:27 -03:00
Gabe Cook
08ecca86bc
Add send_every to uart switch for recurring data (#1514) 2021-02-27 19:53:53 -03:00
Kurt Kellner
b91723344e
Vl53l0x change address (#1126)
* Added vl53l0x change address and timeout

* Added vl53l0x change address and timeout

* vl53l0x code cleanup and update test

* remove executable bit

* lint code cleanup

* code review fixes including timeout default to 10ms

* Code review cleanup and change a WARN log level message to DEBUG

* Fix issue where warn should be temporary

* Added name of sensor to warning message

* Fix blacklist lint issue

* Remove unused import
2021-02-25 19:12:06 -03:00
spilin
3d0310d0e0
Add dial support for sim800l component (#1558) 2021-02-25 18:11:15 -03:00
Guillermo Ruffino
25924ca4e8
fix substitution losing track of document range (#1547) 2021-02-19 21:52:42 -03:00
Kris
c92c439d17
Added Waveshare 2.90inch V2 e-ink display (#1538) 2021-02-18 07:12:02 +13:00
Chris Nussbaum
dce20680d7
Add duration option to action start deep sleep (#1526) 2021-02-15 14:32:22 -03:00
marecabo
f95be6a0df
Device class attribute for sensor component (#1525)
* Add constants for sensor device_class

* Add device_class attribute to sensor component

* Add device_class attribute to sensor class

* Add device_class to mhz19 temperature sensor

* Add device_class to sensor in api component

* Add test for device_class of sensor

* Rename DEVICE_CLASS_NONE to DEVICE_CLASS_EMPTY for consistency

* Make optional attributes of sensor component truly optional
2021-02-15 12:49:02 -03:00
SenexCrenshaw
a342302114
st7735_conf_fixes (#1530) 2021-02-14 02:21:43 -03:00
Keith Burzinski
b52f7cfe86
MCP230xx open drain interrupt pins (#1243) 2021-02-13 22:07:11 +13:00
Frank Bakker
81b512a7b3
Added energy sensor to hlw8012 (#1198) 2021-02-13 21:57:06 +13:00
Jérémy JOURDIN
04d8593f38
Add MCP4725 DAC Component (#1418)
* Add MCP4725 DAC

* Fix lint

* Fix lint

* Fix lint

* Lint & cleanup

* Lint again

* One more lint

* add test

Co-authored-by: Guillermo Ruffino <glm.net@gmail.com>
2021-02-06 12:18:48 -03:00
fkirill
de3377132d
Adding support for the Inkbird IBS-TH1 Mini sensor (#1099) 2021-02-06 17:04:47 +13:00
Guillermo Ruffino
52c67d715b
add http request tests (#1448)
* add http request tests

* add to test3 for esp8266

* move test action to another trigger
2021-01-23 19:44:20 -03:00
Florian Mösch
b28735d63b
rename read/write to read/time/write_time (#1468) 2021-01-18 09:35:35 -03:00
Florian Mösch
4c105398f7
time sync notification (#1442)
* add on_time_sync trigger

* cleanup lint

* fix review remark (sntp didn't trigger callbacks)
2021-01-18 09:34:50 -03:00
SenexCrenshaw
36089a1400
Updated Mcp3008 to support reference_voltage and voltage_sampler::VoltageSampler (#1387)
Co-authored-by: Jesse Hills <3060199+jesserockz@users.noreply.github.com>
2021-01-14 07:33:19 +13:00
Florian Mösch
bf453ad8cd
make time components polling components (#1443)
* make real time clock components polling components

* add test
2021-01-12 15:37:22 -03:00
Guillermo Ruffino
fbc1b3e316
Add rc522 i2c (#1432)
* split to spi and i2c

* fix binary_sensor

* i2c comms ready

* fix rc522_spi binary sensor compat

* lint

* lint

* add test and codeowners

* fix refactor
2021-01-12 10:13:53 -03:00
Florian Mösch
699696e8d1
DS1307 real time clock component (#1441)
* initial support for DS1307 real time clock

* add simple test, make sync functions public

* cleanup lint

* add sync to/from rtc actions

* changes action names

* Update esphome/components/ds1307/ds1307.cpp

Co-authored-by: Guillermo Ruffino <glm.net@gmail.com>

* Update esphome/components/ds1307/time.py

Co-authored-by: Guillermo Ruffino <glm.net@gmail.com>

* fix suggested change

Co-authored-by: Guillermo Ruffino <glm.net@gmail.com>
2021-01-08 19:40:22 -03:00
Keith Burzinski
095d3181cd
SSD1322 display support (#1405) 2020-12-30 22:52:41 +13:00
Keith Burzinski
9aa14a2e83
Add full SSD1327 display support (#1406) 2020-12-30 22:48:23 +13:00
Daniel Schramm
498b59e998
Canbus + MCP2515 including ExtID support (#1384) 2020-12-22 08:27:20 +13:00
SenexCrenshaw
7cd4c3bdd3
MCP23SXX I/O Expander - SPI (#1068)
Co-authored-by: Jesse Hills <3060199+jesserockz@users.noreply.github.com>
2020-12-07 06:43:55 +13:00
Michel Marti
b3169deda7
scd30: Allow setting temperature offset (#1400) 2020-12-04 07:21:10 +13:00
Alex
3afb564a48
Configurable OTA Safe Mode (#1393) 2020-12-02 11:41:39 +13:00
SenexCrenshaw
7ff3f752e2
New display ST7735 (#1066)
* Initial Commit - ST7735

* Updated for CI checks

* Updated for travis build

* Travis fixes

* Travis line too long

* Travis fixes

* Fixed up travis format issues

* Travis Fixes

* Initial Commit - ST7735

* Updated for CI checks

* Updated for travis build

* Travis fixes

* Travis line too long

* Travis fixes

* Fixed up travis format issues

* Travis Fixes

* Update to new color API and added test

* Check fixes

* Fixed sid length in test

* Cleaned up whitespaces

* kbx81 recommended fixes

* test fix

* Fixes of fixes

* Fixed test1.yaml

* Fixed test1.yaml

* Changed digital pin #s to gpio

* Updated to match kbx's color names

* Typo for ST7735_INITR_MINI_160X80

* Updated 8bit color space code
Added to_rgb_332 to color.h
fixed typo

* Added in to_rgb_332,to_bgr_332, rgb_332to_rgb_556 and a more generic scale

* Fixed MADCTL

* Fixp MADCTL

* Implemented usrbgr option
updated color to support 332 bgr conversion
typo fix

* Updated to_bgr_332

* Fix up for clang

* FIx up init code. type in buffer caused overrun

* fixup protected names

* typos

* Matched use_bgr to its conf

* color.h red fix in bgr_233to_rgb_565

* Fix ST7735_INITR_MINI_160X80

* Renamed bgr_233to_bgr_565 to match its function
Color space leak in bgr_233to_bgr_565.
cleaned up init code for displays.

* Fix

* clang fix

* Started Color Conversion

* Added various bit color functions
add triadto

* lint changes

* Various fixes

* Various formatting fixes. Wish my checks worked!

* Updated color api to support different formats
removed to_rgb_565

* lint clang fixes

* Test1 fix

* test1.yaml fix

* fixed 565 in ILI9341Display

* Added CodeOwners

* Updated CODEOWNERS

* changed to to332 and to565

* Waiting for color.h changes

* Stage changes

* Removed all changes except this driver

* Moved color functions into driver

* lint changes

* Lint and removed unrelated display driver changes

* Lint changes

* Initial Commit - ST7735

* Updated for CI checks

* Updated for travis build

* Travis fixes

* Travis line too long

* Travis fixes

* Fixed up travis format issues

* Travis Fixes

* Initial Commit - ST7735

* Updated for CI checks

* Updated for travis build

* Travis fixes

* Travis line too long

* Travis fixes

* Fixed up travis format issues

* Travis Fixes

* Update to new color API and added test

* Check fixes

* Fixed sid length in test

* Cleaned up whitespaces

* kbx81 recommended fixes

* test fix

* Fixes of fixes

* Fixed test1.yaml

* Fixed test1.yaml

* Changed digital pin #s to gpio

* Updated to match kbx's color names

* Typo for ST7735_INITR_MINI_160X80

* Updated 8bit color space code
Added to_rgb_332 to color.h
fixed typo

* Added in to_rgb_332,to_bgr_332, rgb_332to_rgb_556 and a more generic scale

* Fixed MADCTL

* Fixp MADCTL

* Implemented usrbgr option
updated color to support 332 bgr conversion
typo fix

* Updated to_bgr_332

* Fix up for clang

* FIx up init code. type in buffer caused overrun

* fixup protected names

* typos

* Matched use_bgr to its conf

* color.h red fix in bgr_233to_rgb_565

* Fix ST7735_INITR_MINI_160X80

* Renamed bgr_233to_bgr_565 to match its function
Color space leak in bgr_233to_bgr_565.
cleaned up init code for displays.

* Fix

* clang fix

* Started Color Conversion

* Added various bit color functions
add triadto

* lint changes

* Various fixes

* Various formatting fixes. Wish my checks worked!

* Updated color api to support different formats
removed to_rgb_565

* lint clang fixes

* Test1 fix

* test1.yaml fix

* fixed 565 in ILI9341Display

* Added CodeOwners

* Updated CODEOWNERS

* changed to to332 and to565

* Waiting for color.h changes

* Stage changes

* Removed all changes except this driver

* Moved color functions into driver

* lint changes

* Lint and removed unrelated display driver changes

* Lint changes

* Updated with latest color api

* pulled from origin

* Updated for color.h changes

* pulled test1 from dev

* Added test
2020-11-23 14:37:43 -03:00
SenexCrenshaw
d821ead92a
Formatted test yaml files (#1382) 2020-11-19 23:59:19 -03:00
Keith Burzinski
08f1eac8b2
SSD1331 display support (#1244) 2020-11-18 19:34:53 +13:00
MoA
a9a00f139b
Add climate.hitachi_ac344 (#1336)
* Add climate.hitachi_ac344

* Add Hitachi AC344 Climate IR test

* Fixes unhandled switch-case in fan-mode

* Fixes logging format

* Fixes file mode

* Lint clang-tidy

* Lint clang-tidy

* Static cast float to uint8
git push

* Remove comment and debug code

* Change log verbosity to VV
2020-11-17 22:05:12 -03:00
Samuel Sieb
d20caa9d60
add support for EZO sensor circuits (#1239)
Co-authored-by: Samuel Sieb <samuel@sieb.net>
2020-11-17 22:01:42 +13:00
Marcos Pérez Ferro
7e40d4246c
Adding ADE7953 irq_pin (#1359) 2020-11-16 09:30:14 +13:00
0hax
5a2b14cfa4
components: teleinfo: electrical counter information. (#1108)
Signed-off-by: 0hax <0hax@protonmail.com>
Co-authored-by: Otto Winter <otto@otto-winter.com>
Co-authored-by: Jesse Hills <3060199+jesserockz@users.noreply.github.com>
2020-11-16 07:08:19 +13:00
Michel Marti
f2d218e5ad
scd30: Allow setting ambient pressure compensation (#1365) 2020-11-16 07:03:08 +13:00
Yaroslav
c9055f2aef
Allow Tuya climate temperature_multiplier to be current/target multiplier (#1345)
* Separate temperature_multiplier to current/target multiplier

* Apply suggestions from code review

Co-authored-by: Jesse Hills <3060199+jesserockz@users.noreply.github.com>

Co-authored-by: Jesse Hills <3060199+jesserockz@users.noreply.github.com>
2020-11-12 06:31:35 +13:00
Yaroslav
9fed7cab5f
Add support for Tuya MCU 0x1C (obtain local time) (#1344)
* Fix some Tuya devices not handling commands sent without delay

* Also do not report WiFi status if MCU does not support it

* Support Tuya MCU 0x1c command (obtain local time)

* Use #ifdef USE_TIME to handle optional dependency on RTC

* Rename Tuya clock config variable to time to be consistent with the codebase

* Add tuya time configuration to test4
2020-11-11 11:31:28 +13:00
Daniel Hyles
fc01a70b65
Hbridge christmas light (#1251)
* Hbridge Christmas light component

Can be used for Christmas lights that use 2 wires to run 2 different strings of lights using a hbridge driver.

* Add Test

NOTE: I am unable to test this via the docker image

* Update hbridge_light_output.h

* Update hbridge_light_output.h

* Update hbridge_light_output.h

* Update light.py

* Fixed duty as white value bug fixed

* lint changes

* Name case change

* thanks lint
2020-11-08 14:46:34 +13:00
Alexander Pohl
49cb8fd9d3
Add support for ATC_MiThermometer (#1291)
* Add support for additional Xiaomi BLE sensors (#1027)

* Revert "Add support for additional Xiaomi BLE sensors (#1027)"

This reverts commit b2723830f4.

* initial ATC Mithermometer component

* removed references to xiaomi_ble

* temp, humi and batt in % working, todo: battery in mV

* report battery level in volt

* report battery level again in percent

* Add files via upload

* add ATC Mithermometer component

* remove some comments

* fix travis ci build issues

* mark codeowner, make functions protected

* add newlines, remove spaces

* two lines after function or class definition

* update codeowners

* Bump flake8 from 3.8.3 to 3.8.4

Bumps [flake8](https://gitlab.com/pycqa/flake8) from 3.8.3 to 3.8.4.
- [Release notes](https://gitlab.com/pycqa/flake8/tags)
- [Commits](https://gitlab.com/pycqa/flake8/compare/3.8.3...3.8.4)

Signed-off-by: dependabot[bot] <support@github.com>

* Add files via upload

* Bump pytest from 6.0.2 to 6.1.1

Bumps [pytest](https://github.com/pytest-dev/pytest) from 6.0.2 to 6.1.1.
- [Release notes](https://github.com/pytest-dev/pytest/releases)
- [Changelog](https://github.com/pytest-dev/pytest/blob/master/CHANGELOG.rst)
- [Commits](https://github.com/pytest-dev/pytest/compare/6.0.2...6.1.1)

Signed-off-by: dependabot[bot] <support@github.com>

* add ATC battery voltage to test2.yaml

* fix lint-python

* Bump colorlog from 4.2.1 to 4.4.0

Bumps [colorlog](https://github.com/borntyping/python-colorlog) from 4.2.1 to 4.4.0.
- [Release notes](https://github.com/borntyping/python-colorlog/releases)
- [Commits](https://github.com/borntyping/python-colorlog/compare/v4.2.1...v4.4.0)

Signed-off-by: dependabot[bot] <support@github.com>

* Bump voluptuous from 0.11.7 to 0.12.0

Bumps [voluptuous](https://github.com/alecthomas/voluptuous) from 0.11.7 to 0.12.0.
- [Release notes](https://github.com/alecthomas/voluptuous/releases)
- [Changelog](https://github.com/alecthomas/voluptuous/blob/master/CHANGELOG.md)
- [Commits](https://github.com/alecthomas/voluptuous/commits/v0.12.0)

Signed-off-by: dependabot[bot] <support@github.com>

* restore requirements

* move codeowner above dependencies

* Revert "restore requirements"

This reverts commit 3c9fd8b421.

* Revert "Bump voluptuous from 0.11.7 to 0.12.0"

This reverts commit 8eb0dba1c3.

* Revert "Bump flake8 from 3.8.3 to 3.8.4"

This reverts commit 20952632db.

* Revert "Bump colorlog from 4.2.1 to 4.4.0"

This reverts commit 87bbf95d86.

* Revert "Bump pytest from 6.0.2 to 6.1.1"

This reverts commit 1b6ed80431.

Co-authored-by: vevsvevs <v-v@mail.ru>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-11-04 06:36:11 +13:00
Dimitris Zervas
e536316e3d
Add contrast option to PCD8544 (#1348)
* Add contrast option to PCD8544. Closes #1519

* Minor fixes as instructed by @jesserockz
2020-11-03 10:05:20 +13:00
Jesse Hills
a6c46eb8e5
Adds support for RF Bridge advanced codes (#1246)
* WIP: Advanced commands for portisch firmware

* Fix string code sending

* clang formatting

* Add new rf_bridge functions to test

* Add advanced code received trigger

* Fix copy-paste mistake in the advanced sending

* Fix log message to be consistent

* clang

* Remove extra +
2020-11-03 07:34:29 +13:00