aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHolger Hans Peter Freyther <zecke@selfish.org>2010-05-14 01:57:02 +0800
committerHolger Hans Peter Freyther <zecke@selfish.org>2010-05-14 02:09:23 +0800
commitcf5cc5bb5b472f470eb9584a32dee3c38413f93a (patch)
tree1b025289d52c704575722ae0517d0248570d6c94
parent3d6a5d648e0dca3c65c1be42bc1ce617179b4a2c (diff)
[vty] Add power measurements to the one line summary.
-rw-r--r--openbsc/src/vty_interface.c14
1 files changed, 13 insertions, 1 deletions
diff --git a/openbsc/src/vty_interface.c b/openbsc/src/vty_interface.c
index 85530d004..279970649 100644
--- a/openbsc/src/vty_interface.c
+++ b/openbsc/src/vty_interface.c
@@ -685,9 +685,21 @@ static void lchan_dump_full_vty(struct vty *vty, struct gsm_lchan *lchan)
static void lchan_dump_short_vty(struct vty *vty, struct gsm_lchan *lchan)
{
- vty_out(vty, "Lchan %u in Timeslot %u of TRX %u in BTS %u, Type %s%s",
+ struct gsm_meas_rep *mr;
+ int idx;
+
+ /* we want to report the last measurement report */
+ idx = calc_initial_idx(ARRAY_SIZE(lchan->meas_rep),
+ lchan->meas_rep_idx, 1);
+ mr = &lchan->meas_rep[idx];
+
+ vty_out(vty, "Lchan: %u Timeslot: %u TRX: %u BTS: %u Type: %s - L1 MS Power: %u dBm "
+ "RXL-FULL-dl: %4d dBm RXL-FULL-ul: %4d dBm%s",
lchan->nr, lchan->ts->nr, lchan->ts->trx->nr,
lchan->ts->trx->bts->nr, gsm_lchant_name(lchan->type),
+ mr->ms_l1.pwr,
+ rxlev2dbm(mr->dl.full.rx_lev),
+ rxlev2dbm(mr->ul.full.rx_lev),
VTY_NEWLINE);
}