This is merely a historical archive of years 2008-2021, before the migration to mailman3.
A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.
Harald Welte gerrit-no-reply at lists.osmocom.orgHarald Welte has submitted this change and it was merged. ( https://gerrit.osmocom.org/9603 )
Change subject: LMSDevice: Call LMS_Init() before setting sample rate
......................................................................
LMSDevice: Call LMS_Init() before setting sample rate
LMS_Init() will override basically all device settings with their
default value, including the sample rate.  We hence have to make sure
to call it before any other API function that changes the device config
such as sample rate, frequency, filter bandwidth, ...
Change-Id: I4cdbae8406b5e1e93da491e90f8bad41d4be748b
---
M Transceiver52M/device/lms/LMSDevice.cpp
1 file changed, 6 insertions(+), 4 deletions(-)
Approvals:
  Harald Welte: Looks good to me, approved
  Jenkins Builder: Verified
diff --git a/Transceiver52M/device/lms/LMSDevice.cpp b/Transceiver52M/device/lms/LMSDevice.cpp
index 603b23d..0442e27 100644
--- a/Transceiver52M/device/lms/LMSDevice.cpp
+++ b/Transceiver52M/device/lms/LMSDevice.cpp
@@ -112,6 +112,12 @@
 
 	delete [] info_list;
 
+	LOG(INFO) << "Init LMS device";
+	if (LMS_Init(m_lms_dev) != 0) {
+		LOG(ERROR) << "LMS_Init() failed";
+		return -1;
+	}
+
 	LOG(DEBUG) << "Setting sample rate to " << GSMRATE*sps << " " << sps;
 	if (LMS_SetSampleRate(m_lms_dev, GSMRATE*sps, 32) < 0)
 		goto out_close;
@@ -139,10 +145,6 @@
 		goto out_close;
 	}
 
-	LOG(INFO) << "Init LMS device";
-	if (LMS_Init(m_lms_dev) < 0)
-		goto out_close;
-
 	/* Perform Rx and Tx calibration */
 	for (i=0; i<chans; i++) {
 		LOG(INFO) << "Calibrating chan " << i;
-- 
To view, visit https://gerrit.osmocom.org/9603
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-trx
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: I4cdbae8406b5e1e93da491e90f8bad41d4be748b
Gerrit-Change-Number: 9603
Gerrit-PatchSet: 2
Gerrit-Owner: Harald Welte <laforge at gnumonks.org>
Gerrit-Reviewer: Harald Welte <laforge at gnumonks.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: Pau Espin Pedrol <pespin at sysmocom.de>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20180613/cb2f5c26/attachment.htm>