forked from NaxdyOrg/NaxGCC-FW
fix(input): don't use raw waker (embassy)
This commit is contained in:
parent
4077220f27
commit
3514463dbb
1 changed files with 4 additions and 2 deletions
|
@ -135,9 +135,11 @@ async fn update_stick_states<
|
||||||
let mut cy_sum = 0u32;
|
let mut cy_sum = 0u32;
|
||||||
|
|
||||||
// TODO: lower interval possible?
|
// TODO: lower interval possible?
|
||||||
let mut timer = Timer::at(Instant::now() + embassy_time::Duration::from_millis(1));
|
|
||||||
|
|
||||||
while embassy_futures::poll_once(&mut timer) != Poll::Ready(()) {
|
let end_time = Instant::now() + embassy_time::Duration::from_millis(1);
|
||||||
|
let timer = Timer::at(end_time);
|
||||||
|
|
||||||
|
while Instant::now() < end_time {
|
||||||
adc_count += 1;
|
adc_count += 1;
|
||||||
ax_sum += read_ext_adc(
|
ax_sum += read_ext_adc(
|
||||||
Stick::ControlStick,
|
Stick::ControlStick,
|
||||||
|
|
Loading…
Add table
Reference in a new issue