File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -128,8 +128,8 @@ static int i2c_gpio_init(const struct device *dev)
128
128
return - EINVAL ;
129
129
}
130
130
131
- err = gpio_config (context -> scl_gpio , config -> scl_pin ,
132
- config -> scl_flags | GPIO_OUTPUT_HIGH );
131
+ err = gpio_pin_configure (context -> scl_gpio , config -> scl_pin ,
132
+ config -> scl_flags | GPIO_OUTPUT_HIGH );
133
133
if (err ) {
134
134
LOG_ERR ("failed to configure SCL GPIO pin (err %d)" , err );
135
135
return err ;
@@ -141,11 +141,11 @@ static int i2c_gpio_init(const struct device *dev)
141
141
return - EINVAL ;
142
142
}
143
143
144
- err = gpio_config (context -> sda_gpio , config -> sda_pin ,
145
- config -> sda_flags | GPIO_INPUT | GPIO_OUTPUT_HIGH );
144
+ err = gpio_pin_configure (context -> sda_gpio , config -> sda_pin ,
145
+ config -> sda_flags | GPIO_INPUT | GPIO_OUTPUT_HIGH );
146
146
if (err == - ENOTSUP ) {
147
- err = gpio_config (context -> sda_gpio , config -> sda_pin ,
148
- config -> sda_flags | GPIO_OUTPUT_HIGH );
147
+ err = gpio_pin_configure (context -> sda_gpio , config -> sda_pin ,
148
+ config -> sda_flags | GPIO_OUTPUT_HIGH );
149
149
}
150
150
if (err ) {
151
151
LOG_ERR ("failed to configure SDA GPIO pin (err %d)" , err );
You can’t perform that action at this time.
0 commit comments