mirror of
https://github.com/oliverschmidt/contiki.git
synced 2024-12-26 19:29:24 +00:00
Atmel radio bug fix when setting tx-power. Spotted by Voravit Tanyingyong
This commit is contained in:
parent
bb90d50ba1
commit
bb5d5546ce
@ -494,7 +494,8 @@ set_value(radio_param_t param, radio_value_t value)
|
|||||||
return RADIO_RESULT_OK;
|
return RADIO_RESULT_OK;
|
||||||
|
|
||||||
case RADIO_PARAM_TXPOWER:
|
case RADIO_PARAM_TXPOWER:
|
||||||
if(value < TX_PWR_MIN || value > TX_PWR_MAX) {
|
/* MIN = 15, MAX = 0 */
|
||||||
|
if(value > TX_PWR_MIN || value < TX_PWR_MAX) {
|
||||||
return RADIO_RESULT_INVALID_VALUE;
|
return RADIO_RESULT_INVALID_VALUE;
|
||||||
}
|
}
|
||||||
rf230_set_txpower(value);
|
rf230_set_txpower(value);
|
||||||
|
Loading…
Reference in New Issue
Block a user