Build: enhance docker use, reducing build options, cleanup
[marnav.git] / src / marnav / seatalk / message_6c.hpp
blobed9c08acf03434e92e39b5cafdcbbfbf6e029a4b
1 #ifndef MARNAV__SEATALK__MESSAGE_6C__HPP
2 #define MARNAV__SEATALK__MESSAGE_6C__HPP
4 #include <marnav/seatalk/message.hpp>
5 #include <marnav/seatalk/equipment.hpp>
7 namespace marnav
9 namespace seatalk
11 /// @brief Second Equipment ID
12 ///
13 /// Second equipment ID message, follows message `01`.
14 ///
15 /// @code
16 /// 6c 05 XX XX XX XX XX XX
17 /// @endcode
18 ///
19 /// Known examples:
20 /// @code
21 /// 6C 05 04 BA 20 28 2D 2D : ST60 Tridata
22 /// 6C 05 05 70 99 10 28 2D : ST60 Log
23 /// 6C 05 F3 18 00 26 2D 2D : ST80 Masterview
24 /// @endcode
25 ///
26 class message_6c : public message
28 public:
29 constexpr static const message_id ID = message_id::equipment_id_2;
30 constexpr static size_t SIZE = 8;
32 /// @{
33 constexpr static equipment_id st60_tridata{{0x04, 0xba, 0x20, 0x28, 0x2d, 0x2d}};
34 constexpr static equipment_id st60_log{{0x05, 0x70, 0x99, 0x10, 0x28, 0x2d}};
35 constexpr static equipment_id st80_masterview{{0xf3, 0x18, 0x00, 0x26, 0x2d, 0x2d}};
36 /// @}
38 message_6c();
39 message_6c(const message_6c &) = default;
40 message_6c & operator=(const message_6c &) = default;
42 virtual raw get_data() const override;
44 static std::unique_ptr<message> parse(const raw & data);
46 private:
47 equipment_id id_;
49 public:
50 equipment_id get_equipment_id() const noexcept { return id_; }
52 void set_equipment_id(const equipment_id & t) noexcept { id_ = t; }
57 #endif