mirror of
https://github.com/esphome/esphome.git
synced 2024-11-14 10:26:53 +01:00
commit
4fb0f7f8c6
@ -128,7 +128,7 @@ void IRAM_ATTR ISRInternalGPIOPin::pin_mode(gpio::Flags flags) {
|
|||||||
auto *arg = reinterpret_cast<ISRPinArg *>(arg_);
|
auto *arg = reinterpret_cast<ISRPinArg *>(arg_);
|
||||||
gpio_set_direction(arg->pin, flags_to_mode(flags));
|
gpio_set_direction(arg->pin, flags_to_mode(flags));
|
||||||
gpio_pull_mode_t pull_mode = GPIO_FLOATING;
|
gpio_pull_mode_t pull_mode = GPIO_FLOATING;
|
||||||
if (flags & (gpio::FLAG_PULLUP | gpio::FLAG_PULLDOWN)) {
|
if ((flags & gpio::FLAG_PULLUP) && (flags & gpio::FLAG_PULLDOWN)) {
|
||||||
pull_mode = GPIO_PULLUP_PULLDOWN;
|
pull_mode = GPIO_PULLUP_PULLDOWN;
|
||||||
} else if (flags & gpio::FLAG_PULLUP) {
|
} else if (flags & gpio::FLAG_PULLUP) {
|
||||||
pull_mode = GPIO_PULLUP_ONLY;
|
pull_mode = GPIO_PULLUP_ONLY;
|
||||||
|
@ -132,16 +132,16 @@ bool BLEClientBase::gattc_event_handler(esp_gattc_cb_event_t event, esp_gatt_if_
|
|||||||
this->set_state(espbt::ClientState::IDLE);
|
this->set_state(espbt::ClientState::IDLE);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
if (this->connection_type_ == espbt::ConnectionType::V3_WITH_CACHE) {
|
|
||||||
this->set_state(espbt::ClientState::CONNECTED);
|
|
||||||
this->state_ = espbt::ClientState::ESTABLISHED;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
auto ret = esp_ble_gattc_send_mtu_req(this->gattc_if_, param->open.conn_id);
|
auto ret = esp_ble_gattc_send_mtu_req(this->gattc_if_, param->open.conn_id);
|
||||||
if (ret) {
|
if (ret) {
|
||||||
ESP_LOGW(TAG, "[%d] [%s] esp_ble_gattc_send_mtu_req failed, status=%x", this->connection_index_,
|
ESP_LOGW(TAG, "[%d] [%s] esp_ble_gattc_send_mtu_req failed, status=%x", this->connection_index_,
|
||||||
this->address_str_.c_str(), ret);
|
this->address_str_.c_str(), ret);
|
||||||
}
|
}
|
||||||
|
if (this->connection_type_ == espbt::ConnectionType::V3_WITH_CACHE) {
|
||||||
|
this->set_state(espbt::ClientState::CONNECTED);
|
||||||
|
this->state_ = espbt::ClientState::ESTABLISHED;
|
||||||
|
break;
|
||||||
|
}
|
||||||
esp_ble_gattc_search_service(esp_gattc_if, param->cfg_mtu.conn_id, nullptr);
|
esp_ble_gattc_search_service(esp_gattc_if, param->cfg_mtu.conn_id, nullptr);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
"""Constants used by esphome."""
|
"""Constants used by esphome."""
|
||||||
|
|
||||||
__version__ = "2022.12.3"
|
__version__ = "2022.12.4"
|
||||||
|
|
||||||
ALLOWED_NAME_CHARS = "abcdefghijklmnopqrstuvwxyz0123456789-_"
|
ALLOWED_NAME_CHARS = "abcdefghijklmnopqrstuvwxyz0123456789-_"
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user