Skip to main content

encode_frame

Function encode_frame 

Source
pub fn encode_frame(
    w: &mut Writer<'_>,
    transaction_id: u16,
    unit_id: UnitId,
    pdu: &[u8],
) -> Result<(), EncodeError>
Expand description

Encode a complete Modbus TCP frame (MBAP header + PDU) into the writer.