How can I add multiple data from arduino to one field on Thingspeak?

33 views (last 30 days)
I have two seperate temperature sensors connected to arduino and I would like for them to read data on the same field in Thingspeak. For example, have one graph showing two lines on it in different colors, each representing one of the temperature sensor data. Is this possible? If so, how can it be done?
Thank you

Answers (2)

Christopher Stapels
Christopher Stapels on 2 Mar 2020
Have a look at this tutorial: Compare Temperature Data from Three Different Days. It describes one of the template codes availalbe in the MATLAB visualizations app.
  1 Comment
AL-HASAN MANSURI
AL-HASAN MANSURI on 4 Feb 2023
This tutorial says how to compare data of three different days of same sensor. What I want is, How to plot multiple sensor data in the one field chart ?
I have six temperature and humidity sensor, at different location but I want the temp of all sensor on one field chart & humi of all on the other field chart.

Sign in to comment.


Christopher Stapels
Christopher Stapels on 4 Feb 2023
Edited: Christopher Stapels on 4 Feb 2023
Field plots are the automatic plots that show unmoderated field data. You cannot do multiple series on a field plot. You can add MATLAB Visualizations to your channel to show multiple series in a single plot using the MATLAB visualizations app.
If you select new in MATLAB visualizations app, there is a code template for plotting two series.
MATLAB documentation will help you plot multiple series on the same plot. See this mafe on multiple plots. Basically, you use the hold on command to keep the previous plot.
Here is the basic plan.
  1. Read each sensor data into variables in your code (MATLAB variables are automatically arrays btw).
  2. Plot the first data set.
  3. use
hold on
4. plot all the rest.
5. enjoy.
  4 Comments
Christopher Stapels
Christopher Stapels on 6 Feb 2023
Field plots are the automatic plots that show unmoderated field data. You cannot do multiple series on a field plot. You can add MATLAB Visualizations to your channel to show multiple series in a single plot using the MATLAB visualizations app. See the instructions in my answer above.

Sign in to comment.

Communities

More Answers in the  ThingSpeak Community

Products

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!