Our system is working fine defining the default APN in the prj.conf file. We are using the LTE Link Controller.
What I need to do is set the APN based on the SIM that happens to be installed (without a recompile). This is pretty standard behavior on most products I am familiar with.
The LTE Link Controller documentation states that the APN can be set (as well as a number of things) but I don't see any API to do so. From the documentation:
"The LTE link can be controlled through library configurations and API calls to enable a range of features such as specifying the Access Point Name (APN), switching between LTE network modes (NB-IoT or LTE-M), enabling GNSS support ... snip.... "
I assume this would be done after the call to lte_lc_init() and the call to lte_lc_connect() but I am not really sure. Perhaps I am going about this all wrong. I really trying to avoid re-inventing the wheel and use the link_controller provided by Nordic as it seems very complete except for an obvious way to set the APN.
If I use the PDN library, I am not sure how compatible that is with the lte link controller operation. I am not even sure what context ID the link controller is using.
Any ideas or pointers to documentation?