Anjay Lite
Loading...
Searching...
No Matches
lwm2m_send.h
Go to the documentation of this file.
1/*
2 * Copyright 2023-2025 AVSystem <avsystem@avsystem.com>
3 * AVSystem Anjay Lite LwM2M SDK
4 * All rights reserved.
5 *
6 * Licensed under AVSystem Anjay Lite LwM2M Client SDK - Non-Commercial License.
7 * See the attached LICENSE file for details.
8 */
9
10#include <anj/init.h>
11
22#ifndef ANJ_LWM2M_SEND_H
23# define ANJ_LWM2M_SEND_H
24
25# include <anj/defs.h>
26
27# ifdef __cplusplus
28extern "C" {
29# endif
30
31# ifdef ANJ_WITH_LWM2M_SEND
32
38# define ANJ_SEND_ID_ALL UINT16_MAX
39
46# define ANJ_SEND_SUCCESS 0
47
63# define ANJ_SEND_ERR_TIMEOUT -1
64
74# define ANJ_SEND_ERR_ABORT -2
75
86# define ANJ_SEND_ERR_REJECTED -3
87
92# define ANJ_SEND_ERR_NETWORK -4
93
98# define ANJ_SEND_ERR_INTERNAL -5
99
101# define ANJ_SEND_ERR_NO_REQUEST_FOUND -6
102
106# define ANJ_SEND_ERR_NO_SPACE -7
107
114# define ANJ_SEND_ERR_NOT_ALLOWED -8
115
117# define ANJ_SEND_ERR_DATA_NOT_VALID -9
118
/* end of anj_send_errors */
120
129typedef enum {
130# ifdef ANJ_WITH_SENML_CBOR
132# endif // ANJ_WITH_SENML_CBOR
133# ifdef ANJ_WITH_LWM2M_CBOR
135# endif // ANJ_WITH_LWM2M_CBOR
137
147 uint16_t send_id,
148 int result,
149 void *data);
150
172
208 const anj_send_request_t *send_request,
209 uint16_t *out_send_id);
210
227int anj_send_abort(anj_t *anj, uint16_t send_id);
228
230# define ANJ_INTERNAL_INCLUDE_SEND
231# include <anj_internal/lwm2m_send.h>
232# undef ANJ_INTERNAL_INCLUDE_SEND
235# endif // ANJ_WITH_LWM2M_SEND
236
237# ifdef __cplusplus
238}
239# endif
240
241#endif // ANJ_LWM2M_SEND_H
Core type and constant definitions for Anjay Lite.
struct anj_struct anj_t
Definition defs.h:136
Global configuration validation header for Anjay Lite.
void anj_send_finished_handler_t(anj_t *anjay, uint16_t send_id, int result, void *data)
Definition lwm2m_send.h:146
int anj_send_new_request(anj_t *anj, const anj_send_request_t *send_request, uint16_t *out_send_id)
anj_send_content_format_t
Definition lwm2m_send.h:129
@ ANJ_SEND_CONTENT_FORMAT_SENML_CBOR
Definition lwm2m_send.h:131
@ ANJ_SEND_CONTENT_FORMAT_LWM2M_CBOR
Definition lwm2m_send.h:134
int anj_send_abort(anj_t *anj, uint16_t send_id)
Definition defs.h:591
Definition lwm2m_send.h:154
void * data
Definition lwm2m_send.h:167
const anj_io_out_entry_t * records
Definition lwm2m_send.h:156
anj_send_content_format_t content_format
Definition lwm2m_send.h:170
anj_send_finished_handler_t * finished_handler
Definition lwm2m_send.h:164
size_t records_cnt
Definition lwm2m_send.h:159