mirror of
https://github.com/arendst/Tasmota.git
synced 2025-07-25 11:46:31 +00:00
upd
This commit is contained in:
parent
f6572a863b
commit
95bdb15ae9
@ -1338,7 +1338,7 @@ int ICACHE_RAM_ATTR Pin(uint32_t gpio, uint32_t index) {
|
||||
|
||||
bool PinUsed(uint32_t gpio, uint32_t index = 0);
|
||||
bool PinUsed(uint32_t gpio, uint32_t index) {
|
||||
return (Pin(gpio, index) > -1);
|
||||
return (Pin(gpio, index) >= 0);
|
||||
}
|
||||
|
||||
uint32_t GetPin(uint32_t lpin) {
|
||||
|
@ -412,7 +412,7 @@ void SetLedLink(uint32_t state)
|
||||
if (-1 == led_pin) { // Legacy - LED1 is status
|
||||
SetLedPowerIdx(0, state);
|
||||
}
|
||||
else if (led_pin > -1) {
|
||||
else if (led_pin >= 0) {
|
||||
if (state) { state = 1; }
|
||||
digitalWrite(led_pin, (led_inv) ? !state : state);
|
||||
}
|
||||
@ -717,7 +717,7 @@ void MqttPublishTeleState(void)
|
||||
MqttShowState();
|
||||
MqttPublishPrefixTopic_P(TELE, PSTR(D_RSLT_STATE), MQTT_TELE_RETAIN);
|
||||
|
||||
#ifdef USE_DT_VARS
|
||||
#ifdef USE_DT_VARS
|
||||
DTVarsTeleperiod();
|
||||
#endif // USE_DT_VARS
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user