Skip to main content

MCUmgrErr

Enum MCUmgrErr 

Source
#[repr(i32)]
pub enum MCUmgrErr {
Show 15 variants MGMT_ERR_EOK = 0, MGMT_ERR_EUNKNOWN = 1, MGMT_ERR_ENOMEM = 2, MGMT_ERR_EINVAL = 3, MGMT_ERR_ETIMEOUT = 4, MGMT_ERR_ENOENT = 5, MGMT_ERR_EBADSTATE = 6, MGMT_ERR_EMSGSIZE = 7, MGMT_ERR_ENOTSUP = 8, MGMT_ERR_ECORRUPT = 9, MGMT_ERR_EBUSY = 10, MGMT_ERR_EACCESSDENIED = 11, MGMT_ERR_UNSUPPORTED_TOO_OLD = 12, MGMT_ERR_UNSUPPORTED_TOO_NEW = 13, MGMT_ERR_EPERUSER = 256,
}
Expand description

Variants§

§

MGMT_ERR_EOK = 0

No error (success).

§

MGMT_ERR_EUNKNOWN = 1

Unknown error.

§

MGMT_ERR_ENOMEM = 2

Insufficient memory (likely not enough space for CBOR object).

§

MGMT_ERR_EINVAL = 3

Error in input value.

§

MGMT_ERR_ETIMEOUT = 4

Operation timed out.

§

MGMT_ERR_ENOENT = 5

No such file/entry.

§

MGMT_ERR_EBADSTATE = 6

Current state disallows command.

§

MGMT_ERR_EMSGSIZE = 7

Response too large.

§

MGMT_ERR_ENOTSUP = 8

Command not supported.

§

MGMT_ERR_ECORRUPT = 9

Corrupt

§

MGMT_ERR_EBUSY = 10

Command blocked by processing of other command

§

MGMT_ERR_EACCESSDENIED = 11

Access to specific function, command or resource denied

§

MGMT_ERR_UNSUPPORTED_TOO_OLD = 12

Requested SMP MCUmgr protocol version is not supported (too old)

§

MGMT_ERR_UNSUPPORTED_TOO_NEW = 13

Requested SMP MCUmgr protocol version is not supported (too new)

§

MGMT_ERR_EPERUSER = 256

User errors defined from 256 onwards

Implementations§

Source§

impl MCUmgrErr

Source

pub const fn from_repr(discriminant: i32) -> Option<MCUmgrErr>

Try to create Self from the raw representation

Source§

impl MCUmgrErr

Source

pub fn err_to_string(err: i32) -> String

Converts a raw error code to a string

Trait Implementations§

Source§

impl Clone for MCUmgrErr

Source§

fn clone(&self) -> MCUmgrErr

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for MCUmgrErr

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Display for MCUmgrErr

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
Source§

impl PartialEq for MCUmgrErr

Source§

fn eq(&self, other: &MCUmgrErr) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl Copy for MCUmgrErr

Source§

impl Eq for MCUmgrErr

Source§

impl StructuralPartialEq for MCUmgrErr

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit #126799)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T> ToString for T
where T: Display + ?Sized,

Source§

fn to_string(&self) -> String

Converts the given value to a String. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V