Skip to main content

Module msgpack

Module msgpack 

Source
Expand description

Minimal msgpack encoder/decoder for Resource advertisements and HMU packets.

Supports the subset needed by Reticulum’s Resource protocol:

  • Nil, Bool, positive/negative fixint, uint8-64, int8-32
  • fixstr, str8
  • bin8, bin16, bin32
  • fixarray, array16
  • fixmap, map16

Enums§

Error
Msgpack error.
Value
A msgpack value.

Functions§

pack
Encode a Value to msgpack bytes.
pack_str_map
Convenience: pack a map from string keys.
unpack
Decode a single msgpack value from the start of data. Returns (value, bytes_consumed).
unpack_exact
Decode a complete msgpack value, ensuring no trailing data.