diff options
Diffstat (limited to 'src/osmo-bts-sysmo')
-rw-r--r-- | src/osmo-bts-sysmo/l1_if.c | 5 | ||||
-rw-r--r-- | src/osmo-bts-sysmo/main.c | 7 | ||||
-rw-r--r-- | src/osmo-bts-sysmo/oml.c | 19 |
3 files changed, 22 insertions, 9 deletions
diff --git a/src/osmo-bts-sysmo/l1_if.c b/src/osmo-bts-sysmo/l1_if.c index e2ad500f..12749dd3 100644 --- a/src/osmo-bts-sysmo/l1_if.c +++ b/src/osmo-bts-sysmo/l1_if.c @@ -841,6 +841,7 @@ static int handle_ph_data_ind(struct femtol1_hdl *fl1, GsmL1_PhDataInd_t *data_i uint32_t fn; uint8_t *data, len; int rc = 0; + int8_t rssi; chan_nr = chan_nr_by_sapi(trx->ts[data_ind->u8Tn].pchan, data_ind->sapi, data_ind->subCh, data_ind->u8Tn, data_ind->u32Fn); @@ -877,6 +878,8 @@ static int handle_ph_data_ind(struct femtol1_hdl *fl1, GsmL1_PhDataInd_t *data_i return rc; } + /* get rssi */ + rssi = (int8_t) (data_ind->measParam.fRssi); /* get data pointer and length */ data = data_ind->msgUnitParam.u8Buffer; len = data_ind->msgUnitParam.u8Size; @@ -893,10 +896,10 @@ static int handle_ph_data_ind(struct femtol1_hdl *fl1, GsmL1_PhDataInd_t *data_i l1sap = msgb_l1sap_prim(l1p_msg); osmo_prim_init(&l1sap->oph, SAP_GSM_PH, PRIM_PH_DATA, PRIM_OP_INDICATION, l1p_msg); - l1sap->u.data.rssi = data_ind->measParam.fRssi; l1sap->u.data.link_id = link_id; l1sap->u.data.chan_nr = chan_nr; l1sap->u.data.fn = fn; + l1sap->u.data.rssi = rssi; return l1sap_up(trx, l1sap); } diff --git a/src/osmo-bts-sysmo/main.c b/src/osmo-bts-sysmo/main.c index b9f9fe98..bee5bda2 100644 --- a/src/osmo-bts-sysmo/main.c +++ b/src/osmo-bts-sysmo/main.c @@ -319,6 +319,7 @@ int main(int argc, char **argv) bts = gsm_bts_alloc(tall_bts_ctx); vty_init(&bts_vty_info); + e1inp_vty_init(); bts_vty_init(bts, &bts_log_info); handle_options(argc, argv); @@ -419,3 +420,9 @@ int main(int argc, char **argv) osmo_select_main(0); } } + +void bts_model_abis_close(struct gsm_bts *bts) +{ + /* for now, we simply terminate the program and re-spawn */ + bts_shutdown(bts, "Abis close"); +} diff --git a/src/osmo-bts-sysmo/oml.c b/src/osmo-bts-sysmo/oml.c index 4c9ac497..adc0241c 100644 --- a/src/osmo-bts-sysmo/oml.c +++ b/src/osmo-bts-sysmo/oml.c @@ -818,6 +818,9 @@ static void set_payload_format(GsmL1_LogChParam_t *lch_par) static void lchan2lch_par(GsmL1_LogChParam_t *lch_par, struct gsm_lchan *lchan) { + struct amr_multirate_conf *amr_mrc = &lchan->tch.amr_mr; + struct gsm48_multi_rate_conf *mr_conf = + (struct gsm48_multi_rate_conf *) amr_mrc->gsm48_ie; int j; LOGP(DL1C, LOGL_INFO, "%s: %s tch_mode=0x%02x\n", @@ -857,41 +860,41 @@ static void lchan2lch_par(GsmL1_LogChParam_t *lch_par, struct gsm_lchan *lchan) lch_par->tch.amrActiveCodecSet[j] = GsmL1_AmrCodec_Unset; j = 0; - if (lchan->mr_conf.m4_75) + if (mr_conf->m4_75) lch_par->tch.amrActiveCodecSet[j++] = GsmL1_AmrCodec_4_75; if (j >= ARRAY_SIZE(lch_par->tch.amrActiveCodecSet)) break; - if (lchan->mr_conf.m5_15) + if (mr_conf->m5_15) lch_par->tch.amrActiveCodecSet[j++] = GsmL1_AmrCodec_5_15; if (j >= ARRAY_SIZE(lch_par->tch.amrActiveCodecSet)) break; - if (lchan->mr_conf.m5_90) + if (mr_conf->m5_90) lch_par->tch.amrActiveCodecSet[j++] = GsmL1_AmrCodec_5_9; if (j >= ARRAY_SIZE(lch_par->tch.amrActiveCodecSet)) break; - if (lchan->mr_conf.m6_70) + if (mr_conf->m6_70) lch_par->tch.amrActiveCodecSet[j++] = GsmL1_AmrCodec_6_7; if (j >= ARRAY_SIZE(lch_par->tch.amrActiveCodecSet)) break; - if (lchan->mr_conf.m7_40) + if (mr_conf->m7_40) lch_par->tch.amrActiveCodecSet[j++] = GsmL1_AmrCodec_7_4; if (j >= ARRAY_SIZE(lch_par->tch.amrActiveCodecSet)) break; - if (lchan->mr_conf.m7_95) + if (mr_conf->m7_95) lch_par->tch.amrActiveCodecSet[j++] = GsmL1_AmrCodec_7_95; if (j >= ARRAY_SIZE(lch_par->tch.amrActiveCodecSet)) break; - if (lchan->mr_conf.m10_2) + if (mr_conf->m10_2) lch_par->tch.amrActiveCodecSet[j++] = GsmL1_AmrCodec_10_2; if (j >= ARRAY_SIZE(lch_par->tch.amrActiveCodecSet)) break; - if (lchan->mr_conf.m12_2) + if (mr_conf->m12_2) lch_par->tch.amrActiveCodecSet[j++] = GsmL1_AmrCodec_12_2; break; case GSM48_CMODE_DATA_14k5: |