mirror of
				https://github.com/esphome/esphome.git
				synced 2025-10-30 22:53:59 +00:00 
			
		
		
		
	[i2c] Workaround for i2c on s2 (#8188)
This commit is contained in:
		| @@ -39,6 +39,10 @@ void IDFI2CBus::setup() { | |||||||
|   conf.scl_io_num = scl_pin_; |   conf.scl_io_num = scl_pin_; | ||||||
|   conf.scl_pullup_en = scl_pullup_enabled_; |   conf.scl_pullup_en = scl_pullup_enabled_; | ||||||
|   conf.master.clk_speed = frequency_; |   conf.master.clk_speed = frequency_; | ||||||
|  | #ifdef USE_ESP32_VARIANT_ESP32S2 | ||||||
|  |   // workaround for https://github.com/esphome/issues/issues/6718 | ||||||
|  |   conf.clk_flags = I2C_SCLK_SRC_FLAG_AWARE_DFS; | ||||||
|  | #endif | ||||||
|   esp_err_t err = i2c_param_config(port_, &conf); |   esp_err_t err = i2c_param_config(port_, &conf); | ||||||
|   if (err != ESP_OK) { |   if (err != ESP_OK) { | ||||||
|     ESP_LOGW(TAG, "i2c_param_config failed: %s", esp_err_to_name(err)); |     ESP_LOGW(TAG, "i2c_param_config failed: %s", esp_err_to_name(err)); | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user