[][src]Enum sawp_modbus::Write

pub enum Write {
    MultReq {
        address: u16,
        quantity: u16,
        data: Vec<u8>,
    },
    Mask {
        address: u16,
        and_mask: u16,
        or_mask: u16,
    },
    Other {
        address: u16,
        data: u16,
    },
}

Write information on parsed in function data

Variants

MultReq

AccessType::MULTIPLE requests, responses fall in Write::Other

Fields of MultReq

address: u16quantity: u16data: Vec<u8>
Mask

FunctionCode::MaskWrReg requests/responses, the only (public) write function that does not fall under AccessType::SINGLE/AccessType::MULTIPLE (with the exception of FunctionCode::WrFileRec)

Fields of Mask

address: u16and_mask: u16or_mask: u16
Other

Used for AccessType::SINGLE requests/responses and AccessType::MULTIPLE responses

Fields of Other

address: u16data: u16

Trait Implementations

impl Debug for Write[src]

impl PartialEq<Write> for Write[src]

impl StructuralPartialEq for Write[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.