MeshCore icon

MeshCore

Interact with a MeshCore device over TCP/WiFi

Utility → Encode Raw Frame

AI-generated

Summary

Builds a complete MeshCore raw frame from a payload and routing details, returning the encoded frame as hex for use in another operation or system.

Inputs

  • Payload (required) — Hex payload bytes, used as given.
  • Payload Type (required) — Firmware payload type value from 0 to 15.
  • Payload Version — Header version bits, from 0 to 3; the firmware currently accepts only 0.
  • Route Type — Choose Flood, Direct, Transport Flood, or Transport Direct. Defaults to Flood.
  • Path — Hex path-hash bytes, hop by hop. Leave empty for zero hops; the byte length must divide evenly by the selected path hash size.
  • Transport Code 1 — First transport code, from 0 to 65535; used for transport route types.
  • Transport Code 2 — Second transport code, from 0 to 65535; used for transport route types.
  • Path Hash Size — Bytes per hop: 1, 2, or 3. Match the mesh's setting, available as pathHashSize in Device → Get Device Info.

Output shape

A single item containing the encoded raw frame as hex.

The frame includes the header, applicable transport codes, packed path length, path, and payload. The source implementation constructs the frame locally; it does not send it to the mesh.

Links

Discussion