Commit Graph

8 Commits

Author SHA1 Message Date
me-no-dev
c8140f8288 add configTime, getLocalTime and support for time in Print
example:
```cpp
//done once on WiFi init
configTime(-7200, 3600, "pool.ntp.org");
//get local time
struct tm timeinfo;
if(!getLocalTime(&timeinfo)){
    Serial.println("Failed to obtain time");
    return;
}
//print time
Serial.println(&timeinfo);
//print time with different format
Serial.println(&timeinfo, "%A, %B %d %Y %H:%M:%S");
```
fixes: https://github.com/espressif/arduino-esp32/issues/29
2017-01-24 04:07:27 +02:00
me-no-dev
5d61d8ddd0 copy va_list in Print::printf 2016-10-11 11:42:47 +03:00
me-no-dev
e7d2c18742 Do not delete printf buffer if not required 2016-10-10 19:29:25 +03:00
me-no-dev
01961ef5c6 use local buffer for printf if size is equal or less than 64 2016-10-10 17:37:34 +03:00
me-no-dev
063b563079 Print::printf should allocate it's buffer 2016-10-08 00:18:12 +03:00
me-no-dev
bb9ded7ed4 comment out __FlashStringHelper methods in Print 2016-10-07 23:59:24 +03:00
me-no-dev
03f5d62323 Wiring.h -> Arduino.h 2016-10-06 07:09:45 -06:00
me-no-dev
5f3a205955 initial import 2016-10-06 07:09:44 -06:00