User manual

setTime(xhour, xminute, xsecond, xday, xmonth, xyear);
sendCom("AT+CIPCLOSE", "OK");
return true;
}
else return false;
}
else return false;
}
Parameters for the host address and the subaddress are submitted to this func-
tion. The Get-Request query is created from this and submitted to the TCP server
of the website after a connection is established. The server response now needs
to be analysed. For this, the entire request header part is skipped by scanning for
\r\n\r\n, which simply means continuing after a double Carriage Return and New
Line. The next numbers correspond to the date and time you are looking for, which
are saved in interim variables with a number of parseInt()-function calls. One spe-
cial feature is the date, where individual values are separated by a dash. The par-
seInt()-function interprets this as a negative number. Therefore, the values are
simply multiplied by -1. Last, the time is set with the setTime()-function and output
once per second by the loop-routine. The clock is now fully functional.
3.3 | Temperature display
This project displays the current temperature and the general weather. Again, the
values are output via the serial monitor. Additionally, there is an intuitive output
with the RGB-LED. With a single look, you can
guess at whether it is sensible to take along a
warm jacket.
For this setup, it is important to connect the RGB-LED correctly. RGB means Red,
Green, Blue; the LED actually is made up of several LEDs with a shared cathode
connection. A combination of the different colours with different brightnesses per-
Required parts
1 x pinboard, 1 x NanoESP, 1 x RGB-LED, 3 x resistor
1 kOhm (brown-black-red), circuit wire