Struct multiwii_serial_protocol::structs::MspFeatures
[−]
[src]
pub struct MspFeatures { pub features: [bool; 32], }
Fields
features: [bool; 32]
Methods
impl MspFeatures
[src]
fn packed_struct_display_formatter<'a>(
&'a self
) -> PackedStructDisplay<'a, Self, [u8; 4]>
[src]
&'a self
) -> PackedStructDisplay<'a, Self, [u8; 4]>
Display formatter for console applications
Trait Implementations
impl PackedStruct<[u8; 4]> for MspFeatures
[src]
Structure that can be packed an unpacked into 4 bytes.
Bit, MSB0 | Name | Type |
0 | features[0] | bool |
1 | features[1] | bool |
2 | features[2] | bool |
3 | features[3] | bool |
4 | features[4] | bool |
5 | features[5] | bool |
6 | features[6] | bool |
7 | features[7] | bool |
8 | features[8] | bool |
9 | features[9] | bool |
10 | features[10] | bool |
11 | features[11] | bool |
12 | features[12] | bool |
13 | features[13] | bool |
14 | features[14] | bool |
15 | features[15] | bool |
16 | features[16] | bool |
17 | features[17] | bool |
18 | features[18] | bool |
19 | features[19] | bool |
20 | features[20] | bool |
21 | features[21] | bool |
22 | features[22] | bool |
23 | features[23] | bool |
24 | features[24] | bool |
25 | features[25] | bool |
26 | features[26] | bool |
27 | features[27] | bool |
28 | features[28] | bool |
29 | features[29] | bool |
30 | features[30] | bool |
31 | features[31] | bool |
fn pack(&self) -> [u8; 4]
[src]
Packs the structure into a byte array.
fn unpack(src: &[u8; 4]) -> Result<MspFeatures, PackingError>
[src]
Unpacks the structure from a byte array.
impl PackedStructInfo for MspFeatures
[src]
fn packed_bits() -> usize
[src]
Number of bits that this structure occupies when being packed.
impl PackedStructSlice for MspFeatures
[src]
fn pack_to_slice(&self, output: &mut [u8]) -> Result<(), PackingError>
[src]
Pack the structure into an output buffer.
fn unpack_from_slice(src: &[u8]) -> Result<Self, PackingError>
[src]
Unpack the structure from a buffer.
fn packed_bytes() -> usize
[src]
Number of bytes that this structure demands for packing or unpacking.
fn pack_to_vec(&self) -> Result<Vec<u8>, PackingError>
[src]
Pack the structure into a new byte vector.
impl PackedStructDebug for MspFeatures
[src]
fn fmt_fields(&self, fmt: &mut Formatter) -> Result<(), Error>
[src]
fn packed_struct_display_header() -> &'static str
[src]
impl Display for MspFeatures
[src]
fn fmt(&self, f: &mut Formatter) -> Result
[src]
Formats the value using the given formatter. Read more
impl Debug for MspFeatures
[src]
impl Copy for MspFeatures
[src]
impl Clone for MspFeatures
[src]
fn clone(&self) -> MspFeatures
[src]
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl Default for MspFeatures
[src]
fn default() -> MspFeatures
[src]
Returns the "default value" for a type. Read more