I have successfully modified the arduino WiFiUdpNtpClient example to get ntp time and and setup a D3221 rtc. Not a lot needs to be done to the example. I use Adafruit’s RTCLib to manage the RTC. The nice thing about this library is its collection of time manipulation functions. Time is syncd on boot and every 12 hours.