Skip to content

Commit 9b71709

Browse files
committed
defer callback for hw encoder to ada callback
1 parent 509d55f commit 9b71709

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

changelog.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
- Added systemOff() to enter hibernate mode
99
- Correct waitForEvent() function with SoftDevice enabled and disabled.
1010
- Added RotaryEncoder support for both Hardware and Software Encoder.
11+
- Ada Callback task is started along with loop task, used as worker thread to defer interrupt callback.
1112

1213
## 0.7.0
1314

libraries/RotaryEncoder/RotaryEncoder.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -198,7 +198,7 @@ void HwRotaryEncoder::_irq_handler(void)
198198
if ( _cb )
199199
{
200200
int32_t step = read();
201-
if ( step ) _cb(step);
201+
if ( step ) ada_callback(NULL, _cb, step);
202202
}
203203
}
204204
}

0 commit comments

Comments
 (0)