[SOLVED] Widget graph

Continuing the discussion from Widget Graph in ESP8266 project:
My graph data has suddenly dissapeared from all granularities. Are there problems on the Blynk side here as I cannot think of anything I have done recently that would erase my data

Just checked again and all seems well. My graph data has returned. Not sure what the problem was there but will keep a close watch over the next few hours :confused:

I believe it’s a known issue and will be fixed in the next release. I have seen and reported this as well.

Serge

We don’t have issues with graph data. @ssozonoff could you please clarify what do you mean?

Hi,

I experienced an “issue” like this in the past. My graphs were not updated or losing info.
As I discovered some weeks ago, this was due to the fact that I was missing something on my firmware, which is noted in the docs of the history graphs here.. In short:
“In order to see data in history graph you need to use either widgets with “Frequency reading” interval (in that case your app should be open and running) or you can use Blynk.virtualWrite on hardware side. Every Blynk.virtualWrite command is stored on server automatically. In that case you don’t need application to be up and running.

Maybe and just maybe your firmware is not doing a blynk.virtualWrite periodically?
Otherwise, this would that when your app is not ON in your phone, there are no updates on the values of the graph, leading you to believe that the graph is not working properly, like it happened to me. (and maybe you, since you opened the app and later reported that everything looks ok now?).

Concrete example: I call the below updateBlynkCloud() from the loop of my firmware at every minute to update the blynk cloud even when my blynk app is not running in my phone.

/*******************************************************************************
 * Function Name  : updateBlynkCloud
 * Description    : publish readings to the blynk server every minute so the
                    History Graph gets updated even when
                    the blynk app is not on (running) in the users phone
 * Return         : none
 *******************************************************************************/
    void updateBlynkCloud() {

  //is it time to store in the blynk cloud? if so, do it
  if ( (USE_BLYNK == "yes") and (blynkStoreInterval > BLYNK_STORE_INTERVAL) ) {

    //reset timer
    blynkStoreInterval = 0;

    //publish every sensor reading to the blynk cloud
    Blynk.virtualWrite(BLYNK_DISPLAY_SENSOR0, sensorReading[0]);
    Blynk.virtualWrite(BLYNK_DISPLAY_SENSOR1, sensorReading[1]);
    Blynk.virtualWrite(BLYNK_DISPLAY_SENSOR2, sensorReading[2]);
    Blynk.virtualWrite(BLYNK_DISPLAY_SENSOR3, sensorReading[3]);

  }

}

@Dmitriy, maybe this can be clarified in some way or made even more explicit? Since this leads to users thinking the blynk app or the history graph widget does not work properly. :slight_smile:

Sorry thought I had posted my findings in my thread regarding this issue