u-blox TOBY-L2, TOBY-R2, and LARA-R2 new initial bearer recommendations

Matthew Starr mstarr at hedonline.com
Fri Sep 4 20:58:51 UTC 2020


u-blox released the following guidance in June 2020 on the TOBY-L2, TOBY-R2, and LARA-R2 to setup your APN you want to connect to as the initial bearer at CID=1.

https://www.u-blox.com/sites/default/files/LTE-initial-default-bearer_AppNote_%28UBX-20015573%29.pdf

These modems already have a default CID=1 APN setup that is generic and ModemManager then uses another CID based on the APN you want to use and the IP type (IPv4, IPv6, both).  When I manually modified the modem's CID=1 entry to the correct APN and IP type to match what ModemManager is trying to use, the modem connected so much faster with ModemManager and did not have as many issues with re-connection times.

I am interested in making changes to ModemManager to implement always using CID=1 for these modems.  I know the code that handles the CID selection and creation of new ones if there is no a match is in src/mm-broadband-bearer.c.  I also know there is a plugin for u-blox that can detect model types.  What I am not sure how to do is override the functions in src/mm-broadband-bearer.c with ones that will be in the u-blox plugin.  The AT command u-blox uses to modify CIDs is AT+CGDCONT.

Additionally I still want to use the code in src/mm-broadband-bearer.c for all other u-blox modems that don't match these models.

Another difficult part of this is the modem needs to be de-registered from the network when changing CID=1 if the APN and IP type do not match what the ModemManager APN and IP type are.  The modems use AT+CFUN to put the modem in airplane mode and back to full mode when changing the CID=1 APN settings.  I don't think this works with the current data connection flow in ModemManager.

I am currently using the ModemManager 1.8.X series, but could implement the changes on the newest version and the back port them for the product I am working on.  I plan to update to the newest ModemManager eventually, but if updating now makes this easier to implement, then I might do that sooner than originally planned.

I would really appreciate some guidance on how I would best go about implementing these changes.  Thanks.

Best Regards,

Matthew Starr


More information about the ModemManager-devel mailing list