• Hardware model - ESP 8266
• Communication type - Wifi
• Iphone SE (IOS)
• Blynk server
• Blynk Library version 0.5.0
...
// Temporary variables
static char celsiusTemp[7];
static char humidityTemp[7];
...
void sendSensor()
{
float h = dht.readHumidity();
float t = dht.readTemperature();
// Computes temperature values in Celsius and Humidity
float hic = dht.computeHeatIndex(t, h, false);
dtostrf(hic, 6, 2, celsiusTemp);
dtostrf(h, 6, 2, humidityTemp);
if (isnan(h) || isnan(t)) {
Serial.println("Failed to read from DHT sensor!");
return;
}
Blynk.virtualWrite(V2, humidityTemp);
Blynk.virtualWrite(V1, celsiusTemp);
blinkLedWidget();
}
...
Good morning!
Can you tell me what I’m doing wrong?
In IOS when I add V1 and V2 to History Chart, it write “no data”!
But in “value display” temperature and humidity is available correct (27.34 etc.)
Assuming you meen SuperChart, not its predecessor History Graph (or possibly both… can’t remember the old one now )… depending on the scale you are looking at, it will take some time to populate the data stream.
Hello. Try to print values to serial output and check the values, most probably you send not floats. Also history graph has 1 minute delay, maybe this is the issue.
Sounds like you are running some older versions of App… You need to keep them current to a point. Be aware that the History Graph has been “replaced” with the Super Chart in newer App versions.
@Piroteh please post the serial output from your hardware. I’ll repeat - from what I see you probably send not floats but strings. Please check you haven’t ‘space’ char in data you send.
Try to print
char humidityTemp[7]
to serial output. I bet it has space in it. Also, you don’t need to send strings. You may send floats directly.