Preparing for production

Before deploying devices that use the LwM2M carrier library, consider the following prerequisites.

Root CA certificates

You can optimize your application by removing or adding certificates based on your product needs. Refer to the respective documentation of one or more of your operators for more information on which certificates apply.

The Cellular: LwM2M carrier sample contains a couple of root CA certificates that are typically used for out-of-band firmware updates. The carrier with which you plan to certify your product might not require the included certificates. Also, the certificates needed by the carrier might not be present in the sample. Hence it might become necessary to program the required certificates.

Pre-programming the certificates

The certificates are typically stored in the modem. The LwM2M carrier sample writes the certificates to the modem if they are not already present. Alternatively, you can also write the certificates beforehand using the Cellular: AT Client sample.

To pre-program the certificates, use one of the following methods:

  • Build and flash the Cellular: AT Client sample and provision the certificates using AT commands and the Cellular Monitor application. See Managing credentials for more information.

  • Build and flash the LwM2M carrier sample, while making sure that the appropriate certificates (*.pem) are included in the certs folder and referenced in carrier_certs.c.

Other samples and applications like Asset Tracker v2 and Cellular: Modem Shell with the carrier library integration do not write any certificates in the application.

Pre-shared Key (PSK)

In live (production) environment, the correct PSK is generated and stored in the modem depending on which operator network the device is in. The application should not provide a custom security tag using CONFIG_LWM2M_CARRIER_SERVER_SEC_TAG in this case.

If the device is operating outside the supported operator network, then the custom security tag will be applied.

Carrier configuration and testing

  • The library supports carriers which have specific device management requirements. Not all requirements are documented here. You must contact your carrier for more information as mentioned in the Certification and version dependencies documentation.

    • With a few exceptions, if you leave the lwm2m_carrier_config_t structure empty when calling lwm2m_carrier_main(), it configures the carrier library to behave correctly in the operator network it is currently connected to.

  • The settings required to test and certify your product with the carrier will be different from the settings needed for mass deployment.

LG U+ operator requirements

Following are the configurations are required for using the library with the LG U+ operator network: