nRF Connect SDK API 2.8.99
Loading...
Searching...
No Matches
nrf_cloud_fota_poll.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2024 Nordic Semiconductor ASA
3 *
4 * SPDX-License-Identifier: LicenseRef-Nordic-5-Clause
5 */
6
7#ifndef NRF_CLOUD_FOTA_POLL_H_
8#define NRF_CLOUD_FOTA_POLL_H_
9
15#include <net/nrf_cloud_rest.h>
16
17#ifdef __cplusplus
18extern "C" {
19#endif
20
31
39
48 const char *const status_details);
49
51 /* Internal variables */
53 struct k_work_delayable timeout_work;
56 const char *device_id;
58
59 /* Public variables */
60
70 uint32_t fragment_size;
71
74
82
88};
89
101
113
138
141#ifdef __cplusplus
142#endif
143
144#endif /* NRF_CLOUD_FOTA_POLL_H_ */
dfu_target_image_type
DFU image type.
Definition dfu_target.h:28
int nrf_cloud_fota_poll_init(struct nrf_cloud_fota_poll_ctx *ctx)
Initialize nRF Cloud FOTA polling assistance. Must be called before any other module functions.
nrf_cloud_fota_reboot_status
Definition nrf_cloud_fota_poll.h:25
@ FOTA_REBOOT_REQUIRED
Definition nrf_cloud_fota_poll.h:26
@ FOTA_REBOOT_SUCCESS
Definition nrf_cloud_fota_poll.h:27
@ FOTA_REBOOT_FAIL
Definition nrf_cloud_fota_poll.h:28
@ FOTA_REBOOT_SYS_ERROR
Definition nrf_cloud_fota_poll.h:29
void(* nrf_cloud_fota_poll_handler_t)(enum nrf_cloud_fota_status status, const char *const status_details)
Status event handler registered with the module to handle asynchronous status events from the module.
Definition nrf_cloud_fota_poll.h:47
int nrf_cloud_fota_poll_process_pending(struct nrf_cloud_fota_poll_ctx *ctx)
Process/validate a pending FOTA update job. This may initiate a reboot through the context's reboot f...
int nrf_cloud_fota_poll_process(struct nrf_cloud_fota_poll_ctx *ctx)
Perform the following FOTA tasks: Report the status of an in progress FOTA job. Check for a queued FO...
void(* fota_reboot_handler_t)(enum nrf_cloud_fota_reboot_status status)
Reboot event handler registered with the module to handle asynchronous reboot events from the module.
Definition nrf_cloud_fota_poll.h:38
nrf_cloud_fota_status
FOTA status reported to nRF Cloud and notified in nrf_cloud_fota_poll_handler_t.
Definition nrf_cloud.h:288
nRF Cloud REST API.
fota_reboot_handler_t reboot_fn
Definition nrf_cloud_fota_poll.h:73
enum dfu_target_image_type img_type
Definition nrf_cloud_fota_poll.h:57
const char * device_id
Definition nrf_cloud_fota_poll.h:56
struct k_work_delayable timeout_work
Definition nrf_cloud_fota_poll.h:53
uint32_t fragment_size
Definition nrf_cloud_fota_poll.h:70
bool is_nonblocking
Definition nrf_cloud_fota_poll.h:54
void * smp_reset_cb
Definition nrf_cloud_fota_poll.h:87
bool full_modem_fota_supported
Definition nrf_cloud_fota_poll.h:55
nrf_cloud_fota_poll_handler_t status_fn
Definition nrf_cloud_fota_poll.h:81
struct nrf_cloud_rest_context * rest_ctx
Definition nrf_cloud_fota_poll.h:52
Definition nrf_cloud_fota_poll.h:50
Parameters and data for using the nRF Cloud REST API.
Definition nrf_cloud_rest.h:58