[MERGED] osmo-bts[master]: measurement: Keep average of high-accurate ToA value in lchan

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.

Harald Welte gerrit-no-reply at lists.osmocom.org
Tue Feb 27 21:58:37 UTC 2018


Harald Welte has submitted this change and it was merged.

Change subject: measurement: Keep average of high-accurate ToA value in lchan
......................................................................


measurement: Keep average of high-accurate ToA value in lchan

At the end of a measurement processing window, we currently compute
the ToA / timing offset at 1/256th symbol accuracy, but we only print
it to the log.  Let's store the value in the lchan to make it usable
by other code in follow-up patches.

Change-Id: I5f00a16ac966b627d9452a98b8fa70984bed684a
---
M include/osmo-bts/gsm_data_shared.h
M src/common/measurement.c
2 files changed, 2 insertions(+), 0 deletions(-)

Approvals:
  Harald Welte: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/include/osmo-bts/gsm_data_shared.h b/include/osmo-bts/gsm_data_shared.h
index 770aea8..2d6ead1 100644
--- a/include/osmo-bts/gsm_data_shared.h
+++ b/include/osmo-bts/gsm_data_shared.h
@@ -290,6 +290,7 @@
 		/* last L1 header from the MS */
 		uint8_t l1_info[2];
 		struct gsm_meas_rep_unidir ul_res;
+		int16_t ms_toa256;
 	} meas;
 	struct {
 		struct amr_multirate_conf amr_mr;
diff --git a/src/common/measurement.c b/src/common/measurement.c
index bdb2850..ba7494a 100644
--- a/src/common/measurement.c
+++ b/src/common/measurement.c
@@ -399,6 +399,7 @@
 	mru->sub.rx_lev = dbm2rxlev((int)irssi_sub_sum * -1);
 	mru->full.rx_qual = ber10k_to_rxqual(ber_full_sum);
 	mru->sub.rx_qual = ber10k_to_rxqual(ber_sub_sum);
+	lchan->meas.ms_toa256 = ta256b_sum;
 
 	LOGP(DMEAS, LOGL_INFO, "%s UL MEAS RXLEV_FULL(%u), RXLEV_SUB(%u),"
 	       "RXQUAL_FULL(%u), RXQUAL_SUB(%u), num_meas_sub(%u), num_ul_meas(%u) \n",

-- 
To view, visit https://gerrit.osmocom.org/6970
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I5f00a16ac966b627d9452a98b8fa70984bed684a
Gerrit-PatchSet: 1
Gerrit-Project: osmo-bts
Gerrit-Branch: master
Gerrit-Owner: Harald Welte <laforge at gnumonks.org>
Gerrit-Reviewer: Harald Welte <laforge at gnumonks.org>
Gerrit-Reviewer: Jenkins Builder



More information about the gerrit-log mailing list