cancel
Showing results for 
Search instead for 
Did you mean: 

LoRaWAN_End_Node application:how to modify the join channels?

PZong.1
Associate

Hi,

I'm trying to modify the join channels in the project LoRaWAN_End_Node, but I didn't find out how to do it.

I modified the following macro definition to enable sub channels CN470 80-87:

1.lorawan_conf.h

/**
  * \brief Limits the number usable channels by default for AU915, CN470 and US915 regions
  * \note the default channel mask with this option activates the first 8 channels. \
  *       this default mask can be modified in the RegionXXXXXInitDefaults function associated with the active region.
  */
#define HYBRID_ENABLED                                  1

​2 RegionCN470.c

/* The HYBRID_DEFAULT_MASKx define the enabled channels in Hybrid mode*/
/* Note: they can be redefined in lorawan_conf.h*/
#ifndef HYBRID_DEFAULT_MASK0 /*enabled channels from channel 15 down to channel 0*/
#define HYBRID_DEFAULT_MASK0 0x0000 /*channel 7 down to channel 0  enabled*/
#endif
#ifndef HYBRID_DEFAULT_MASK1 /*enabled channels from channel 31 down to channel 16*/
#define HYBRID_DEFAULT_MASK1 0x0000
#endif
#ifndef HYBRID_DEFAULT_MASK2 /*enabled channels from channel 47 down to channel 32*/
#define HYBRID_DEFAULT_MASK2 0x0000
#endif
#ifndef HYBRID_DEFAULT_MASK3 /*enabled channels from channel 63 down to channel 48*/
#define HYBRID_DEFAULT_MASK3 0x0000
#endif
#ifndef HYBRID_DEFAULT_MASK4 /*enabled channels from channel 79 down to channel 64*/
#define HYBRID_DEFAULT_MASK4 0x0000
#endif
#ifndef HYBRID_DEFAULT_MASK5 /*enabled channels from channel 95 down to channel 80*/
#define HYBRID_DEFAULT_MASK5 0x00FF
#endif

But when I test the program, it doesn't use the channels I want.

0s038:TX on freq 470500000 Hz at DR 0
1s524:MAC txDone
6s557:RX_1 on freq 500500000 Hz at DR 0
6s755:IRQ_RX_TX_TIMEOUT
6s755:MAC rxTimeOut
7s557:RX_2 on freq 505300000 Hz at DR 0
7s755:IRQ_RX_TX_TIMEOUT
7s755:MAC rxTimeOut
 
###### = JOIN FAILED
10s042:VDDA: 254
10s042:temp: 22
10s046:TX on freq 471500000 Hz at DR 0
11s533:MAC txDone
16s566:RX_1 on freq 501500000 Hz at DR 0
16s764:IRQ_RX_TX_TIMEOUT
16s764:MAC rxTimeOut
17s566:RX_2 on freq 505300000 Hz at DR 0
17s764:IRQ_RX_TX_TIMEOUT
17s764:MAC rxTimeOut
 
###### = JOIN FAILED
20s051:VDDA: 254
20s051:temp: 22
20s055:TX on freq 470300000 Hz at DR 0
21s541:MAC txDone
26s575:RX_1 on freq 500300000 Hz at DR 0
26s773:IRQ_RX_TX_TIMEOUT
26s773:MAC rxTimeOut
27s575:RX_2 on freq 505300000 Hz at DR 0
27s773:IRQ_RX_TX_TIMEOUT
27s773:MAC rxTimeOut
 
###### = JOIN FAILED
30s060:VDDA: 254
30s060:temp: 22
30s064:TX on freq 471300000 Hz at DR 0
31s550:MAC txDone
 

Is there something else that needs to be changed?

0 REPLIES 0