Widgets: Voltage Graph: Date locked on Dec 31 6:00PM to Dec 31 6:00PM

Board: Wemos D1 Mini (ESP8266)
Dashboard: Web
Bug / issue description:

I am reporting a digital sensor as voltage so that I can see activity over time graphed. I am sending status changes with:

Cayenne.virtualWrite(2,digitalRead(4),"voltage", "v"); 

Cayenne shows the voltage in live mode, but shows no data available for all but live graph modes: Legend shows for all but live: Start Date: Dec 31 6:00PM End Date: Dec 31 6:00PM

Hi @MBfromOK, welcome to the cayenne community. can you provide more details on your bug as i cannot reproduce the same at my end.

View here: - Cayenne

Steps to reproduce:
Setup a new graph widget on the relay status channel(2)
Send data to Cayenne using:


Cayenne.virtualWrite(2,digitalRead(4),"voltage", "v");  

This should show a spike up when the “voltage” is on, and drop when the “voltage” is off. Since it is a graph you see a square wave over time. Instead I get this:

unless you view live data: (not much to see, I just tested briefly 12+ hours ago)

can you check the setting of the line chart widget if the channel is set properly?

Before I realized the issue I switched it the widget and code to use channel 6 last night, but the relay in question is live both irl and on dashboard (Humidifier Control & Graph are the same relay different reporting channels)

Looking at the live graph the on / ‘1’ digital state graphs right below 1.5 and is updating, device has been up for 32000+ms so there should be data available for minute, hour and day options.

Note the blue line in live mode (as well the time updates every several seconds when data is received)

for digital actuator like relay, the line chart wont show history data.

Note the code is telling the API that it is voltage, not digital actuator, so as far as the graph is concerned it is getting voltage every 15 secs.

first of all are you sending any data to the channel 6

Yes, please see the second screenshot where there is a blue line right below 1.5 and the legend below ranges from Feb 1 @ 12:11PM to Feb 1 @ 12:11PM

3rd screen shot where I manually triggered the relay and screen captured:

Manual trigger again with minute selected:

i am editing your device right now. i am testing something.

can you check now?

Same behavior as 3rd and 4th screenshot

Please note that the graph in screenshot 3 has live selected
The same graph in screenshot 4 has minute selected.

did you refreshed your browser?

Yes, are you looking at the project or the device?

Actually, I am seeing a different bug… While talking to you and trying to show what I was seeing I added an additional graph to the Project connected to the same channel with the same settings…(I was planning on having one “live” and one historical for screen capturing)… The one called channel 6 wouldn’t show historical (time based) graph, the one called Relay Status - Live was showing everything.

I just removed the Channel 6 Graph, recreated the Live graph as historical and now both of the new graphs are working as expected.

To confuse / clarify things: If you switch to viewing these widgets / channels from the device: Relay Status - Live (just a name, no settings changes) won’t show historical data if you pick anything other than live

please do not change anything, let’s handle one bug at a time.
i have made changes to your device and now the data is shown in history.
I guess the procedure you are using is adding a line chart widget from the dashboard. that is not the correct way to do it.
the correct way is: when you publish data from your device with the correct data type, a green temporary widget will be created. you need to add it by clicking on + on the top right of the widget.
next, go to setting of this widget and change the widget type to value.
in your case where you want to view two line chart, use two different channel which will create two different widgets.
i hope you understand your mistake.

Ok, I will stand by while you evaluate and test my last post :slight_smile: my appologies!

i want you to make the changes now.
first, delete both the line chart widget. add another line of code which publishes data to another channel and follow this: