1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2025-12-27 07:21:18 +01:00

at86rf2xx: Always set channel on device

This removes the check if the current configured channel equals the new
channel. This check prevents the at86rf2xx channel to be configured
after a reset which causes the radio to be non-functional after a
NETOPT_STATE_RESET.
This commit is contained in:
Koen Zandberg 2018-07-20 12:07:08 +02:00
parent 838b18e8f9
commit b025362a7a
No known key found for this signature in database
GPG Key ID: 0895A893E6D2985B

View File

@ -140,11 +140,11 @@ uint8_t at86rf2xx_get_chan(const at86rf2xx_t *dev)
void at86rf2xx_set_chan(at86rf2xx_t *dev, uint8_t channel)
{
if ((channel > AT86RF2XX_MAX_CHANNEL) ||
if ((channel > AT86RF2XX_MAX_CHANNEL)
#if AT86RF2XX_MIN_CHANNEL /* is zero for sub-GHz */
(channel < AT86RF2XX_MIN_CHANNEL) ||
|| (channel < AT86RF2XX_MIN_CHANNEL)
#endif
(dev->netdev.chan == channel)) {
) {
return;
}