diff options
| author | Ruben De Smet <[email protected]> | 2023-08-11 11:58:22 +0200 |
|---|---|---|
| committer | Ruben De Smet <[email protected]> | 2023-08-22 16:58:31 +0200 |
| commit | c39671266e21dd9e35e60cc680453cd5c38162db (patch) | |
| tree | 895dbbcefb90af1fd65c8844c1e5785a909b0671 /examples/stm32f3/src | |
| parent | b1ec460b9af131ef80fcafd79a7f63aa326aaf94 (diff) | |
Deprecate *recv* in favor of *receive*
Diffstat (limited to 'examples/stm32f3/src')
| -rw-r--r-- | examples/stm32f3/src/bin/button_events.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/examples/stm32f3/src/bin/button_events.rs b/examples/stm32f3/src/bin/button_events.rs index 02c475f66..8e97e85eb 100644 --- a/examples/stm32f3/src/bin/button_events.rs +++ b/examples/stm32f3/src/bin/button_events.rs | |||
| @@ -49,12 +49,12 @@ impl<'a> Leds<'a> { | |||
| 49 | 49 | ||
| 50 | async fn show(&mut self) { | 50 | async fn show(&mut self) { |
| 51 | self.leds[self.current_led].set_high(); | 51 | self.leds[self.current_led].set_high(); |
| 52 | if let Ok(new_message) = with_timeout(Duration::from_millis(500), CHANNEL.recv()).await { | 52 | if let Ok(new_message) = with_timeout(Duration::from_millis(500), CHANNEL.receive()).await { |
| 53 | self.leds[self.current_led].set_low(); | 53 | self.leds[self.current_led].set_low(); |
| 54 | self.process_event(new_message).await; | 54 | self.process_event(new_message).await; |
| 55 | } else { | 55 | } else { |
| 56 | self.leds[self.current_led].set_low(); | 56 | self.leds[self.current_led].set_low(); |
| 57 | if let Ok(new_message) = with_timeout(Duration::from_millis(200), CHANNEL.recv()).await { | 57 | if let Ok(new_message) = with_timeout(Duration::from_millis(200), CHANNEL.receive()).await { |
| 58 | self.process_event(new_message).await; | 58 | self.process_event(new_message).await; |
| 59 | } | 59 | } |
| 60 | } | 60 | } |
