-
Notifications
You must be signed in to change notification settings - Fork 7.6k
AttachInterrupt does not work on output of PWM (2.0.2) #6140
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
@P-R-O-C-H-Y will you please give this a shot? |
I'm looking into the I can't get the ESP32 to output PWM signal on GPIO pins since 2.0.2 (at least not using the same code as before) |
Hi @mstegen, move function
@TD-er The LEDC PWM outputs are working as normal :) No problem in 2.0.2 |
OK will test. |
@TD-er Yes, tried with 2.0.2 and 2.0.0 and both works as expected :) |
I probably found why it isn't working on my setup. Ah apparently that code of mine is no longer needed as it is now implemented here: |
Great @P-R-O-C-H-Y ! thanks a lot for fixing this. |
Are you sure? It worked with the old version. I'm using MCPWM to generate PWM and also attached an interrupt to the Pin. It worked until today after upgrading from 3.x to the new 6.5. It was working pretty nice so it is possible. After setting up MCPWM I used Edit: Removing the pinMode() call seems to make it work again. But also have big issues with I2S now producing totally messed up readings. |
Board
ESP32Dev module
Device Description
I'm using a PWM output, and setup a pin interrupt so i can detect the start of the PWM signal.
This works fine in 2.0.1, but not on 2.0.2
Hardware Configuration
no
Version
latest master
IDE Name
PlatfromIO
Operating System
Win10/Linux
Flash frequency
80Mhz
PSRAM enabled
no
Upload speed
115200
Description
attachInterrupt
should be able to attach to the output signal of the PWM signal generated by ledC.this does work in 2.0.1, but not in 2.0.2.
I noticed that there were changes made to the LEDC code (#6045)
when using the old (2.0.1) code for
ledcAttachPin
in my code, it works again.So something in the new code, does not allow a PIN interrupt to be attached to the PWM output.
Below is test code to reproduce the problem.
Sketch
Debug Message
Other Steps to Reproduce
No response
I have checked existing issues, online documentation and the Troubleshooting Guide
The text was updated successfully, but these errors were encountered: