trx/radio_if.py: reset UHD device time at startup
Some UHD devices, such as UmTRX, require one to manually reset the
hardware clock, otherwise the burst transmission doesn't work.
Change-Id: Idddc1387199bd22342ec5af25c8635e73352e315
diff --git a/python/trx/radio_if.py b/python/trx/radio_if.py
index 355312b..119b237 100644
--- a/python/trx/radio_if.py
+++ b/python/trx/radio_if.py
@@ -257,6 +257,12 @@
(self.dict_toggle_sign, 'dict_out'),
(self.msg_to_tag_sink, 'msg'))
+
+ # Some UHD devices (such as UmTRX) do start the clock
+ # not from 0, so it's required to reset it manually.
+ # Resetting UHD source will also affect the sink.
+ self.phy_src.set_time_now(uhd.time_spec(0.0))
+
def shutdown(self):
print("[i] Shutdown Radio interface")
self.stop()