summaryrefslogtreecommitdiff
path: root/src/cc1111/ao_radio.c
diff options
context:
space:
mode:
authorBdale Garbee <bdale@gag.com>2015-07-16 13:36:59 -0600
committerBdale Garbee <bdale@gag.com>2015-07-16 13:36:59 -0600
commitf4f0f044df1251d64d44bf62d25b488fd04a05c8 (patch)
tree12efee1447a67d8cf37b6f447c011708264b8266 /src/cc1111/ao_radio.c
parentb25690062ac04a588ad4d11740597c20e516eb1a (diff)
parent570daace9caf7647a09c53d5c75593cc4c98b93b (diff)
Merge branch 'branch-1.6' into debian
Diffstat (limited to 'src/cc1111/ao_radio.c')
-rw-r--r--src/cc1111/ao_radio.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/src/cc1111/ao_radio.c b/src/cc1111/ao_radio.c
index b9821a42..cead0364 100644
--- a/src/cc1111/ao_radio.c
+++ b/src/cc1111/ao_radio.c
@@ -451,13 +451,9 @@ ao_radio_recv(__xdata void *packet, uint8_t size, uint8_t timeout) __reentrant
/* Wait for DMA to be done, for the radio receive process to
* get aborted or for a receive timeout to fire
*/
- if (timeout)
- ao_alarm(timeout);
__critical while (!ao_radio_dma_done && !ao_radio_abort)
- if (ao_sleep(&ao_radio_dma_done))
+ if (ao_sleep_for(&ao_radio_dma_done, timeout))
break;
- if (timeout)
- ao_clear_alarm();
/* If recv was aborted, clean up by stopping the DMA engine
* and idling the radio