From fb922c0ab9a8d04151da78d5c135b2043893c0c5 Mon Sep 17 00:00:00 2001 From: Mariano Alvira Date: Sun, 7 Mar 2010 18:48:36 -0500 Subject: [PATCH] transmit at max power --- tests/rftest-tx.c | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/tests/rftest-tx.c b/tests/rftest-tx.c index aec89e159..aed10db8e 100644 --- a/tests/rftest-tx.c +++ b/tests/rftest-tx.c @@ -7,15 +7,19 @@ #define LED LED_RED -#define PAYLOAD_LEN 120 -#define DELAY 400000 +/* 802.15.4 PSDU is 127 MAX */ +/* 2 bytes are the FCS */ +/* therefore 125 is the max payload length */ +#define PAYLOAD_LEN 16 +#define DELAY 1 void fill_packet(volatile packet_t *p) { static volatile uint8_t count=0; volatile uint8_t i; p->length = PAYLOAD_LEN; p->offset = 0; - for(i=0; idata[0] = 0xff; + for(i=1; idata[i] = count++; } } @@ -44,7 +48,9 @@ void main(void) { /* trim the reference osc. to 24MHz */ pack_XTAL_CNTL(CTUNE_4PF, CTUNE, FTUNE, IBIAS); - set_power(0x0f); /* 0dbm */ +// set_power(0x0f); /* 0xf = -1dbm, see 3-22 */ +// set_power(0x11); /* 0x11 = 3dbm, see 3-22 */ + set_power(0x12); /* 0x12 is the highest, not documented*/ set_channel(0); /* channel 11 */ /* initial radio command */