Zephyr API Documentation 4.0.0
A Scalable Open Source RTOS
Loading...
Searching...
No Matches
mgmt_defines.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2018-2021 mcumgr authors
3 * Copyright (c) 2022-2023 Nordic Semiconductor ASA
4 *
5 * SPDX-License-Identifier: Apache-2.0
6 */
7
8#ifndef H_MGMT_MGMT_DEFINES_
9#define H_MGMT_MGMT_DEFINES_
10
11#include <inttypes.h>
12
13#ifdef __cplusplus
14extern "C" {
15#endif
16
28#define MGMT_RETURN_CHECK(ok) ok ? MGMT_ERR_EOK : MGMT_ERR_EMSGSIZE
29
44
92
142
143#define MGMT_HDR_SIZE 8
144
149#ifdef __cplusplus
150}
151#endif
152
153#endif /* MGMT_MGMT_DEFINES_H_ */
mcumgr_group_t
MCUmgr groups.
Definition mgmt_defines.h:49
mcumgr_err_t
MCUmgr error codes.
Definition mgmt_defines.h:96
mcumgr_op_t
Opcodes; encoded in first byte of header.
Definition mgmt_defines.h:31
@ MGMT_GROUP_ID_SETTINGS
Settings management (config) group, used for reading/writing settings.
Definition mgmt_defines.h:60
@ MGMT_GROUP_ID_ENUM
Enumeration management group, used for listing supported command groups.
Definition mgmt_defines.h:81
@ MGMT_GROUP_ID_SPLIT
Split image management group (unused)
Definition mgmt_defines.h:69
@ MGMT_GROUP_ID_IMAGE
Image management group, used for uploading firmware images.
Definition mgmt_defines.h:54
@ MGMT_GROUP_ID_RUN
Run group (unused)
Definition mgmt_defines.h:72
@ MGMT_GROUP_ID_OS
OS (operating system) group.
Definition mgmt_defines.h:51
@ MGMT_GROUP_ID_SHELL
Shell management group, used for executing shell commands.
Definition mgmt_defines.h:78
@ MGMT_GROUP_ID_STAT
Statistic management group, used for retrieving statistics.
Definition mgmt_defines.h:57
@ ZEPHYR_MGMT_GRP_BASIC
Zephyr-specific groups decrease from PERUSER to avoid collision with upstream and user-defined groups...
Definition mgmt_defines.h:90
@ MGMT_GROUP_ID_FS
FS (file system) group, used for performing file IO operations.
Definition mgmt_defines.h:75
@ MGMT_GROUP_ID_LOG
Log management group (unused)
Definition mgmt_defines.h:63
@ MGMT_GROUP_ID_PERUSER
User groups defined from 64 onwards.
Definition mgmt_defines.h:84
@ MGMT_GROUP_ID_CRASH
Crash group (unused)
Definition mgmt_defines.h:66
@ MGMT_ERR_EPERUSER
User errors defined from 256 onwards.
Definition mgmt_defines.h:140
@ MGMT_ERR_EMSGSIZE
Response too large.
Definition mgmt_defines.h:119
@ MGMT_ERR_ENOTSUP
Command not supported.
Definition mgmt_defines.h:122
@ MGMT_ERR_EINVAL
Error in input value.
Definition mgmt_defines.h:107
@ MGMT_ERR_EOK
No error (success).
Definition mgmt_defines.h:98
@ MGMT_ERR_EBADSTATE
Current state disallows command.
Definition mgmt_defines.h:116
@ MGMT_ERR_ENOENT
No such file/entry.
Definition mgmt_defines.h:113
@ MGMT_ERR_EUNKNOWN
Unknown error.
Definition mgmt_defines.h:101
@ MGMT_ERR_EBUSY
Command blocked by processing of other command.
Definition mgmt_defines.h:128
@ MGMT_ERR_UNSUPPORTED_TOO_OLD
Requested SMP MCUmgr protocol version is not supported (too old)
Definition mgmt_defines.h:134
@ MGMT_ERR_EACCESSDENIED
Access to specific function, command or resource denied.
Definition mgmt_defines.h:131
@ MGMT_ERR_ECORRUPT
Corrupt.
Definition mgmt_defines.h:125
@ MGMT_ERR_ETIMEOUT
Operation timed out.
Definition mgmt_defines.h:110
@ MGMT_ERR_ENOMEM
Insufficient memory (likely not enough space for CBOR object).
Definition mgmt_defines.h:104
@ MGMT_ERR_UNSUPPORTED_TOO_NEW
Requested SMP MCUmgr protocol version is not supported (too new)
Definition mgmt_defines.h:137
@ MGMT_OP_WRITE
Write op-code.
Definition mgmt_defines.h:39
@ MGMT_OP_WRITE_RSP
Write response op-code.
Definition mgmt_defines.h:42
@ MGMT_OP_READ
Read op-code.
Definition mgmt_defines.h:33
@ MGMT_OP_READ_RSP
Read response op-code.
Definition mgmt_defines.h:36