diff --git a/esphome/components/bluetooth_proxy/bluetooth_connection.cpp b/esphome/components/bluetooth_proxy/bluetooth_connection.cpp index cb07c41c22..bf39790712 100644 --- a/esphome/components/bluetooth_proxy/bluetooth_connection.cpp +++ b/esphome/components/bluetooth_proxy/bluetooth_connection.cpp @@ -360,13 +360,13 @@ esp_err_t BluetoothConnection::read_descriptor(uint16_t handle) { this->address_str().c_str()); return ESP_GATT_NOT_CONNECTED; } - ESP_LOGV(TAG, "[%d] [%s] Reading GATT descriptor handle %d", this->get_connection_index(), - this->address_str().c_str(), handle); + ESP_LOGV(TAG, "[%d] [%s] Reading GATT descriptor handle %d", this->get_connection_index(), this->address_str_.c_str(), + handle); esp_err_t err = esp_ble_gattc_read_char_descr(this->gattc_if_, this->conn_id_, handle, ESP_GATT_AUTH_REQ_NONE); if (err != ERR_OK) { ESP_LOGW(TAG, "[%d] [%s] esp_ble_gattc_read_char_descr error, err=%d", this->get_connection_index(), - this->address_str().c_str(), err); + this->address_str_.c_str(), err); return err; } return ESP_OK; @@ -378,15 +378,15 @@ esp_err_t BluetoothConnection::write_descriptor(uint16_t handle, const std::stri this->address_str().c_str()); return ESP_GATT_NOT_CONNECTED; } - ESP_LOGV(TAG, "[%d] [%s] Writing GATT descriptor handle %d", this->get_connection_index(), - this->address_str().c_str(), handle); + ESP_LOGV(TAG, "[%d] [%s] Writing GATT descriptor handle %d", this->get_connection_index(), this->address_str_.c_str(), + handle); esp_err_t err = esp_ble_gattc_write_char_descr( this->gattc_if_, this->conn_id_, handle, data.size(), (uint8_t *) data.data(), response ? ESP_GATT_WRITE_TYPE_RSP : ESP_GATT_WRITE_TYPE_NO_RSP, ESP_GATT_AUTH_REQ_NONE); if (err != ERR_OK) { ESP_LOGW(TAG, "[%d] [%s] esp_ble_gattc_write_char_descr error, err=%d", this->get_connection_index(), - this->address_str().c_str(), err); + this->address_str_.c_str(), err); return err; } return ESP_OK; @@ -405,7 +405,7 @@ esp_err_t BluetoothConnection::notify_characteristic(uint16_t handle, bool enabl esp_err_t err = esp_ble_gattc_register_for_notify(this->gattc_if_, this->remote_bda_, handle); if (err != ESP_OK) { ESP_LOGW(TAG, "[%d] [%s] esp_ble_gattc_register_for_notify failed, err=%d", this->get_connection_index(), - this->address_str().c_str(), err); + this->address_str_.c_str(), err); return err; } } else { @@ -414,7 +414,7 @@ esp_err_t BluetoothConnection::notify_characteristic(uint16_t handle, bool enabl esp_err_t err = esp_ble_gattc_unregister_for_notify(this->gattc_if_, this->remote_bda_, handle); if (err != ESP_OK) { ESP_LOGW(TAG, "[%d] [%s] esp_ble_gattc_unregister_for_notify failed, err=%d", this->get_connection_index(), - this->address_str().c_str(), err); + this->address_str_.c_str(), err); return err; } }