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/.
fixeria gerrit-no-reply at lists.osmocom.orgfixeria has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-trx/+/20076 )
Change subject: radioDevice: fix set_antennas(): consider MULTI_ARFCN mode
......................................................................
radioDevice: fix set_antennas(): consider MULTI_ARFCN mode
In the multi-ARFCN mode, if the Tx/Rx antenna names are explicitly
set in 'chan N' sections of the configuration file:
trx
...
multi-arfcn disable
chan 0
tx-path TX/RX
rx-path RX2
chan 1
tx-path TX/RX
rx-path RX2
chan 2
tx-path TX/RX
rx-path RX2
osmo-trx would crash, because radioDevice::set_antennas() would
attempt to configure antenna names for all N physical channels,
while USRP devices usually have 2 or even 1 available.
The easiest approach is to remove both 'tx-path'/'rx-path' from
all 'chan N' sections excluding 'chan 0', so it would work fine.
This makes sense, because in the multi-ARFCN mode we actually
use only one physical channel.
However, let's still make sure that explicit configuration of the
Tx/Rx antenna names would not crash osmo-trx and skip N > 0 in
radioDevice::set_antennas().
Change-Id: I09f316f181cbbc2214e8913b73f7c1fcea4e8c05
Related: OS#4636
---
M Transceiver52M/device/common/radioDevice.h
1 file changed, 6 insertions(+), 2 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-trx refs/changes/76/20076/1
diff --git a/Transceiver52M/device/common/radioDevice.h b/Transceiver52M/device/common/radioDevice.h
index cfe65da..56b6aa9 100644
--- a/Transceiver52M/device/common/radioDevice.h
+++ b/Transceiver52M/device/common/radioDevice.h
@@ -181,9 +181,12 @@
}
bool set_antennas() {
+ unsigned int tx_paths_len;
+ unsigned int rx_paths_len;
unsigned int i;
- for (i = 0; i < tx_paths.size(); i++) {
+ tx_paths_len = (iface == MULTI_ARFCN) ? 1 : tx_paths.size();
+ for (i = 0; i < tx_paths_len; i++) {
if (tx_paths[i] == "")
continue;
LOGCHAN(i, DDEV, DEBUG) << "Configuring Tx antenna " << tx_paths[i];
@@ -193,7 +196,8 @@
}
}
- for (i = 0; i < rx_paths.size(); i++) {
+ rx_paths_len = (iface == MULTI_ARFCN) ? 1 : rx_paths.size();
+ for (i = 0; i < rx_paths_len; i++) {
if (rx_paths[i] == "")
continue;
LOGCHAN(i, DDEV, DEBUG) << "Configuring Rx antenna " << rx_paths[i];
--
To view, visit https://gerrit.osmocom.org/c/osmo-trx/+/20076
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-trx
Gerrit-Branch: master
Gerrit-Change-Id: I09f316f181cbbc2214e8913b73f7c1fcea4e8c05
Gerrit-Change-Number: 20076
Gerrit-PatchSet: 1
Gerrit-Owner: fixeria <vyanitskiy at sysmocom.de>
Gerrit-MessageType: newchange
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20200911/2131775b/attachment.htm>