/* This API configure the ODR of the auxiliary sensor.  */
static int8_t config_aux_odr(const struct bmi160_dev *dev)
/* This API configure the ODR of the auxiliary sensor.  */
static int8_t config_aux_odr(const struct bmi160_dev *dev)
{
    int8_t rslt;
    uint8_t aux_odr;
    rslt = bmi160_get_regs(BMI160_AUX_ODR_ADDR, &aux_odr, 1, dev);
    if (rslt == BMI160_OK)
    {
        aux_odr = (uint8_t)(dev->aux_cfg.aux_odr);
        rslt = bmi160_set_regs(BMI160_AUX_ODR_ADDR, &aux_odr, 1, dev);
        dev->delay_ms(BMI160_AUX_COM_DELAY);
    }
    return rslt;
}