docs: def pack(self, fmt, data):
          """
          Write bytes by packing them according to the provided format `fmt`.
          For more information about the `fmt` format see: https://docs.python.org/3/library/struct.html
  
          Args:
              fmt (str): format string.
              data (object): the data to write to the raw stream.
  
          Returns:
              int: the number of bytes written.
          """
          return self.WriteBytes(struct.pack(fmt, data), unhex=False)