Search found 3 matches

by Auxal3000
Tue Mar 03, 2020 11:07 pm
Forum: ESP32 Arduino
Topic: ledc doesn't work after restart or deep sleep wakeup
Replies: 2
Views: 4444

Re: ledc doesn't work after restart or deep sleep wakeup

Solution found

I have seen that before to enter to sleep mode I used the instruction:

Code: Select all

rtc_gpio_hold_en(GPIO_NUM_4);
This block this GPIO to prevent any changes in this pin.
After restart, the chip must execute the instruction:

Code: Select all

rtc_gpio_hold_dis(GPIO_NUM_4);
to unblock it.
by Auxal3000
Thu Feb 27, 2020 10:51 am
Forum: ESP32 Arduino
Topic: ledc doesn't work after restart or deep sleep wakeup
Replies: 2
Views: 4444

Re: ledc doesn't work after restart or deep sleep wakeup

I forgot to send the code:

Before setup:

Code: Select all

#define ledFlash           4 
into setup():

Code: Select all

    ledcSetup(LEDC_CHANNEL_7, 12000, 9); 
    ledcAttachPin(ledFlash, LEDC_CHANNEL_7);
    ledcWrite(LEDC_CHANNEL_7, 0);
into loop():

Code: Select all

 ledcWrite(LEDC_CHANNEL_7, 50);
by Auxal3000
Thu Feb 27, 2020 2:52 am
Forum: ESP32 Arduino
Topic: ledc doesn't work after restart or deep sleep wakeup
Replies: 2
Views: 4444

ledc doesn't work after restart or deep sleep wakeup

Hello
I'm using a ESP32 CAM that has a Led-flash included. I initialize the led in the program and it works ok. But if I call ESP.restart() or after a sleep wake up and the ledc is always of.
I don't know what to do.
Thanks for any help