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

Fix Esp32 hardware timer callbacks #2716

Merged
merged 3 commits into from
Jan 31, 2024

Conversation

mikee47
Copy link
Contributor

@mikee47 mikee47 commented Jan 31, 2024

Fix esp32 hardware timer callbacks

PR #2697 was supposed to fix the WDT from hardware timer interrupts.
It did this by disabling interrupts (and therefore callbacks) completely.

The actual reason for the WDT is twofold:

  1. IDF version 5 changed some low-level HAL calls to accept bit masks instead of timer index.
  2. Argument to interrupt callback wasn't stored or passed correctly so user-provided callback got junk for this parameter.

This PR fixes those issues and fixes incomplete testing in HostTests.

Also checked Basic_Blink sample using HardwareTimer.

mikee47 added 3 commits January 31, 2024 12:27
PR SmingHub#2697 was supposed to fix the WDT from hardware timer interrupts.
It did this by disabling interrupts (and therefore callbacks) completely.

The actual reason for the WDT is twofold:

1. IDF version 5 changed some low-level HAL calls to accept bit masks instead of timer index.
2. Argument to interrupt callback wasn't stored or passed correctly so user-provided callback got junk for this parameter.
@slaff slaff added this to the 5.2.0 milestone Jan 31, 2024
@slaff slaff merged commit 02a403f into SmingHub:develop Jan 31, 2024
46 checks passed
@slaff slaff mentioned this pull request Feb 5, 2024
5 tasks
@mikee47 mikee47 deleted the fix/esp32-hwtimer-callback branch March 16, 2024 14:25
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

Successfully merging this pull request may close these issues.

2 participants