Data not Shown in Thingspeak

I am using Arduino Nano and NodeMCU fro my IoT Air Analyzer Project using MQ Sensors. What I want to do is to display my gas readings on the LCD and have it displayed in my Thingspeak channel. While I have no problems with having my readings shown in LCD, the problem is that my data is not getting uploaded to the Thingspeak channel. I have two codes: One for Arduino Nano and One for NodeMCU. I am using ArduinoJson version 5.13.5 and SoftwareSerial library as well.

Arduino Nano.ino (4.4 KB)
NodeMCU.ino (2.2 KB)

there are lots of ideas on the things website.

I looked at your nodemcu program. I don't see the part that connects http.

I use

int LogToThingSpeak(int FieldToSend, int CodeToSend) {
int callOut;
WiFiClient client;
ThingSpeak.begin(client);
if (FieldToSend < 9) {
callOut = ThingSpeak.writeField(Chan1, FieldToSend, CodeToSend, WrtKey1);
}
else {
FieldToSend -= 8;
callOut = ThingSpeak.writeField(Chan2, FieldToSend, CodeToSend, WrtKey2);
}
if(callOut==200){
WriteTScntr++;}
else {
ErrorTScntr++;}
return callOut;
}

Hi and thank you for responding! So i have to form my own code based on this in order for my nodemcu to connect to https?

start with the Thingspeak examples in the Arduino IDE for the ESP8266 ("WriteSingleFieldSecure" or "WriteMultipleFieldsSecure")

GitHub has lots of examples too

Thingspeak examples in the Arduino IDE are the same as the examples in Thingspeak's Github page

I suppose, but perhaps he might find others more suited to his project.

Maybe, but since the OP can't even do the very simplest thing yet, their first step should be to get a Thingspeak example in the Arduino IDE working

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