/* aux_pw_on_ctrl:  OIS chain on aux interface power on mode  */
int32_t lsm6dso_aux_pw_on_ctrl_get(stmdev_ctx_t *ctx, lsm6dso_ois_on_t *val)
/* aux_pw_on_ctrl:  OIS chain on aux interface power on mode  */
int32_t lsm6dso_aux_pw_on_ctrl_get(stmdev_ctx_t *ctx, lsm6dso_ois_on_t *val)
{
  lsm6dso_ctrl7_g_t reg;
  int32_t ret;
  ret = lsm6dso_read_reg(ctx, LSM6DSO_CTRL7_G, (uint8_t *)&reg, 1);
  switch (reg.ois_on) {
    case LSM6DSO_AUX_ON:
      *val = LSM6DSO_AUX_ON;
      break;
    case LSM6DSO_AUX_ON_BY_AUX_INTERFACE:
      *val = LSM6DSO_AUX_ON_BY_AUX_INTERFACE;
      break;
    default:
      *val = LSM6DSO_AUX_ON;
      break;
  }
  return ret;
}