0

I wish to obtain unix epoch timestamps in millisecond precision. I am using an ESP32 along with DS3231 RTC breakout board from adafruit.

Apparently the Repository is not maintained often but I see a PR which overcomes the rollover for software timer and the developer provided a patch in the comment to use the unix timestamps in ms.

I went to the libraries folder where all the downloaded adafruit repos exist. But when I did git status it mentions that the library download (from the library manager) is not a git repository.

I wan't to inculcate the changes to the RTClib library by using the patch provided. Should I just change the code directly via the Arduino IDE editor?

asked Sep 28, 2018 at 11:32

1 Answer 1

1

Save the patch to a file, put it in the directory holding the library, open a terminal on that directory and type:

patch -p1 < patchfile

You may have to install the "patch" utility if you don't have it yet. On a Debian-like OS (I don't know for other OSes):

sudo apt install patch
answered Sep 28, 2018 at 12:01
1
  • Well I blundered and cloned a fork from your repo and added the patch to it. Added this updated repo to the IDE. I think I will revert back to your method. Commented Sep 28, 2018 at 12:57

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.