diff --git a/platform/msb430/dev/cc1020.c b/platform/msb430/dev/cc1020.c index 06fa3f58a..5056a328f 100644 --- a/platform/msb430/dev/cc1020.c +++ b/platform/msb430/dev/cc1020.c @@ -71,9 +71,6 @@ static void cc1020_write_reg(uint8_t addr, uint8_t adata); static void cc1020_load_config(const uint8_t *); static void cc1020_reset(void); -/// selected rx/tx/pd switching algorithm -static enum cc1020_power_mode cc1020_power_mode = CC1020_ALWAYS_ON; - // current mode of cc1020 chip static enum cc1020_state cc1020_state = CC1020_OFF; static volatile uint8_t cc1020_rxbuf[HDRSIZE + CC1020_BUFFERSIZE]; @@ -193,12 +190,6 @@ cc1020_set_tx(void) cc1020_state = CC1020_TX; } -void -cc1020_set_power_mode(enum cc1020_power_mode mode) -{ - cc1020_power_mode = mode; -} - void cc1020_set_power(uint8_t pa_power) { @@ -263,12 +254,8 @@ cc1020_set_receiver(void (*recv)(const struct radio_driver *)) int cc1020_on(void) { - if (cc1020_power_mode == CC1020_ALWAYS_ON) { - // Switch to receive mode - cc1020_set_rx(); - } else { - cc1020_off(); - } + // Switch to receive mode + cc1020_set_rx(); return 1; } diff --git a/platform/msb430/dev/cc1020.h b/platform/msb430/dev/cc1020.h index 07823fced..c33a41a37 100644 --- a/platform/msb430/dev/cc1020.h +++ b/platform/msb430/dev/cc1020.h @@ -51,17 +51,12 @@ Berlin, 2006 #include "dev/radio.h" -enum cc1020_power_mode { - CC1020_ALWAYS_ON -}; - extern const uint8_t cc1020_config_19200[]; extern const uint8_t cc1020_config_115200[]; void cc1020_init(const uint8_t* config); void cc1020_set_rx(void); void cc1020_set_tx(void); -void cc1020_set_power_mode(enum cc1020_power_mode mode); void cc1020_set_power(uint8_t pa_power); uint8_t cc1020_get_rssi(void);