Line Graph - no data available

I am trying to use a line chart in the custom widgets. I can send data via MQTT.fx to gauge widgets just fine but when I try to send data to a line graph I keep seeing “no data available for this period”. I am using the same topic string as when I send data to a standard widget and I can get widgets to automatically pop up with my data but I get nothing with the line graph.

The topic string: v1/“MQTT Username”/things/“Client ID”/data/1
Of course the MQTT Username & Client ID are those provided in my device information screen.

The data I am publishing is: flow,m=22.3

Also I do not get the live selection for the time frame. The graph is set up to pick up data from channel 1, the time frame is for today

I think we have a bug with showing the history of data for MQTT devices. Will update you when we can push a fix. Sorry about this! Hang in there.

-Benny

I would really like to use this in my IoT class this summer (ESP8266 via MQTT in BYOD mode). Occasionally, if I destroy the device and make a new one, the graph will show up for about 5 minutes and then fail to update, if I refresh the desktop, it returns to the “no data available” thing. So, intermittently it works (as of today around 5:00 PST) . . . but then it fails again. : (

Just to follow up, it looks as if after a few hours, the graphs begin working again. Maybe there is a caveat that you need N data points before anything really ‘happens’. I do need to update the page manually (no refresh dashboard, but reload the entire page in the browser (Firefox) to affect a change of the graphs (that is, the graphs don’t auto-update, when looking at the last hour, you see the last hour since you loaded the page – if a few hours have past, the graph does not shift to the right to display the next hour(s))

It’s getting better . . .

JG

2 Likes

What IoT class are you running this summer? We have receive a lot of interest in using Cayenne in the classroom to teaching IoT concepts, so interested to hear your plans. Perhaps we can provide some support for your class as well. :slight_smile:

-B

@bestes

sorry for the late reply. I am teaching a 2 month intro to IOT using the esp8266 and arduino IDE at the University of Washington in the their Human Centered Design and Engineering program. Our midterm project is to deploy 20-30 sensors across campus to monitor environmental factors . . . class commences in June.

We would like to visualize and sonify the data in real-time. Is there anyway to tap into the fees (websockets ?) to pull the data back out in real-time. It would be nice to do more advanced multi-modal representations of RT data with Processing/Max/supercollider/etc.

JG

I have a arduino project whit a Virtual pin.

I had succes in the beginning but now the graph give’s an error; No data available for this period

i have tried to remove the graph and reinstall is but still the same error.

the starnge thing is that i can read a gauge and thatt works fine but data log is not working…

Can you reset the graph or do something so it works!!

here is the sketch;

define CAYENNE_PRINT Serial // Comment this out to disable prints and save space
include
char token = “xxxxxxxxxxxx”;// removed it for not make it puplick

float vout = 0.0;
float vin = 0.0;
int value = 0;

const int sensorPin= A0;

void setup()
{
Serial.begin(9600);
Cayenne.begin(token);
pinMode(sensorPin, INPUT);
analogReference(DEFAULT);// calibrate analoge input
}

void loop(){
Cayenne.run();

value = analogRead(sensorPin);
vout = (value * 5.0) / 1024.0;
vin = (vout * 4.927309); /// calibreren volt sensor
Cayenne.virtualWrite(V10, vin);

Serial.println(vin);
Serial.println(“test if the sensor is running”);

delay (1000);

}

Sometimes it can take quite a while until the graphs populates data. Is it still blank?

Hi Adam,
Is this problem fixed yet? I am having the same issue.

I have tried both your raw MQTT method:

and also the Node-Red node-red-contrib-cayenne-mqtt-client.

The data appears in the Value Widget but not in the Chart Widget. I am using unique channel numbers.
I am going to leave it running for the day to see if it requires time to collect data points.
Any other ideas?

Hi JG,
Finally after many hours of removing and adding and refreshing dashboard over and over with trends, the answer is as you have said above.
I could always get the value to show up in the Value or Gauge Widget but would error with no data on the Line Chart, logging in and out and Resetting Dashboard had no effect most of the time.

Use F5 to do a browser refresh and the trending works instantly
I am in Love with Cayenne again :wink:
Using Arduino Huzzah ESP8266 and CayenneMQTTESP8266 Library to upload values received on the serial port.
works a treat.
Jason