|
ESP DateTime
0.2.0
Date Time Functions and Classes for ESP8266 and ESP32
|
This library provides a simple class DateTimeClass for sync system timestamp vis ntp and a struct DateFormatter to format date time to string, works on ESP8266 and ESP32 platform.
Current Version: v0.2.0
This libarary is published to PlatformIO, PlatformIO IDE has built-in PIO Home: Library Manager, you can search ESPDateTime in Library Manager and click to install this library.
Or you can install using platformio cli:
And then, add dependency to your platformio.ini file:
I will publish this library to Arduino Library soon. (TODO)
Clone this repo or download source code at release page, then copy all files in src to your project source directory.
DateTime is a global DateTimeClass object for use in your code.
You can use DateTime to get current time and format time to string, format function internal using strftime function in <time.h>.
DateTime object.See examples folder in this project, to run example on your device, WiFi ssid and password must be set in source code.
See API Reference.
Copyright 2019 github@mcxiaoke.com
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.