All Projects → menan → SparkJson

menan / SparkJson

Licence: MIT License
JSON library Ported from @bblanchon for Spark Core

Programming Languages

C++
36643 projects - #6 most used programming language

Projects that are alternatives of or similar to SparkJson

neopo
A lightweight solution for local Particle development.
Stars: ✭ 19 (-47.22%)
Mutual labels:  particle, photon
Particle Api Js
JS Library for the Particle API
Stars: ✭ 112 (+211.11%)
Mutual labels:  particle, photon
Device Os
Device OS (Firmware) for Particle Devices
Stars: ✭ 976 (+2611.11%)
Mutual labels:  particle, photon
Docs
Documentation for Particle
Stars: ✭ 131 (+263.89%)
Mutual labels:  particle, photon
Hardware Libraries
Particle parts for computer-aided design (CAD)
Stars: ✭ 77 (+113.89%)
Mutual labels:  particle, photon
Particle Cli
Command Line Interface for Particle Cloud and devices
Stars: ✭ 208 (+477.78%)
Mutual labels:  particle, photon
phaser-particle-editor-plugin
This plugin creates particles based on JSON data generated by Phaser Particle Editor
Stars: ✭ 28 (-22.22%)
Mutual labels:  particle
revgeo
Reverse Geocoding in R with Google Maps API and Photon API
Stars: ✭ 20 (-44.44%)
Mutual labels:  photon
carloop
Carloop OBDII reader
Stars: ✭ 21 (-41.67%)
Mutual labels:  particle
EasyConfetti
🎊 Fancy confetti effects in Swift
Stars: ✭ 557 (+1447.22%)
Mutual labels:  particle
ParticleLib
一个用于Minecraft Particle的类库
Stars: ✭ 19 (-47.22%)
Mutual labels:  particle
spark-sdk-ios
DEPRECATED Particle iOS Cloud SDK. Use -->
Stars: ✭ 52 (+44.44%)
Mutual labels:  particle
vue-photonkit
Photonkit components for Vue
Stars: ✭ 15 (-58.33%)
Mutual labels:  photon
particle
Package to deal with particles, the PDG particle data table, PDGIDs, etc.
Stars: ✭ 113 (+213.89%)
Mutual labels:  particle
preact-photon-electron-quick-start
Demo desktop app built with Electron using the Preact-Photon UI library
Stars: ✭ 32 (-11.11%)
Mutual labels:  photon
power-mode-input
PowerModeInput can make your text input box more compelling
Stars: ✭ 68 (+88.89%)
Mutual labels:  particle
karting
A multiplayer racing example project in Unity using the SocketWeaver SDK
Stars: ✭ 39 (+8.33%)
Mutual labels:  photon
status-o-cat
GitHub system status indicator
Stars: ✭ 13 (-63.89%)
Mutual labels:  particle
Paperino
E-Paper display library for the Particle & Arduino family.
Stars: ✭ 35 (-2.78%)
Mutual labels:  particle
Corpuscles.jl
Julia package for particle physics
Stars: ✭ 25 (-30.56%)
Mutual labels:  particle

Arduino JSON library

Build Status Coverage Status

An elegant and efficient JSON library for embedded systems.

It's design to have the most intuitive API, the smallest footprint and works without any allocation on the heap (no malloc).

It has been written with Arduino in mind, but it isn't linked to Arduino libraries so you can use this library in any other C++ project.

Features

  • JSON decoding
  • JSON encoding (with optional indentation)
  • Elegant API, very easy to use
  • Fixed memory allocation (no malloc)
  • Small footprint
  • MIT License

Quick start

Decoding / Parsing

char json[] = "{\"sensor\":\"gps\",\"time\":1351824120,\"data\":[48.756080,2.302038]}";

StaticJsonBuffer<200> jsonBuffer;

JsonObject& root = jsonBuffer.parseObject(json);

const char* sensor = root["sensor"];
long time          = root["time"];
double latitude    = root["data"][0];
double longitude   = root["data"][1];

Encoding / Generating

StaticJsonBuffer<200> jsonBuffer;

JsonObject& root = jsonBuffer.createObject();
root["sensor"] = "gps";
root["time"] = 1351824120;

JsonArray& data = root.createNestedArray("data");
data.add(48.756080, 6);  // 6 is the number of decimals to print
data.add(2.302038, 6);   // if not specified, 2 digits are printed

root.printTo(Serial);
// This prints:
// {"sensor":"gps","time":1351824120,"data":[48.756080,2.302038]}

Documentation

The documentation is available online in the Arduino JSON wiki

Testimonials

From Arduino's Forum user jflaplante:

I tried aJson json-arduino before trying your library. I always ran into memory problem after a while. I have no such problem so far with your library. It is working perfectly with my web services.

From Arduino's Forum user gbathree:

Thanks so much - this is an awesome library! If you want to see what we're doing with it - the project is located at www.photosynq.org.

From StackOverflow user thegreendroid:

It has a really elegant, simple API and it works like a charm on embedded and Windows/Linux platforms. We recently started using this on an embedded project and I can vouch for its quality.

From GitHub user zacsketches:

Thanks for a great library!!! I've been watching you consistently develop this library over the past six months, and I used it today for a publish and subscribe architecture designed to help hobbyists move into more advanced robotics. Your library allowed me to implement remote subscription in order to facilitate multi-processor robots. ArduinoJson saved me a week's worth of time!!


Found this library useful? Help me back with a donation! 😄

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].