mirror of
https://github.com/embassy-rs/embassy.git
synced 2024-11-22 06:42:32 +00:00
parent
9a447f1359
commit
9772645718
@ -268,9 +268,9 @@ impl<'d, U: UarteInstance, T: TimerInstance> embedded_io::asynch::BufRead
|
||||
|
||||
fn consume(&mut self, amt: usize) {
|
||||
let signal = self.inner.with(|state| {
|
||||
let empty = state.rx.is_empty();
|
||||
let full = state.rx.is_full();
|
||||
state.rx.pop(amt);
|
||||
!empty
|
||||
full
|
||||
});
|
||||
if signal {
|
||||
self.inner.pend();
|
||||
|
Loading…
Reference in New Issue
Block a user