How to poll updated parameters correctly?

I am trying to add a parameter for my sensor driver and was able to update the parameter successfully in the initialization time.

  1. Create a parameter file “name_params.c” and defined a param
    PARAM_DEFINE_FLOAT(SENS_RNG_LPF, 0.25f);

  2. Added followings as private variables
    int _params_sub{-1}; /**< parameter updates subscription */
    param_t _param_lpf;

  3. Subscribe parameter_update in the constructor
    _params_sub = orb_subscribe(ORB_ID(parameter_update));

  4. Update param in init() function as following
    _param_lpf = param_find(“SENS_RNG_LPF”);
    if (_param_lpf != PARAM_INVALID) {
    float val = 2.5;
    param_get(_param_lpf, &val);
    _lpf_cutoff_freq = val;
    }

  5. During run time I tried to poll updated parameters as here
    void LidarLitePWM::parameter_update_poll()
    {
    bool updated;
    /* Check if parameters have changed */
    orb_check(_params_sub, &updated);
    if (updated) {
    struct parameter_update_s param_update;
    orb_copy(ORB_ID(parameter_update), _params_sub, &param_update);
    float val = 2.5;
    param_get(_param_lpf, &val);
    _lpf_cutoff_freq = val;
    }
    }

1 - 4 works fine as the parameter save and update works in the initialization time however 5 is not working in the run time.
What should I change in order to able to change parameters in the run time?
Any help would much appreciated.
Thanks,

Kyu

Hi,
This issue has been solved ?
Are you calling the parameter_update_poll() function inside run() function of your driver ?