open_protocol/messages/
link_communication.rs

1use open_protocol_codec_proc_macro::{OpenProtocolDecode, OpenProtocolEncode, OpenProtocolMessage};
2
3/// 5.1.1 MID 9998 Communication acknowledge error
4/// This message is used in conjunction with the use of header sequence number.
5#[derive(Debug, Default, Eq, PartialEq, OpenProtocolEncode, OpenProtocolDecode, OpenProtocolMessage)]
6#[open_protocol_message(MID = 9998, revision = 1)]
7pub struct MID9998rev1 {
8    /// MID number to which the acknowledgment error belongs to
9    #[open_protocol_field(length = 4)]
10    pub mid_number: u16,
11
12    /// Error code for the sent message
13    #[open_protocol_field(length = 4)]
14    pub error_code: u16,
15}
16
17/// 5.1.2 MID 9997 Communication acknowledge
18/// This message is used in conjunction with the use of header sequence number.
19#[derive(Debug, Default, Eq, PartialEq, OpenProtocolEncode, OpenProtocolDecode, OpenProtocolMessage)]
20#[open_protocol_message(MID = 9997, revision = 1)]
21pub struct MID9997rev1 {
22    /// Acknowledged MID number
23    #[open_protocol_field(length = 4)]
24    pub mid_number: u16,
25}