Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 2 additions & 6 deletions samples/light_switch/src/app_task_zigbee.c
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,6 @@
#include "zb_mem_config_custom.h"
#include "zb_dimmer_switch.h"

#if defined(CONFIG_LIGHT_SWITCH_CONFIGURE_TX_POWER)
#include <osif/mac_platform.h>
#endif

#if CONFIG_ZIGBEE_FOTA
#include <zigbee/zigbee_fota.h>
#include <zephyr/sys/reboot.h>
Expand Down Expand Up @@ -906,7 +902,7 @@ void set_tx_power(void)
{
zb_ret_t ret;
uint32_t channel_mask;
uint8_t channel = ZB_TRANSCEIVER_START_CHANNEL_NUMBER;
uint8_t channel = ZB_PAGE0_2_4_GHZ_CHANNEL_FROM;

#if defined(CONFIG_ZIGBEE_CHANNEL_SELECTION_MODE_SINGLE)
channel_mask = 1 << CONFIG_ZIGBEE_CHANNEL;
Expand All @@ -917,7 +913,7 @@ void set_tx_power(void)
channel_mask |= zigbee_touchlink_initiator_zll_primary_channel_mask();
#endif

for (; channel <= ZB_TRANSCEIVER_MAX_CHANNEL_NUMBER; channel++) {
for (; channel <= ZB_PAGE0_2_4_GHZ_CHANNEL_TO; channel++) {
if (channel_mask & (1 << channel)) {
LOG_INF("Setting tx power for channel %d: %d dBm", channel,
CONFIG_LIGHT_SWITCH_TX_POWER);
Expand Down
Loading