I Cube LRWAN problem

Hello, I am currently working on a project using LoRa technology. My end node is composed of Nucleo-l073rz and i-Nucleo-lrwan1 shield and I am also using Keil IDE. So here’s the problem:

  1. I installed the I Cube Lrwan expansion ( I tried both V1.3.1 and the latest one which is the V2.0.0 and even older versions)
  2. I made the changes in the code as instructed (Older version : Changes in the commissioning.h file: DevEUI, JoinEUI, NwkKey, *Latest Version * : Changes in the se-identity.h file: DevEUI, JoinEUI, NwkKey)
  3. I built and loaded the code
  4. I used Tera term on my COM to monitor the join request
  5. In both cases ( for the 2 versions) I got nothing.
    5.1 for the V1.3.1 version (and all the older versions like v1.1.1, v1.2.2 v1.4.1 …): I get Phy TxTimeout and nothing else (I monitor the traffic on the gateway and I get nothing )
    5.2 for the V2.0.0 version: I keep getting Join Failed every 10 spb1
    So I am asking for a solution to this problem and Thank you in advance

Have you checked the device transmits on the frequencies the gateway uses? (Is it using the right frequency plan and for those with multiple sub-bands the right sub-band?)

Thank you for your reply,
How can I check that?
I mean even the tutorial for this is to install the I Cube LRWAN make few changes and it works fine for everyone.

The transmit frequency is visible in your output. Does that match the gateway settings?

Two hints about using the forum:

  • Do not post the same issue multiple times. That is wasting peoples time because they read both and answers might be given and duplicated.
  • Do not post screen shots of text. Just cut-and-paste the text to your message and use < / > in the formatting options to mark it pre-formatted text.
1 Like

Yes, the gateway has the same frequency plan: EU868 MHz

Does the gateway receive other nodes traffic or does it not show any data?

It does receive other nodes. I used the same node using stm32duino library (STM32duino_I_NUCLEO_LRWAN1) programmed using the arduinoIDE on the same board with the same shield and I used with the same device setting and the gateway received it. but when I work with I cube expansion I dont get anything.

TxTimeout error indicates that the TxDone interrupt has not been detected by the MCU.

You need to check that the pins connection between the MCU and the Radio are correct. You need also to verify that the used pins are the ones defined in the source code.

As there is is no information on which radio shield you are using it will be difficult to help you further.

On Keil you need to specify the radio shield you want to use.
In case this is not correct the MCU will most certainly fail to communicate with the radio.
image

I am using I nucleo LRWAN shield and it has sx1272. How can I fix the connection ?

I suppose that the board setup that you are using is the one described at following link.

In the description it is said that the used shield is an SX1272MB2xAS.

In Keil IDE you need to select the sx1272mb2das target as shown in my previous post.
Once the change is done recompile the code and flash the board and everything should work as expected.

Thank you for your reply.
Unfortunately, I still get nothing.Capture4

I have tried the provided example using my NucleoL073+SX1272MB2DAS shield and I observed the same issue as you.

I then tried to change the compiler optimization and the firmware looks to operate better.
Just by changing the optimization level from -Oz to -O1 looks to improve as then we get txDone instead of txTimeout please refer to below log.

I would recommend that you contact ST support as it looks like there is a problem when compiler highest optimization level is activated.

Please note that I did not try to connect to a network server. Also I have used latest version of the en.i-cube_lrwan package (V2.0.0).

Log generated by changing sys_conf.h to the following:

/**
  * @brief  Verbose level for all trace logs
  */
#define VERBOSE_LEVEL     VLEVEL_H

/**
  * @brief Enable trace logs
  */
#define APP_LOG_ENABLED   1

/**
  * @brief Enable Debugger mode
  * @note  1:ON it enables the debbugger plus 4 dgb pins, 0:OFF the debugger is OFF (lower consumption)
  */
#define DEBUGGER_ON       1

/**
  * @brief Disable Low Power mode
  * @note  0: LowPowerMode enabled. MCU enters stop2 mode, 1: LowPowerMode disabled. MCU enters sleep mode only
  */
#define LOW_POWER_DISABLE 1

Generated log:

