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
ESP32 GPIO25 and GPIO26 as standard Output
Re: ESP32 GPIO25 and GPIO26 as standard Output
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?
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?
Re: ESP32 GPIO25 and GPIO26 as standard Output
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?
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?
-
- Posts: 9766
- Joined: Thu Nov 26, 2015 4:08 am
Re: ESP32 GPIO25 and GPIO26 as standard Output
Unless you're specifically using I2S-related calls to configure these pins as a DAC, they're normal GPIOs.
Re: ESP32 GPIO25 and GPIO26 as standard Output
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?maxl_1989 wrote: i use a esp32-wroom-32 module.
my problem is, i can't set an output level.
Who is online
Users browsing this forum: Sang_Huynh and 192 guests