3 programs are available for this board. The first one sets date and time which is hard-coded in the program. You must therefore modify the code if you want to set the correct date and time:
https://github.com/uraich/MicroPython_IoTDemos/blob/master/drivers/ds1307/ds1307SetTime.py
The second program is an improvement over the first one. It also sets date and time of the RTC but this time it gets the correct date and time from an NTP time server. Just running the program without any modification will therefor set the correct time.
https://github.com/uraich/MicroPython_IoTDemos/blob/master/drivers/ds1307/ds1307SetTimeNtp.py
The third program reads the date and time from the RTC and prints it in a humanly readable format:
https://github.com/uraich/MicroPython_IoTDemos/blob/master/drivers/ds1307/ds1307GetTime.py
-- %USERSIG{UliRaich - 2019-03-22}%
| I | Attachment | Action | Size | Date | Who | Comment |
|---|---|---|---|---|---|---|
| |
wemosDS1307.png | manage | 76 K | 22 Mar 2019 - 14:10 | UnknownUser |