/* This API configure necessary setting of any-motion interrupt.  */
static int8_t config_any_motion_int_settg(const struct bmi160_int_settg *int_config, const struct bmi160_acc_any_mot_int_cfg *any_motion_int_cfg, const struct bmi160_dev *dev)
/* This API configure necessary setting of any-motion interrupt.  */
static int8_t config_any_motion_int_settg(const struct bmi160_int_settg *int_config, const struct bmi160_acc_any_mot_int_cfg *any_motion_int_cfg, const struct bmi160_dev *dev)
{
    int8_t rslt;
    rslt = set_intr_pin_config(int_config, dev);
    if (rslt == BMI160_OK)
    {
        rslt = disable_sig_motion_int(dev);
        if (rslt == BMI160_OK)
        {
            rslt = map_feature_interrupt(int_config, dev);
            if (rslt == BMI160_OK)
            {
                rslt = config_any_motion_src(any_motion_int_cfg, dev);
                if (rslt == BMI160_OK)
                {
                    rslt = config_any_dur_threshold(any_motion_int_cfg, dev);
                }
            }
        }
    }
    return rslt;
}