<p>Pau Espin Pedrol has uploaded this change for <strong>review</strong>.</p><p><a href="https://gerrit.osmocom.org/9678">View Change</a></p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">lms: Allow values diff than 34dB to be set by setRxGain()<br><br>Until now, setRxGain in LMSDevice did not take into account the setter<br>parameter and was always using hardcoded 34dB, which was experimentally<br>found to be a good default value.<br><br>Let's force that value during initialization, but still allow the upper<br>layers (controlled by BTS) to set different values. osmo-bts only sends<br>a SETRXGAIN command (which calls setRxGain in osmo-trx) if a value is<br>explicitly set in its VTY config, so we are on the safe side if the user<br>doesn't explicitly configure a desired dB.<br><br>Change-Id: I5684e675281a3f581855dbb56d199a6fe238a712<br>---<br>M Transceiver52M/device/lms/LMSDevice.cpp<br>1 file changed, 1 insertion(+), 3 deletions(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">git pull ssh://gerrit.osmocom.org:29418/osmo-trx refs/changes/78/9678/1</pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;"><span>diff --git a/Transceiver52M/device/lms/LMSDevice.cpp b/Transceiver52M/device/lms/LMSDevice.cpp</span><br><span>index 16585e6..ffea505 100644</span><br><span>--- a/Transceiver52M/device/lms/LMSDevice.cpp</span><br><span>+++ b/Transceiver52M/device/lms/LMSDevice.cpp</span><br><span>@@ -223,7 +223,7 @@</span><br><span> </span><br><span>             // Set gains to midpoint</span><br><span>             setTxGain((minTxGain() + maxTxGain()) / 2, i);</span><br><span style="color: hsl(0, 100%, 40%);">-          setRxGain((minRxGain() + maxRxGain()) / 2, i);</span><br><span style="color: hsl(120, 100%, 40%);">+                setRxGain(34.0, i);</span><br><span> </span><br><span>              m_lms_stream_rx[i] = {};</span><br><span>             m_lms_stream_rx[i].isTx = false;</span><br><span>@@ -327,8 +327,6 @@</span><br><span>               return 0.0;</span><br><span>  }</span><br><span> </span><br><span style="color: hsl(0, 100%, 40%);">-   dB = 34.0;</span><br><span style="color: hsl(0, 100%, 40%);">-</span><br><span>   if (dB > maxRxGain())</span><br><span>             dB = maxRxGain();</span><br><span>    if (dB < minRxGain())</span><br><span></span><br></pre><p>To view, visit <a href="https://gerrit.osmocom.org/9678">change 9678</a>. To unsubscribe, or for help writing mail filters, visit <a href="https://gerrit.osmocom.org/settings">settings</a>.</p><div itemscope itemtype="http://schema.org/EmailMessage"><div itemscope itemprop="action" itemtype="http://schema.org/ViewAction"><link itemprop="url" href="https://gerrit.osmocom.org/9678"/><meta itemprop="name" content="View Change"/></div></div>

<div style="display:none"> Gerrit-Project: osmo-trx </div>
<div style="display:none"> Gerrit-Branch: master </div>
<div style="display:none"> Gerrit-MessageType: newchange </div>
<div style="display:none"> Gerrit-Change-Id: I5684e675281a3f581855dbb56d199a6fe238a712 </div>
<div style="display:none"> Gerrit-Change-Number: 9678 </div>
<div style="display:none"> Gerrit-PatchSet: 1 </div>
<div style="display:none"> Gerrit-Owner: Pau Espin Pedrol <pespin@sysmocom.de> </div>