/* This API configures the power mode, range and bandwidth of sensor.  */
int8_t bmi160_set_sens_conf(struct bmi160_dev *dev)
/* This API configures the power mode, range and bandwidth of sensor.  */
int8_t bmi160_set_sens_conf(struct bmi160_dev *dev)
{
    int8_t rslt = BMI160_OK;
    if ((dev == NULL) || (dev->delay_ms == NULL))
    {
        rslt = BMI160_E_NULL_PTR;
    }
    else
    {
        rslt = set_accel_conf(dev);
        if (rslt == BMI160_OK)
        {
            rslt = set_gyro_conf(dev);
            if (rslt == BMI160_OK)
            {
                rslt = bmi160_set_power_mode(dev);
                if (rslt == BMI160_OK)
                {
                    rslt = check_invalid_settg(dev);
                }
            }
        }
    }
    return rslt;
}