From 8b2ef2675d8e1c20f83a315fb29bc8196462ed16 Mon Sep 17 00:00:00 2001 From: maralvira Date: Sun, 7 Nov 2010 14:10:16 +0000 Subject: [PATCH] discard received packets --- this lets you run multiple rftest-tx's at the same time. --- cpu/mc1322x/tests/rftest-tx.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/cpu/mc1322x/tests/rftest-tx.c b/cpu/mc1322x/tests/rftest-tx.c index 28c46c6ee..13b1e367d 100644 --- a/cpu/mc1322x/tests/rftest-tx.c +++ b/cpu/mc1322x/tests/rftest-tx.c @@ -30,7 +30,7 @@ * This file is part of libmc1322x: see http://mc1322x.devl.org * for details. * - * $Id: rftest-tx.c,v 1.1 2010/06/10 14:55:39 maralvira Exp $ + * $Id: rftest-tx.c,v 1.2 2010/11/07 14:10:16 maralvira Exp $ */ #include @@ -93,6 +93,10 @@ void main(void) { /* a few lockup conditions */ check_maca(); + while((p = rx_packet())) { + if(p) free_packet(p); + } + p = get_free_packet(); if(p) { fill_packet(p);