hi, sorry for the long delay!
here is the basic code:
“Master” - where the readings are USED decide when to open/close relays:
double TempNode02, DewPointNode02; //from Node02
BLYNK_WRITE(V26)
{
TempNode02 = param.asDouble(); // gets reading from Node02 which is a separate ESP8266 device - it is the LIVING ROOM DHT22 sensor
}
BLYNK_WRITE(V7)
{
DewPointNode02 = param.asDouble(); // gets reading from Node02 which is a separate ESP8266 device - it is the LIVING ROOM DHT22 sensor
}
void setup() {
// put your setup code here, to run once:
}
void loop() {
// put your main code here, to run repeatedly:
}
the “Node” code where the sensor is operated, and ‘sends’ readings to the “Master”:
float TempNode02, DewPointNode02;
BLYNK_READ(V26)
{
Blynk.virtualWrite(26, TempNode02);
}
BLYNK_READ(V7)
{
Blynk.virtualWrite(7, DewPointNode02);
}
void runDHT22()
{
int chk;
chk = DHT.read22(LIVING_DHT22_PIN);
HumNode02 = DHT.humidity;
TempNode02 = DHT.temperature;
DewPointNode02 = dewPoint(DHT.temperature, DHT.humidity);
Blynk.virtualWrite(V26, TempNode02);
Blynk.virtualWrite(V7, DewPointNode02);
}
void setup() {
// put your setup code here, to run once:
}
void loop() {
// put your main code here, to run repeatedly:
}
i don’t really know how having the variables as a float in one sketch but double in the other is affecting anything - certainly doesn’t seem to…