On Thu, Mar 16, 2023 at 11:43 PM Tom Isaacson <tom.isaac...@teknique.com> wrote: > > I raised a bug related to this but haven't had a chance to debug it yet: > https://gitlab.freedesktop.org/mobile-broadband/ModemManager/-/issues/665 > > When I use QMI I find some SIM cards can connect automatically, they > don't need me to provide the APN. But ModemManager seems to insist on > it. > > > On Fri, Mar 17, 2023 at 6:11 AM Peter Naulls <pe...@chocky.org> wrote: > > > > On 3/16/23 11:53, Juan A. Rubio wrote: > > > > > Thanks Peter. > > > > > > What mechanism did you use to set the initial bearer? I'm using a > > > Network Manager connection profile in which I'm setting the APN (e.g. > > > myapn), not Telstra.internet > > > > > > [gsm] > > > apn=myapn > > > password="" > > > username="" > > > > > > Do you use mmcli or MM DBus API instead of Network Manager? > > > > mmcli where possible. My of my handling is in OpenWrt's ash; I never > > quite got to grips with DBus. > > > > Here's the section of script where we set the APN; I think logic is clear > > enough. I think it likely that there's a better way, but in our testing > > this is reliable. > > > > I'm sure Alex has more commentary here. > > > > > > config_apn=$(uci get network.wwan.apn 2>/dev/null || true) > > > > initial_bearer_apn=$(mmcli -m $modem_num 2>/dev/null | grep "initial > > bearer apn") > > > > # Might be blank if not ready yet > > if [ -n "${initial_bearer_apn}" ] ; then > > curr_apn_value=$(echo ${initial_bearer_apn} | sed 's#.*: ##' || > > true) > > > > if [ "${config_apn}" == "${curr_apn_value}" ] ; then > > message_out "Initial bearer APN correctly set to '${config_apn}'" > > apn_check_done=true > > > > else > > message_out "Initial bearer APN set to '${curr_apn_value}' vs > > configured value '${config_apn}' - setting initial bearer" > > > > mmcli -m $modem_num --enable || true > > mmcli -m $modem_num > > --3gpp-set-initial-eps-bearer-settings="apn=${config_apn},ip-type=ipv4v6" > > || true > > fi > > fi > > > > > -- > Tom Isaacson
Thanks. It still remains a mystery to me where this Telstra.internet default bearer is coming from. I'm using a SimCom 7600G by the way. Do people believe this value is coming from: - Network Manager, - Modem Manager, - SIM card or - SimCom module? And perhaps more importantly, is this used at all when the network call is established by means of a Network Manager connection profile that contains my own APN? Juan