Matter Interaction Model codec — encode/decode IM payloads.
Decode takes an opcode atom (from ProtocolID.opcode_name) and the
raw TLV binary from ProtoHeader.payload. Encode takes a message
struct and returns TLV binary.
Attribute/command values use tagged tuples for encoding (e.g.
{:uint, 42}) and plain Elixir values after decoding.
Summary
Functions
Chunk a ReportData into multiple messages, each with at most max_reports
attribute reports. All chunks except the last have more_chunked_messages: true.
Functions
@spec chunk_report_data( %MatterEx.IM.ReportData{ attribute_reports: term(), event_reports: term(), more_chunked_messages: term(), subscription_id: term(), suppress_response: term() }, pos_integer() ) :: [ %MatterEx.IM.ReportData{ attribute_reports: term(), event_reports: term(), more_chunked_messages: term(), subscription_id: term(), suppress_response: term() } ]
Chunk a ReportData into multiple messages, each with at most max_reports
attribute reports. All chunks except the last have more_chunked_messages: true.