Skip to content
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

Got error messages in Arduino IDE v3.0.1(ESP32C3) something like timerAlarm or void gpio_intr() #2107

Closed
ChenYuChunEric opened this issue Jun 16, 2024 · 1 comment

Comments

@ChenYuChunEric
Copy link

Version/revision of the library used

IRremoteESP8266 v2.8.6 on Jul 28, 2023.

Describe the bug

Today I upgraded ESP32 board to v3.0.1, but when I uploaded my code it showed error messages while compiling or uploading code that with IRremoteESP8266 lib in EPS32C3.
The Arduion IDE version 2.3.2, and ESP32 board version 3.0.1.
The error messages like below:

d:\�{���g�@\�{���y����Ƨ�\libraries\IRremoteESP8266\src\IRrecv.cpp: In function 'void gpio_intr()':
d:\�{���g�@\�{���y����Ƨ�\libraries\IRremoteESP8266\src\IRrecv.cpp:246:3: error: 'timerAlarmEnable' was not declared in this scope; did you mean 'timerAlarm'?
246 | timerAlarmEnable(timer);
| ^~~~~~~~~~~~~~~~
| timerAlarm
d:\�{���g�@\�{���y����Ƨ�\libraries\IRremoteESP8266\src\IRrecv.cpp: In member function 'void IRrecv::enableIRIn(bool)':
d:\�{���g�@\�{���y����Ƨ�\libraries\IRremoteESP8266\src\IRrecv.cpp:362:21: error: too many arguments to function 'hw_timer_t* timerBegin(uint32_t)'
362 | timer = timerBegin(_timer_num, 80, true);
| ~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~
In file included from C:\Users\User\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.1\cores\esp32/esp32-hal.h:84,
from C:\Users\User\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.1\cores\esp32/Arduino.h:36,
from d:\�{���g�@\�{���y����Ƨ�\libraries\IRremoteESP8266\src\IRrecv.h:10,
from d:\�{���g�@\�{���y����Ƨ�\libraries\IRremoteESP8266\src\IRrecv.cpp:6:
C:\Users\User\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.1\cores\esp32/esp32-hal-timer.h:35:13: note: declared here
35 | hw_timer_t timerBegin(uint32_t frequency);
| ^~~~~~~~~~
d:\�{���g�@\�{���y����Ƨ�\libraries\IRremoteESP8266\src\IRrecv.cpp:371:3: error: 'timerAlarmWrite' was not declared in this scope; did you mean 'timerWrite'?
371 | timerAlarmWrite(timer, MS_TO_USEC(params.timeout), ONCE);
| ^~~~~~~~~~~~~~~
| timerWrite
d:\�{���g�@\�{���y����Ƨ�\libraries\IRremoteESP8266\src\IRrecv.cpp:375:23: error: too many arguments to function 'void timerAttachInterrupt(hw_timer_t
, void (*)())'
375 | timerAttachInterrupt(timer, &read_timeout, false);
| ~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
C:\Users\User\AppData\Local\Arduino15\packages\esp32\hardware\esp32\3.0.1\cores\esp32/esp32-hal-timer.h:50:6: note: declared here
50 | void timerAttachInterrupt(hw_timer_t *timer, void (*userFunc)(void));
| ^~~~~~~~~~~~~~~~~~~~
d:\�{���g�@\�{���y����Ƨ�\libraries\IRremoteESP8266\src\IRrecv.cpp: In member function 'void IRrecv::disableIRIn()':
d:\�{���g�@\�{���y����Ƨ�\libraries\IRremoteESP8266\src\IRrecv.cpp:401:3: error: 'timerAlarmDisable' was not declared in this scope
401 | timerAlarmDisable(timer);
| ^~~~~~~~~~~~~~~~~
d:\�{���g�@\�{���y����Ƨ�\libraries\IRremoteESP8266\src\IRrecv.cpp: In member function 'void IRrecv::pause()':
d:\�{���g�@\�{���y����Ƨ�\libraries\IRremoteESP8266\src\IRrecv.cpp:416:3: error: 'gpio_intr_disable' was not declared in this scope; did you mean 'esp_intr_disable'?
416 | gpio_intr_disable((gpio_num_t)params.recvpin);
| ^~~~~~~~~~~~~~~~~
| esp_intr_disable
d:\�{���g�@\�{���y����Ƨ�\libraries\IRremoteESP8266\src\IRrecv.cpp: In member function 'void IRrecv::resume()':
d:\�{���g�@\�{���y����Ƨ�\libraries\IRremoteESP8266\src\IRrecv.cpp:429:3: error: 'timerAlarmDisable' was not declared in this scope
429 | timerAlarmDisable(timer);
| ^~~~~~~~~~~~~~~~~
d:\�{���g�@\�{���y����Ƨ�\libraries\IRremoteESP8266\src\IRrecv.cpp:430:3: error: 'gpio_intr_enable' was not declared in this scope; did you mean 'esp_intr_enable'?
430 | gpio_intr_enable((gpio_num_t)params.recvpin);
| ^~~~~~~~~~~~~~~~
| esp_intr_enable
exit status 1
Compilation error: exit status 1

To Reproduce

Opened example code in Arduino IDE, but once clicked upload or compile button, it got error messages.

Expected behaviour

Can compile and upload code to ESP32C3 in version 3.0.1.

I have followed the steps in the [Troubleshooting Guide]

Yes

Has this library/code previously worked as expected for you?

Yes
In Arduino IDE ESP32 v 2.0.17

@NiKiZe
Copy link
Collaborator

NiKiZe commented Jun 16, 2024

Closing as duplicate of #2039

@NiKiZe NiKiZe closed this as completed Jun 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants