mirror of
https://github.com/esphome/esphome.git
synced 2024-12-23 16:47:57 +01:00
Use proper schema for the analog pin shorthand (#2103)
The wrong error message is displayed like: > GPIO17 (TOUT) is an analog-only pin on the ESP8266. in case of the analog pin validation because the method `shorthand_analog_pin` uses wrong `GPIO_FULL_INPUT_PIN_SCHEMA` instead of `GPIO_FULL_ANALOG_PIN_SCHEMA`.
This commit is contained in:
parent
a8b90283d8
commit
593a3d48fb
@ -271,7 +271,7 @@ def shorthand_input_pullup_pin(value):
|
|||||||
|
|
||||||
def shorthand_analog_pin(value):
|
def shorthand_analog_pin(value):
|
||||||
value = analog_pin(value)
|
value = analog_pin(value)
|
||||||
return GPIO_FULL_INPUT_PIN_SCHEMA({CONF_NUMBER: value})
|
return GPIO_FULL_ANALOG_PIN_SCHEMA({CONF_NUMBER: value})
|
||||||
|
|
||||||
|
|
||||||
def validate_has_interrupt(value):
|
def validate_has_interrupt(value):
|
||||||
|
Loading…
Reference in New Issue
Block a user