ms_srs: turn tx/rx_gain into INT and make them optional

when they are greater than 0 they are written as config paramter.
if they are -1 they are disbaled and automatic gain calibration is
used.

Change-Id: I473ff3ae679784178574d2f76b612dbf77180490
diff --git a/src/osmo_gsm_tester/obj/ms_srs.py b/src/osmo_gsm_tester/obj/ms_srs.py
index df83c2a..f564519 100644
--- a/src/osmo_gsm_tester/obj/ms_srs.py
+++ b/src/osmo_gsm_tester/obj/ms_srs.py
@@ -39,8 +39,8 @@
         'additional_args[]': schema.STR,
         'airplane_t_on_ms': schema.INT,
         'airplane_t_off_ms': schema.INT,
-        'tx_gain': schema.UINT,
-        'rx_gain': schema.UINT,
+        'tx_gain': schema.INT,
+        'rx_gain': schema.INT,
         'freq_offset': schema.INT,
         }
     for key, val in RunNode.schema().items():
diff --git a/src/osmo_gsm_tester/templates/srsue.conf.tmpl b/src/osmo_gsm_tester/templates/srsue.conf.tmpl
index a922dc8..0250f2b 100644
--- a/src/osmo_gsm_tester/templates/srsue.conf.tmpl
+++ b/src/osmo_gsm_tester/templates/srsue.conf.tmpl
@@ -39,8 +39,12 @@
 dl_earfcn = 2850
 % endif
 freq_offset = ${ue.freq_offset}
+% if int(ue.tx_gain) > 0:
 tx_gain = ${ue.tx_gain}
+% endif
+% if int(ue.rx_gain) > 0:
 rx_gain = ${ue.rx_gain}
+% endif
 
 #nof_radios = 1
 nof_antennas = ${ue.num_antennas}