APP_VERSION:        V1.0.0
MW_LORAWAN_VERSION: V2.2.1
MW_RADIO_VERSION:   V0.0.1
###### OTAA ######
###### AppKey:  2B 7E 15 16 28 AE D2 A6 AB F7 15 88 09 CF 4F 3C
###### NwkKey:  2B 7E 15 16 28 AE D2 A6 AB F7 15 88 09 CF 4F 3C
###### ABP  ######
###### AppSKey: 2B 7E 15 16 28 AE D2 A6 AB F7 15 88 09 CF 4F 3C
###### NwkSKey: 2B 7E 15 16 28 AE D2 A6 AB F7 15 88 09 CF 4F 3C
###### DevEui:  30-37-38-34-68-37-75-01
###### AppEui:  01-01-01-01-01-01-01-01
0s066:TX on freq 868500000 Hz at DR 0
31s532:MAC txDone
36s565:RX_1 on freq 868500000 Hz at DR 0
36s765:MAC rxTimeOut
37s565:RX_2 on freq 869525000 Hz at DR 0
37s765:MAC rxTimeOut

###### = JOIN FAILED
40s050:temp= 31
40s051:VDDA= 254
40s056:TX on freq 868100000 Hz at DR 0
41s581:MAC txDone
46s614:RX_1 on freq 868100000 Hz at DR 0
46s814:MAC rxTimeOut
47s614:RX_2 on freq 869525000 Hz at DR 0
47s814:MAC rxTimeOut

###### = JOIN FAILED
50s050:temp= 31
50s051:VDDA= 254
50s056:TX on freq 868300000 Hz at DR 0
51s581:MAC txDone

I did the same changes that you did, I did not even get a TxDone.
Thank you for your reply

Hello,
I recently purchased the TTIG (The Things Indoor Gateway) and I started working on it.
I am using stm32l073 + I nucleo lrwan shield + arduinoIDE (I am using the stm32duino and lorawan library) to create an end node.
For the uplink, everything is fine and working as for the downlink I am getting nothing
I used the kerlink gateway using the same end node and both the uplink and downlink worked but when I changed to TTIG gateway the downlink does not work anymore.
So if there is a solution to this problem or if there is someone who had the same problem do not hesitate to guide me. Thanks

Both gw’s On TTS(CE) or mix or both V2? Assume as TTIG new it’s on V3…

ABP or OTAA?..Rx window settings on Node?

They are both on V3, and using OTAA.
ps : I am still new to the lorawan technology
I want to know if this problem occured before and is it a hardware or a software problem
Thanks

Hello, I am using stm32l073 + I nucleo lrwan shield + arduinoIDE (I am using the stm32duino and lorawan library) to create an end node. I am using TTIG (The Things Indoor Gateway) as a gateway.
I am using V3 and OTAA.
I’ll upload some screenshots so you can understand the issue.
As you can see in the 1st and 2nd screenshots the node is sending uplinks and the TTN console is able to read those uplinks.
Capture1 Capture4

So, there is no problem with the uplink, but, when I try to send a downlink I get nothing.
This screenshot shows the problem :
Capture2

plus, as you can see in the TTN console I only find the rx2 data rate index I didn’t find the rx1 data rate index :
Capture3

I’d appricate an answer to this problem and Thanks.

As promised …

First, how did you ‘register’ your TTIG - as regardless of how the Nucleo-LRWAN1 setup is working, the TTIG should be able to send downlinks even if the device isn’t able to hear them or process them.

If you added it and entered the EUI it may well be a phantom entry - able to show traffic but not really attached to your account. So if you didn’t use the claiming procedure, you should delete it and claim it:

https://www.thethingsindustries.com/docs/gateways/thethingsindoorgateway/

Until you get an entry in the gateway console log to say it has sent a downlink there is no point working on the device. To preempt any question about TTIG’s & downlinks, yes, they do work in EU868.

However I’m wondering how you get your device to join if the gateway isn’t doing downlinks!

As regards being able to change Rx1, the Rx1 channel/frequency & data rate is always the one the device used to send on a class A uplink so is not something we set on the console. The Rx2 will be setup for you on OTAA in the join-accept so again, not something we need to change.

The problem in the downlink in the V3 is that it uses a 5 seconds Rx1 delay and the V2 uses 1 second RX1 delay.

So try to set in your arduino script the RX1Delay to 5 seconds, just add in the void setup this line :

loraNode.setRx1Delay(5000);

1 Like

That worked like a charm. Problem solved
Thanks a lot