diff options
Diffstat (limited to 'src/osmo-bts-trx/trx_if.c')
-rw-r--r-- | src/osmo-bts-trx/trx_if.c | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/src/osmo-bts-trx/trx_if.c b/src/osmo-bts-trx/trx_if.c index bca9cdca..e6b70134 100644 --- a/src/osmo-bts-trx/trx_if.c +++ b/src/osmo-bts-trx/trx_if.c @@ -46,6 +46,8 @@ int tranceiver_available = 0; const char *tranceiver_ip = "127.0.0.1"; +int settsc_enabled = 0; +int setbsic_enabled = 0; /* * socket @@ -230,12 +232,20 @@ int trx_if_cmd_poweron(struct trx_l1h *l1h) int trx_if_cmd_settsc(struct trx_l1h *l1h, uint8_t tsc) { - return trx_ctrl_cmd(l1h, 0, "SETTSC", "%d", tsc); + if (!settsc_enabled) + return 0; + /* if TSC is enabled only, the positive response is mandatory */ + return trx_ctrl_cmd(l1h, (setbsic_enabled) ? 0 : 1, "SETTSC", "%d", + tsc); } int trx_if_cmd_setbsic(struct trx_l1h *l1h, uint8_t bsic) { - return trx_ctrl_cmd(l1h, 0, "SETBSIC", "%d", bsic); + if (!setbsic_enabled) + return 0; + /* if BSIC is enabled only, the positive response is mandatory */ + return trx_ctrl_cmd(l1h, (settsc_enabled) ? 0 : 1, "SETBSIC", "%d", + bsic); } int trx_if_cmd_setrxgain(struct trx_l1h *l1h, int db) |