<html><head></head><body><div style="font-family: Verdana;font-size: 12.0px;"><div>Hi Alkesander,</div>
<div>
<div> </div>
<div>Thanks for the advice. </div>
<div> </div>
<div>Attached are my log files from MM and qmi-proxy. </div>
<div> </div>
<div>This time when I set the preferred mode to 2G via MM, the sequence from AT-cmd did not change (first 4G then 2G). And after setting to 4G, the sequence from modem changed to: first 2G then 4G. See my test sequence below.</div>
<div> </div>
<div>
<p># mmcli -m 0 --set-allowed-modes='2g|4g' --set-preferred-mode='2g'</p>
<p>successfully set current modes in the modem</p>
<p># mmcli -m 0 --command="AT+QCFG=\"nwscanseq\""</p>
<p>response: '+QCFG: "nwscanseq",020301'</p>
<p># mmcli -m 0 --set-allowed-modes='2g|4g' --set-preferred-mode='4g'</p>
<p>successfully set current modes in the modem</p>
<p># mmcli -m 0 --command="AT+QCFG=\"nwscanseq\""</p>
<p>response: '+QCFG: "nwscanseq",010203'</p>
<p> </p>
<p>Usually only "set-preferred-mode='4g'" does not work for me. Maybe this is a speical test run. if you need logs from NetworkManager or from other test runs, just let me know and I will do more tests and send the logs.</p>
<p>Thanks,</p>
<p>Songwei</p>
</div>
<div>
<div name="quote" style="margin:10px 5px 5px 10px; padding: 10px 0 10px 10px; border-left:2px solid #C3D9E5; word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;">
<div style="margin:0 0 10px 0;"><b>Gesendet:</b> Mittwoch, 01. Dezember 2021 um 11:16 Uhr<br/>
<b>Von:</b> "Aleksander Morgado" <aleksander@aleksander.es><br/>
<b>An:</b> songwei.fu@web.de<br/>
<b>Cc:</b> "ModemManager (development)" <modemmanager-devel@lists.freedesktop.org><br/>
<b>Betreff:</b> Re: Unable to set preferred mode to 4G from ModemManager for Quectel BG96</div>
<div name="quoted-content">Hey,<br/>
<br/>
> 2. Then I set the priority to 2G. Both MM and AT-cmd shows the 2G has now priority.<br/>
><br/>
> # mmcli -m 1 --set-allowed-modes='2g|4g' --set-preferred-mode='2g'<br/>
> successfully set current modes in the modem<br/>
> #<br/>
> # mmcli -m 1 --command="AT+QCFG=\"nwscanseq\""<br/>
> response: '+QCFG: "nwscanseq",010203'<br/>
><br/>
> 3. Then I wanted to set the priority to 4G again. But could not do it with MM. AT comamnd shows the search sequence does not change. But the MM "thinks" the priority is already set back to 4G.<br/>
><br/>
> # mmcli -m 1 --set-allowed-modes='2g|4g' --set-preferred-mode='4g'<br/>
> successfully set current modes in the modem<br/>
> #<br/>
> #<br/>
> # mmcli -m 1 --command="AT+QCFG=\"nwscanseq\""<br/>
> response: '+QCFG: "nwscanseq",010203'<br/>
><br/>
<br/>
We need to see what kind of QMI responses we get from the modem, maybe<br/>
there is something we're not processing right.<br/>
Could you please retry this sequence but with debugging enabled? see<br/>
<a href="https://modemmanager.org/docs/modemmanager/debugging/" target="_blank">https://modemmanager.org/docs/modemmanager/debugging/</a><br/>
<br/>
--<br/>
Aleksander<br/>
<a href="https://aleksander.es" target="_blank">https://aleksander.es</a></div>
</div>
</div>
</div></div></body></html>