/* Enable FIFO batching of pedometer embedded function values..  */
int32_t lsm6dso_fifo_pedo_batch_get(lsm6dso_ctx_t *ctx, uint8_t *val)
/* Enable FIFO batching of pedometer embedded function values..  */
int32_t lsm6dso_fifo_pedo_batch_get(lsm6dso_ctx_t *ctx, uint8_t *val)
{
  lsm6dso_emb_func_fifo_cfg_t reg;
  int32_t ret;
  ret = lsm6dso_mem_bank_set(ctx, LSM6DSO_EMBEDDED_FUNC_BANK);
  if (ret == 0) {
    ret = lsm6dso_read_reg(ctx, LSM6DSO_EMB_FUNC_FIFO_CFG, (uint8_t*)&reg, 1);
  }
  if (ret == 0) {
    *val = reg.pedo_fifo_en;
    ret = lsm6dso_mem_bank_set(ctx, LSM6DSO_USER_BANK);
  }
  return ret;
}