ArduinoJson supports MessagePack serialization and deserialization.
It supports all MessagePack features except bin format and timestamp.
To install ArduinoJson, you can either:
- install the library from the Arduino Library Manager,
- install the library from the Particle Web IDE, or
- download the single header from the release page.
See also: How to install ArduinoJson on arduinojson.org.
StaticJsonDocument<200> doc;
doc["hello"] = "world";
serializeMsgPack(doc, Serial);See also: serializeMsgPack() on arduinojson.org.
StaticJsonDocument<200> doc;
deserializeMsgPack(doc, input);
const char* hello = doc["hello"];See also: deserializeMsgPack() and MsgPackParser.ino on arduinojson.org.