diff --git a/include/sensirion_i2c_hal.h b/include/sensirion_i2c_hal.h index 98e3611..4ccbe6f 100644 --- a/include/sensirion_i2c_hal.h +++ b/include/sensirion_i2c_hal.h @@ -54,7 +54,7 @@ int16_t sensirion_i2c_hal_select_bus(uint8_t bus_idx); * Initialize all hard- and software components that are needed for the I2C * communication. */ -void sensirion_i2c_hal_init(int SDA, int SCL); +void sensirion_i2c_hal_init(); /** * Release all resources initialized by sensirion_i2c_hal_init(). diff --git a/sensirion_i2c_hal.c b/sensirion_i2c_hal.c index 59556ec..4567058 100644 --- a/sensirion_i2c_hal.c +++ b/sensirion_i2c_hal.c @@ -65,27 +65,15 @@ int16_t sensirion_i2c_hal_select_bus(uint8_t bus_idx) { * Initialize all hard- and software components that are needed for the I2C * communication. */ -void sensirion_i2c_hal_init(int SDA, int SCL) { - int i2c_master_port = I2C_NUM_0; - i2c_config_t conf = { - .mode = I2C_MODE_MASTER, - .sda_io_num = SDA, // select GPIO specific to your project - .sda_pullup_en = GPIO_PULLUP_ENABLE, - .scl_io_num = SCL, // select GPIO specific to your project - .scl_pullup_en = GPIO_PULLUP_ENABLE, - .master.clk_speed = 10000, // select frequency specific to your project - // .clk_flags = 0, /*!< Optional, you can use I2C_SCLK_SRC_FLAG_* flags to choose i2c source clock here. */ - }; - i2c_param_config(i2c_master_port, &conf); - - i2c_driver_install(i2c_master_port, I2C_MODE_MASTER, 0, 0, 0); +void sensirion_i2c_hal_init() { + } /** * Release all resources initialized by sensirion_i2c_hal_init(). */ void sensirion_i2c_hal_free(void) { - i2c_driver_delete(I2C_NUM_0); /* TODO:non const port */ + } /**