FastLED 3.9.15
Loading...
Searching...
No Matches
json.h
Go to the documentation of this file.
1#pragma once
2
3#ifndef FASTLED_ENABLE_JSON
4#ifdef __AVR__
5#define FASTLED_ENABLE_JSON 0
6#else
7#define FASTLED_ENABLE_JSON 1
8#endif
9#endif
10
11#if FASTLED_ENABLE_JSON
13#endif
14
15namespace fl {
16
17class Str;
18
19#if !FASTLED_ENABLE_JSON
20class JsonDocument {};
21#else
22class JsonDocument : public ::FLArduinoJson::JsonDocument {};
23#endif
24
25// Parses a JSON string into a JsonDocument.
26bool parseJson(const char *json, JsonDocument *doc, Str *error = nullptr);
27
28// Serializes a JsonDocument to a string.
29void toJson(const JsonDocument &doc, Str *jsonBuffer);
30
31} // namespace fl
bool parseJson(const char *json, fl::JsonDocument *doc, Str *_error)
Definition json.cpp:6
void toJson(const fl::JsonDocument &doc, Str *jsonBuffer)
Definition json.cpp:24
Implements a simple red square effect for 2D LED grids.
Definition crgb.h:16