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

mesh sdk api "nrf_mesh_node_config_clear()" not work

Hi All:

        i met a trouble. 

        i want to implement a function that  i can restore mesh device by uart cmd.

       so , i add uart to light switch service demo,  when i recive a cmd "AT+RESTORE", i will run nrf_mesh_node_config_clear() to clear flash data.

       but i failed. when i send AT+RESTORE to device.  the device  enter ASSERT(),   

      

      i don't know this is API problem or my problem.

     you function (nrf_mesh_node_config_clear()) can work properly?

Parents
  • Hi Jijang,

    you should call that function from main

    Currently, it is not possible to work in the different interrupt levels within stack algorithms. That causes impossibility nested handlers excluding high priority radio stuff. The issue has been reproduced in the current version because of the public API is invoked from the main loop in the example(with thread mcu priority). There is the limitation for calling the public API (see documentation subclause 'Interrupt priority levels').

    'Limitations

    Except for calling initialization related functions before entering the main loop, no mesh API functions must be called from an IRQ priority other than the one specified in the configuration. Breaking this rule may cause unpredictable behavior.'

Reply
  • Hi Jijang,

    you should call that function from main

    Currently, it is not possible to work in the different interrupt levels within stack algorithms. That causes impossibility nested handlers excluding high priority radio stuff. The issue has been reproduced in the current version because of the public API is invoked from the main loop in the example(with thread mcu priority). There is the limitation for calling the public API (see documentation subclause 'Interrupt priority levels').

    'Limitations

    Except for calling initialization related functions before entering the main loop, no mesh API functions must be called from an IRQ priority other than the one specified in the configuration. Breaking this rule may cause unpredictable behavior.'

Children
Related