Closed WL-Richards closed 1 month ago
So I updated how JSON data is being handled. Now whenever the JSON document is need, deserializeJson is called with the doc and jsonStr variable. Likewise, whenever changes have been made to the doc obj, serializeJson is called with the doc and jsonStr variable. So jsonStr is the json data stored as a cstring and is used for mediating changes to the document. Changes are on this branch --> https://github.com/OPEnSLab-OSU/Loom-V4/tree/json-overhaul
@WL-Richards , can we merge this with the Wisp, Chimes branch we're currently using - and plan to have @ZakaryW , @SorenEmmons and @Sarvesh-Thiruppathi test this the DAY it MERGES, to confirm if something is broken or if it works? Let's see some coordination
Closing this as its done, and has been sidelined
We currently use a global instance of a DynamicJsonDocument in the Manager to hold our JSON data, which works fine. However, according to the ArduinoJson spec. This is not how we are supposed to do this. We should be storing JSON documents as c-strings and then when we wish to change some value of the document we create a temp. document to read the string in make the change and then write the data back to a "global" string held by the manager.