diff options
| author | Keith Packard <keithp@keithp.com> | 2009-03-24 23:24:01 -0700 | 
|---|---|---|
| committer | Keith Packard <keithp@keithp.com> | 2009-03-24 23:24:01 -0700 | 
| commit | c41ceb9a488b2209d1d3c09967d1473ce608030f (patch) | |
| tree | 2fdd59ab9ee7dd0fa28c0606603d5e85d137c6b5 | |
| parent | c35de083ca3d4f362063b056a0fd74ffe629d168 (diff) | |
Change radio to -30dBm
| -rw-r--r-- | target/radio/radio.c | 30 | 
1 files changed, 22 insertions, 8 deletions
diff --git a/target/radio/radio.c b/target/radio/radio.c index 9f10fccd..ba693a77 100644 --- a/target/radio/radio.c +++ b/target/radio/radio.c @@ -416,15 +416,29 @@ low() {  #define PACKET_LEN	128 +/* This are from the table for 433MHz */ + +#define RF_POWER_M30_DBM	0x12 +#define RF_POWER_M20_DBM	0x0e +#define RF_POWER_M15_DBM	0x1d +#define RF_POWER_M10_DBM	0x34 +#define RF_POWER_M5_DBM		0x2c +#define RF_POWER_0_DBM		0x60 +#define RF_POWER_5_DBM		0x84 +#define RF_POWER_7_DBM		0xc8 +#define RF_POWER_10_DBM		0xc0 + +#define RF_POWER		RF_POWER_M30_DBM +  static __code uint8_t radio_setup[] = { -	RF_PA_TABLE7_OFF,	0x60, -	RF_PA_TABLE6_OFF,	0x60, -	RF_PA_TABLE5_OFF,	0x60, -	RF_PA_TABLE4_OFF,	0x60, -	RF_PA_TABLE3_OFF,	0x60, -	RF_PA_TABLE2_OFF,	0x60, -	RF_PA_TABLE1_OFF,	0x60, -	RF_PA_TABLE0_OFF,	0x60, +	RF_PA_TABLE7_OFF,	RF_POWER, +	RF_PA_TABLE6_OFF,	RF_POWER, +	RF_PA_TABLE5_OFF,	RF_POWER, +	RF_PA_TABLE4_OFF,	RF_POWER, +	RF_PA_TABLE3_OFF,	RF_POWER, +	RF_PA_TABLE2_OFF,	RF_POWER, +	RF_PA_TABLE1_OFF,	RF_POWER, +	RF_PA_TABLE0_OFF,	RF_POWER,  	RF_FREQ2_OFF,		FREQ_CONTROL >> 16,  	RF_FREQ1_OFF,		FREQ_CONTROL >> 8,  | 
