You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Pin D5 is set in INPUT_PULLUP mode and connected to a push button to GND.
Version
v3.0.4
IDE Name
PlatformIO
Operating System
Arch Linux
Flash frequency
80Mhz
PSRAM enabled
no
Upload speed
460800
Description
When i use the function attachInterrupt(digitalPinToGPIONumber(D5), change_state, CHANGE); the pin that handle interrupt is the D8 pin despite I use digitalPinToGPIONumber(D5). On the same board interrupt worked until about begin of August then stopped to work, I also rollback to 2.0.16 version of arduino-esp32 but still no works. Can be a problem of the board?
Hello @andreock, I suspect the problem is your use of the digitalPinToGPIONumber function. These should really be used only when directly writing to a CPU register or something like that; for Arduino APIs, this detail should be handled by the core for you, transparently, regardless of the Pin Mapping setting in the IDE.
Sorry, I made a typo in the previous question, I use digitalPinToInterrupt not digitalPinToGPIONumber. By the way if I use attachInterrupt(D5, ...) with the current SDK(3.0.4) works. I was sure I had tried yesterday attachInterrupt(D5,...) without digitalPinToInterrupt(), Sorry for the useless issue.
Board
Arduino Nano ESP32
Device Description
Arduino Nano ESP32
Hardware Configuration
Pin D5 is set in INPUT_PULLUP mode and connected to a push button to GND.
Version
v3.0.4
IDE Name
PlatformIO
Operating System
Arch Linux
Flash frequency
80Mhz
PSRAM enabled
no
Upload speed
460800
Description
When i use the function attachInterrupt(digitalPinToGPIONumber(D5), change_state, CHANGE); the pin that handle interrupt is the D8 pin despite I use digitalPinToGPIONumber(D5). On the same board interrupt worked until about begin of August then stopped to work, I also rollback to 2.0.16 version of arduino-esp32 but still no works. Can be a problem of the board?
EDIT: 2.0.14 works
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: