diff options
author | Keith Packard <keithp@keithp.com> | 2010-08-29 22:42:23 -0700 |
---|---|---|
committer | Keith Packard <keithp@keithp.com> | 2010-08-29 22:42:23 -0700 |
commit | 43619c13f749b79c096d1e8fdab3d5cfb5fd85f1 (patch) | |
tree | e79aab1cf2f3b5e10acf924e7bd33b02663fc1bd | |
parent | c4a8569f61eddf690d00337543462235ecbfbe54 (diff) |
altos: Abort radio harder when terminating packet mode.
Make sure the master radio tasks don't get stuck waiting for an
incoming packet again by aborting the radio each time we poke the
tasks.
Signed-off-by: Keith Packard <keithp@keithp.com>
-rw-r--r-- | src/ao_packet_master.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/ao_packet_master.c b/src/ao_packet_master.c index 5e13a91a..50f5aeff 100644 --- a/src/ao_packet_master.c +++ b/src/ao_packet_master.c @@ -126,8 +126,8 @@ ao_packet_forward(void) __reentrant for (c = 0; (ao_packet_tx_used || ao_tx_packet.len) && c < 10; c++) ao_delay(AO_MS_TO_TICKS(100)); ao_packet_enable = 0; - ao_radio_abort(); while (ao_packet_echo_task.wchan || ao_packet_task.wchan) { + ao_radio_abort(); ao_wake_task(&ao_packet_echo_task); ao_wake_task(&ao_packet_task); ao_yield(); |