Sen descrición

Benoit Blanchon 851d21e08c Added JsonObjectIterator %!s(int64=11) %!d(string=hai) anos
JsonGenerator 45c9ba1191 Renamed JsonObjectBase into JsonPrintable %!s(int64=11) %!d(string=hai) anos
JsonGeneratorTests 45c9ba1191 Renamed JsonObjectBase into JsonPrintable %!s(int64=11) %!d(string=hai) anos
JsonParser 851d21e08c Added JsonObjectIterator %!s(int64=11) %!d(string=hai) anos
JsonParserTests 851d21e08c Added JsonObjectIterator %!s(int64=11) %!d(string=hai) anos
examples 0d4d77a7cd Updated example %!s(int64=11) %!d(string=hai) anos
.gitignore 895482de15 Merged the two Visual Studio solutions into one %!s(int64=11) %!d(string=hai) anos
ArduinoJson.sln 895482de15 Merged the two Visual Studio solutions into one %!s(int64=11) %!d(string=hai) anos
CHANGELOG.md 9f07cdcabf Updated CHANGELOG.md %!s(int64=11) %!d(string=hai) anos
JsonGenerator.cpp 5bb6cd0fa9 Extracted class JsonArrayBase to reduce code size %!s(int64=11) %!d(string=hai) anos
JsonGenerator.h e8831c28d9 Added JsonGenerator example for Arduino %!s(int64=11) %!d(string=hai) anos
JsonParser.cpp b75d32e980 Renamed JsonHashTable into JsonObject %!s(int64=11) %!d(string=hai) anos
JsonParser.h 3d8b31b1ec Moved all JsonParser code in a sub-folder. %!s(int64=11) %!d(string=hai) anos
README.md 339de21f1c Updated code size %!s(int64=11) %!d(string=hai) anos
keywords.txt 0e9840da3f Removed multiple tabs that prevent the syntax highlighting from working %!s(int64=12) %!d(string=hai) anos

README.md

Arduino JSON library

A simple and efficient JSON library for embedded systems.

It's design to be very lightweight, 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

Feature comparison

Library Memory allocation Nested objects Parser size Encoder size
Arduino JSON static yes 2616 Bytes 628 bytes
json-arduino dynamic no 3348 (+28%) not supported
aJson dynamic yes 5088 (+94%) 4678 (+640%)

"Parser size" was measured with a program parsing {"sensor":"outdoor","value":25.6}. For each library, I wrote a program that extracts a string and a float. I subtracted the size of a program doing the same without any JSON parsing involved. Source files are here.

"Encoder size" was measured with a program generating {"sensor":"outdoor","value":25.6}. Source files are here.

In each case the target platform was an Arduino Duemilanove and Arduino IDE 1.0.5 was used.

Links: json-arduino, aJson

Testimonials

From Arduino's Forum user jflaplante:

I tried the [aJson and 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.

Links