cancel
Showing results for 
Search instead for 
Did you mean: 

Custom Join request on LoRaWAN End Node STM32L0

Mr._Nileshkumar_Solanki
Associate III

Hello,

I want to make my end node will send join request to the gateway continuously in every five second.

My goal is send join request continuously until end node connected to the gateway and if connection is break after join with server, then again send join request contiguously.

 

Thank you in advance.

5 REPLIES 5
STTwo-32
ST Employee

Hello @Mr._Nileshkumar_Solanki 

I suggest you to use the LoRaWAN_End_Node example available on the I-CUBE-LRWAN expansion package. Then, after understanding how it exactly works, you can do the modifications you are looking for.

Best Regards.

STTwo-32 

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.

Mr._Nileshkumar_Solanki
Associate III

Sure, I will check and let you know about further clarification or discuss about it.

 

Thank you, @STTwo-32 

Mr._Nileshkumar_Solanki
Associate III

Hello @STTwo-32,

I checked and in that code contiguously send join request send 10 to 12 times in 2 minutes.

How I modify my code based on it.

 

Here is JoinRequest function which i used in my code,

"

static void APPLICATION_OnJoinRequest(LmHandlerJoinParams_t *joinParams)

{

    if (joinParams != NULL)

    {

        if (joinParams->Status == LORAMAC_HANDLER_SUCCESS)

        {

            DEBUGOUT("\r\n###### = JOINED = ");

            if (joinParams->Mode == ACTIVATION_TYPE_ABP)

            {

                 DEBUGOUT("ABP ======================\r\n");

            }

          else

           {

                DEBUGOUT("OTAA =====================\r\n");

           }

          /* Force a clock synchronization to be able to start a Multicast Session */

         LmHandlerDeviceTimeReq();

    }

    else

    {

         // Over-The-Air Activation

         LmHandlerJoin(ACTIVATION_TYPE_OTAA);

 

         DEBUGOUT("\r\n###### = JOIN FAILED\r\n");

    }

  }

}

"

 

Thank you in advanced.

Hello @Mr._Nileshkumar_Solanki 

Infact, that should stop after a few times of trying to connect to give indication that there is a connection problem. But if you want to keep trying infinitely, you can take a look at the sequencer of your application and make the connection task works infinitely.

Best Regards.

STTwo-32

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.


But if you want to keep trying infinitely, you can take a look at the sequencer of your application and make the connection task works infinitely.

Hello, 

where i can find the sequencer?

thanks 
Roberto