nrfxlib API 2.8.99
Loading...
Searching...
No Matches
nrf_modem.h File Reference
#include <stdbool.h>
#include <stdint.h>

Go to the source code of this file.

Data Structures

struct  nrf_modem_shmem_cfg
 Shared memory configuration in normal operation mode. More...
 
struct  nrf_modem_bootloader_shmem_cfg
 Shared memory configuration in bootloader mode. The base address must be word-aligned (4 bytes). More...
 
struct  nrf_modem_fault_info
 Modem fault info struct. More...
 
struct  nrf_modem_init_params
 Modem library initialization parameters. More...
 
struct  nrf_modem_bootloader_init_params
 Modem library bootloader initialization parameters. More...
 

Macros

#define NRF_MODEM_MAX_SHMEM_SIZE   (128 << 10) /* 128KiB */
 Maximum size in bytes of shared modem and application memory.
 
#define NRF_MODEM_DFU_RESULT_OK   0x5500001u
 
#define NRF_MODEM_DFU_RESULT_INTERNAL_ERROR   0x4400001u
 
#define NRF_MODEM_DFU_RESULT_HARDWARE_ERROR   0x4400002u
 
#define NRF_MODEM_DFU_RESULT_AUTH_ERROR   0x4400003u
 
#define NRF_MODEM_DFU_RESULT_UUID_ERROR   0x4400004u
 
#define NRF_MODEM_DFU_RESULT_VOLTAGE_LOW   0x4400005u
 
#define NRF_MODEM_CELLULAR_SHMEM_CTRL_SIZE   0x4e8
 Shared memory control region size for Cellular flavour.
 
#define NRF_MODEM_DECT_PHY_SHMEM_CTRL_SIZE   0x728
 Shared memory control region size for DECT PHY flavour.
 
#define NRF_MODEM_SHMEM_BOOTLOADER_SIZE   0x2018
 Bootloader shared memory size.
 
#define NRF_MODEM_FAULT_UNDEFINED   0x001
 
#define NRF_MODEM_FAULT_HW_WD_RESET   0x002
 
#define NRF_MODEM_FAULT_HARDFAULT   0x003
 
#define NRF_MODEM_FAULT_MEM_MANAGE   0x004
 
#define NRF_MODEM_FAULT_BUS   0x005
 
#define NRF_MODEM_FAULT_USAGE   0x006
 
#define NRF_MODEM_FAULT_SECURE_RESET   0x007
 
#define NRF_MODEM_FAULT_PANIC_DOUBLE   0x008
 
#define NRF_MODEM_FAULT_PANIC_RESET_LOOP   0x009
 
#define NRF_MODEM_FAULT_ASSERT   0x010
 
#define NRF_MODEM_FAULT_PANIC   0x011
 
#define NRF_MODEM_FAULT_FLASH_ERASE   0x012
 
#define NRF_MODEM_FAULT_FLASH_WRITE   0x013
 
#define NRF_MODEM_FAULT_POFWARN   0x014
 
#define NRF_MODEM_FAULT_THWARN   0x015
 

Typedefs

typedef void(* nrf_modem_fault_handler_t) (struct nrf_modem_fault_info *fault_info)
 Modem fault handler.
 
typedef void(* nrf_modem_dfu_handler_t) (uint32_t dfu_result)
 Modem DFU handler.
 

Functions

char * nrf_modem_build_version (void)
 Return a statically allocated string identifying the Modem library build.
 
int nrf_modem_init (const struct nrf_modem_init_params *init_params)
 Initialize the Modem library and turn on the modem.
 
int nrf_modem_bootloader_init (const struct nrf_modem_bootloader_init_params *init_params)
 Initialize the Modem library and turn on the modem in bootloader mode.
 
bool nrf_modem_is_initialized (void)
 Check whether the modem is initialized.
 
int nrf_modem_shutdown (void)
 De-initialize the Modem library and turn off the modem.