|
|
@@ -22,7 +22,15 @@
|
|
|
|
|
|
|
|
|
chlcd_error_t chlcd_pin_set_output(chlcd_pin_t target) {
|
|
|
- if (gpio_output_enable(target) == ESP_OK) {
|
|
|
+ gpio_config_t config[1] = {0};
|
|
|
+
|
|
|
+ config->pin_bit_mask = 1UL << target;
|
|
|
+ config->mode = GPIO_MODE_OUTPUT;
|
|
|
+ config->pull_up_en = GPIO_PULLUP_DISABLE;
|
|
|
+ config->pull_down_en = GPIO_PULLDOWN_DISABLE;
|
|
|
+ config->intr_type = GPIO_INTR_DISABLE
|
|
|
+
|
|
|
+ if (gpio_config(config) == ESP_OK) {
|
|
|
return CHLCD_SUCCESS;
|
|
|
}
|
|
|
|