This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Client to Server Data transmit

Hi every one , i tries to call the generic_onoff_client_set function to send a message from the client to the server but this ain't working. Can someone please help me?

Here is the code:

When i call the function, this is the error i get in the Logs: 

Please help! Thank you all

Parents Reply Children
  • Hi i'm using the nrf5_SDK_for_Mesh_v4.1.0 and i modified the Light Switch example!

    That is the only thing i modified. I tried to call the function and i'm getting that error. I even tried to call the button_press handler to simulate a button press but i have the same error.

    Can you please tell me how to use that addr2line  command? I'm new on this and i don't know very well how it works. 

    Thanks for your help!

  • Do you get any errors when you remove this modification? 

    You should have the addr2line tool after installing SES. You should be able to find it here: 

    [Your location]\SEGGER\SEGGER Embedded Studio for ARM 4.52c\gcc\arm-none-eabi\bin

    Add it to your PATH. Then you use the command above in your command prompt.

  • Hi, i used the command, and it gave me this :

    mesh\core\src/timer_scheduler.c:214 (discriminator 1)

    when i looked in the file on that line i have this: 

    Can you please help?

  • Where do you call the code snippet above? And do you get the assert right away when calling generic_onoff_client_set function?

    It would also be helpful if you sent me the call stack when the assert occurs.

    Can you also give me more details about your use-case? What are you trying to do?

  • Hi, 

    My answers below.

    Where do you call the code snippet above? And do you get the assert right away when calling generic_onoff_client_set function?

    I call the generic_onoff_client_set function in the main() loop. And i get the assert when i call the function.

    It would also be helpful if you sent me the call stack when the assert occurs.

    I call the function here. It is in the main loop. 

    Can you also give me more details about your use-case? What are you trying to do?

    To explain, I'm trying to send a byte from the client to the server.
    That byte comes from a smartphone application connected to the client through the proxy service. This proxy service communication  works fine and I receive the byte in the client from the smartphone.
    When I receive the byte I have to retransmit it to the server. This is where I try to call the generic_onoff_client_set function in the main() but this is where I get the error.

    Is it clearer? Feel free to suggest another way to send data to the server if there is one.

    Thanks

Related