This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Incompatibility between nrf_modem_lib and at_host lib

I'm using the at cmd library ( commands like at_cmd_write_with_callback ) to communicate with the modem. 

I'm trying to enable the nrf_modem library to enable OTA updates;

# Modem library
CONFIG_NRF_MODEM_LIB=y
CONFIG_NRF_MODEM_LIB_SYS_INIT=n

it breaks the at command functions;

[00:00:12.856,750] <err> at_cmd: Failed to send AT command (err:9)
[00:00:13.056,915] <err> at_cmd: Failed to send AT command (err:9)
[00:00:13.257,049] <err> at_cmd: Failed to send AT command (err:9)
[00:00:13.457,183] <err> at_cmd: Failed to send AT command (err:9)

is this expected behavior?  How can I do OTA without breaking my current modem implementation?

Parents
  • Hello, 

    Can you elaborate more on your application? Are you using a custom application or one of the samples from NCS?

    The error you are seeing is due to modem library is not initialized before using AT sockets. Please see the Modem library integration layer. Note that when updating the modem, the modem lib initialization takes up to one minute, this is started automatically with CONFIG_NRF_MODEM_LIB_SYS_INIT. Disabling this will allow you to enter main, then you should use nrf_modem_lib_init() to initialize modem library after starting main.

    Kind regards,
    Øyvind

Reply
  • Hello, 

    Can you elaborate more on your application? Are you using a custom application or one of the samples from NCS?

    The error you are seeing is due to modem library is not initialized before using AT sockets. Please see the Modem library integration layer. Note that when updating the modem, the modem lib initialization takes up to one minute, this is started automatically with CONFIG_NRF_MODEM_LIB_SYS_INIT. Disabling this will allow you to enter main, then you should use nrf_modem_lib_init() to initialize modem library after starting main.

    Kind regards,
    Øyvind

Children
No Data
Related