ESP32 GPIO25 and GPIO26 as standard Output

maxl_1989
Posts: 2
Joined: Tue Feb 05, 2019 9:59 pm

ESP32 GPIO25 and GPIO26 as standard Output

Postby maxl_1989 » Tue Feb 05, 2019 10:07 pm

Hello

i already have spent a lot of hours to find out how to set the GPIO25 as output.
i have tried a lot of things but nothing work for me!

This example code work for me to set the GPIO_NUM_33 to Output but not for the GPIO_NUM_25.
gpio_config_t io_conf;
io_conf.intr_type = GPIO_INTR_DISABLE;
io_conf.mode = GPIO_MODE_OUTPUT;
io_conf.pin_bit_mask = (1ULL << GPIO_NUM_25);
io_conf.pull_down_en = GPIO_PULLDOWN_DISABLE;
io_conf.pull_up_en = GPIO_PULLUP_DISABLE;
gpio_config(&io_conf);
gpio_set_level(GPIO_NUM_25, 1);

Can anybody please post me an example code how to set the GPIO25 output.
I dont wont to use the gpios in rtc mode, i want to use it in normal GPIO mode.

Thanks in advance!
best regards,
Markus

permal
Posts: 384
Joined: Sun May 14, 2017 5:36 pm

Re: ESP32 GPIO25 and GPIO26 as standard Output

Postby permal » Wed Feb 06, 2019 2:47 pm

I do it like this for all my outputs: https://github.com/PerMalmberg/Smooth/b ... ut.cpp#L17

I don't see a reason you'd have issues with GPIO 25, it's not a strapping pin. What module are you using, and what is the actual problem?

maxl_1989
Posts: 2
Joined: Tue Feb 05, 2019 9:59 pm

Re: ESP32 GPIO25 and GPIO26 as standard Output

Postby maxl_1989 » Wed Feb 06, 2019 3:07 pm

i use a esp32-wroom-32 module.
my problem is, i can't set an output level.
i think the GPIO25 is default configured to DAC, so is it enought when i only do the gpio_config(&config) to set it as normal output gpio?

ESP_Sprite
Posts: 9016
Joined: Thu Nov 26, 2015 4:08 am

Re: ESP32 GPIO25 and GPIO26 as standard Output

Postby ESP_Sprite » Thu Feb 07, 2019 5:13 am

Unless you're specifically using I2S-related calls to configure these pins as a DAC, they're normal GPIOs.

permal
Posts: 384
Joined: Sun May 14, 2017 5:36 pm

Re: ESP32 GPIO25 and GPIO26 as standard Output

Postby permal » Thu Feb 07, 2019 7:56 am

maxl_1989 wrote: i use a esp32-wroom-32 module.
my problem is, i can't set an output level.
Is the call returning an error or don't you get the desired voltage on the pin? Do you have a schematic? Could it be that something is pulling it low hard?

Who is online

Users browsing this forum: Google [Bot] and 145 guests