I known that the ESP32 uses the GPIOs12, 13, 14, 15 for JTAG and that it is possible to configure them as "normal" IOs (mainly as outputs), but no matter what I try I dont succed reconfiguring those pins.
I have tried to use the methods below (for pin 14), but also other hints I found on the web. Unfortunately they all didnt work for me. The led connected to port 14 just flickers a bit (not only during bot as expected), but I cant turn it on and of in a controlled fashion. Btw, apart from the problems with those special pins my code works as expected.
Not working gpio_config
Code: Select all
gpio_config_t config;
config.pin_bit_mask = (1 << 14);
config.mode = GPIO_MODE_INPUT_OUTPUT;
config.pull_up_en = GPIO_PULLUP_ENABLE;
config.pull_down_en = GPIO_PULLDOWN_DISABLE;
config.intr_type = GPIO_INTR_DISABLE;
gpio_config(&config);
pinMode(14, OUTPUT);
Code: Select all
PIN_FUNC_SELECT(GPIO_PIN_MUX_REG[14], PIN_FUNC_GPIO);
pinMode(14, OUTPUT);
I'd be grateful if someone could post a working arduino example how to use those pins as "normal" GPIOs.
Thanks for your help.