Where is a good place to ask about Arduino-JSON?

Hello Everybody,

I'm trying to analyse how the ESP-Dash-library works.
Gipo of ESP-Dash
It makes heave use of Arduino-JSON.
I'm a bit unsecure if this user-forum is the best place to ask Arduino-JSON-questions
or maybe looking for a JSON-userforum in general (not an Arduino-JSON-specific forum)

I estimate that JSON is the same as Arduino-JSON. Maybe some special functions left out for RAM-saving reasons.

So does anybody know of a user-forum where some users are JSON-specialists?
If they are right here at Arduino-cc even better.

best regards Stefan

JSON is a very simple thing but ArduinoJSON is a very special and efficient library for Arduino, so no JSON forum would not help you.

The library has extensive documentation.

If you have a specific question, try ask on Arduino Stack Exchange. Usually the author of the library answers these questions there.

Hi Jural,

thank you very much for answering.
best regards Stefan

Benoît Blanchon wrote the Arduino-JSON library and he has extensive documentation(and examples, videos) on line

All bugs, features, and discussions about ArduinoJson are in the GitHub issues but I think your question regarding ESP-Dash will not really be ArduinoJson related but understanding how to add an index into the JSON description

You will need to add a _card_index variable in the Card Class instance variables, modify the constructor to be able to define the index (or a grid position)

Then you will need to include this cardIndex into the JSON that is built for that card. it will likely happen in the generateComponentJSON() of the ESPDash Class and modify

  if(!change_only){
    doc["name"] = card->_name;
    doc["type"] = cardTags[card->_type].type;
    doc["value_min"] = card->_value_min;
    doc["value_max"] = card->_value_max;
  }

to add    doc["card_index"] = card->_card_index;within the if()

(you have this method twice, once for cards, once for charts)

If I'm right, that's the "easy part", you'll now have the right card_index attribute in the JSON list that is sent to the browser.

Then the magic of the layout happens in the huge gzipped painful to read javascript that is sent to the client. You'll have to unzip the code (as discussed in the other thread), find the needle in the haystack of which functions are in charge of the layout (probably reading the JSON) and modify that JS function to read according to the card_index attribute, then gzip the file again, dump its ascii value representation and put that back into the const uint8_t DASH_HTML[] PROGMEM array

that's probably how I'd go about it...

This topic was automatically closed 120 days after the last reply. New replies are no longer allowed.