Questions tagged [arduinojson]
46 questions
0
votes
2 answers
Json parsing not working with JsonObject using ArduinoJson library
I am using the following code to store Config.json file to ESP32 flash memory using SPIFFS
#include
#include
#include
bool loadConfig() {
File configFile = SPIFFS.open("/Config.json", "r");
if (!configFile)…

Srujan Patel
- 3
- 3
0
votes
3 answers
Json serializing in C++ (ESP32)
I'm writing some script for ESP32 and struggling to serialize a json.
Used libraries are HTTPClient and ArduinoJson.
String payload = http.getString();
Serial.println(payload);
deserializeJson(result, payload);
const char* usuario =…

alosbh
- 25
- 5
0
votes
0 answers
Deserialize String into StaticJsonDocument
I'm using ArduinoJson, HTTPClient Libraries for my HTTP related communications in ESP8266. I have used a POST method API which returns me a String (but it's a json).
void configure() {
String jsonBody;
const String dataFetchUrl =…

Aravinda Rathnayake
- 61
- 1
- 7
0
votes
0 answers
Setting variables from json into a struct have weird results
I have something in my code output I don't understand.
My guess is the issue is due to [me of course] ... the usage of both "struct"+"arduinoJson" to store configuration values.
I have made this simple code that only connect to Wifi;
either using…

Paul Ernond
- 47
- 6
0
votes
0 answers
How to setup proper POST body using arduino json
I'm trying my hands on arduino. Doing a POST request with some data to a server. But i'm not able to do a proper formatting of that data. I'm using arduinojson for it but i'm not sure whether i'm doing it correctly or not.
#include…

Ahmad hamza
- 1,816
- 1
- 23
- 46
0
votes
1 answer
How to read json file from ESP8266's SPIFFS with ArduinoJSON 6?
I am currently working on a project with ESP8266 (ESP-12E) and I need to store information in a json file (more convenient to access via the web interface and easier to manage than EEPROM for me).
My problem is the following: I'm using the latest…

Vincent
- 1
- 1
- 2
0
votes
1 answer
ArduinoJSON serialization returns an empty string when serializing to char*
I made a function that serializes settings and returns a char* containing serialized data.
First i'm packing all the values into a StaticJsonDocument, then determining size of the output string using measureJson, then allocating space for the output…

EntityinArray
- 109
- 12
0
votes
1 answer
ESP8266 cannot publishing longer data over mqtt topic
I am using esp8266 and Arduino IDE for programming.when I am trying to publish JSON data over MQTT topic from esp8266 over a wifi network, it is working for the below code.
void reportToServer(){
String payload =…

ameya
- 201
- 2
- 16
0
votes
1 answer
Can't get data from Googlesheet using esp32 and Arduinojson
I'm new to esp32 and now I'm trying to Get data using ArduinoJson,
In my googlesheet "A1" have a number and I want to let esp32 to get it,
I send my googlesheet to internet and use the…

NekoshimaTama
- 11
- 5
0
votes
0 answers
ArduinoHttpClient will not post json
For a school projecht we want to read data from the data pins and send them to a php aplication. We get the data and can make a json string from it, but when we try to send the data (multidimensional) the $_POST var is empty of the php script (it…

user3142817
- 787
- 2
- 9
- 15
0
votes
2 answers
How to Create Nested Json Using ArduinoJson on ESP8266
I want this Output Json From Esp8266
I am trying with another json lib https://github.com/arduino-libraries/Arduino_JSON
this is lightweight library than arduinojson.org
{
"ID": "0785E7",
"DEVICE": "SINGLE_RELAY",
"Public_Name": "Demo…

Mukesh mishra
- 41
- 1
- 8
0
votes
1 answer
Make ArduinoJSON Array globally available
I am wrapping my head around this problem quite a long time now.
I am opening a websocket Connection from my ESP32 to my NodeJS Backend. When receiving a message, the content gets parsed with ArduinoJSON.
I store the parsed content in global…

Cornelius
- 306
- 4
- 14
0
votes
1 answer
Arduino POST request using JSON
I am trying to get my Arduino (with an Ethernet shield) to send a POST request with a JSON body to my locally hosted server.
I am using the ArduinoJson (version 6) and Ethernet libraries.
I am attempting to send a POST request to a local endpoint…

Wendell
- 1
- 1
- 2
0
votes
1 answer
NodeMCU JSON POST data issue
I am using the below code for sending POST json requests.
I am receiving the request, but the body parameter is coming as null. ("body": null)
// Example of the different modes of the X.509 validation options
// in the WiFiClientBearSSL object
//
//…

Biranchi
- 16,120
- 23
- 124
- 161
-1
votes
2 answers
How can I Send data directly over to MongoDB without any intermediary?
I wanted to update/push data directly over to the MongoDB using an ESP8266 Wi-Fi module in Arduino. I have seen some solutions referring to use MQTT / their own Node-Red Server to connect with MongoDB and then send connect the data. But I want to do…

Prashant Mishra
- 1
- 1
- 1