mirror of
https://github.com/esphome/esphome.git
synced 2024-12-27 07:51:43 +01:00
fix clang
This commit is contained in:
parent
df37248308
commit
6c36f0c969
1 changed files with 2 additions and 5 deletions
|
@ -22,9 +22,7 @@ void UsbDevice::update() {
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
void UsbDevice::dump_config() {
|
void UsbDevice::dump_config() { ESP_LOGCONFIG(TAG, "USB device - configured: %s", YESNO(get_configured_())); }
|
||||||
ESP_LOGCONFIG(TAG, "USB device - configured: %s", YESNO(get_configured_()));
|
|
||||||
}
|
|
||||||
|
|
||||||
#ifdef USE_BINARY_SENSOR
|
#ifdef USE_BINARY_SENSOR
|
||||||
void UsbDevice::set_configured_binary_sensor(binary_sensor::BinarySensor *sensor) { configured_ = sensor; };
|
void UsbDevice::set_configured_binary_sensor(binary_sensor::BinarySensor *sensor) { configured_ = sensor; };
|
||||||
|
@ -34,7 +32,7 @@ bool UsbDevice::get_configured_() {
|
||||||
// based on defines in HWCDC.cpp
|
// based on defines in HWCDC.cpp
|
||||||
#if CONFIG_IDF_TARGET_ESP32C3 || CONFIG_IDF_TARGET_ESP32S3
|
#if CONFIG_IDF_TARGET_ESP32C3 || CONFIG_IDF_TARGET_ESP32S3
|
||||||
#if ARDUINO_USB_MODE
|
#if ARDUINO_USB_MODE
|
||||||
#if ARDUINO_USB_CDC_ON_BOOT//Serial used for USB CDC
|
#if ARDUINO_USB_CDC_ON_BOOT // Serial used for USB CDC
|
||||||
return Serial;
|
return Serial;
|
||||||
#else
|
#else
|
||||||
return USBSerial;
|
return USBSerial;
|
||||||
|
@ -52,7 +50,6 @@ bool UsbDevice::get_configured_() {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
} // namespace usb_device
|
} // namespace usb_device
|
||||||
} // namespace esphome
|
} // namespace esphome
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Reference in a new issue