RTC with 32.768 kHz crystal

User avatar
loboris
Posts: 514
Joined: Wed Dec 21, 2016 7:40 pm

RTC with 32.768 kHz crystal

Postby loboris » Mon Feb 13, 2017 8:12 pm

Is there any way to configure RTC to run with 32.768 crystal?
This can be very important, as the current implementation of RTC in deep sleep with internal 150 kHz clock is very inaccurate.
On my board (does it depend on board/module ?) RTC runs approximately 3,2% to fast when in deep sleep.
I've tried a kind of callibration (increasing the sleep time by 3.2%, and then adjusting the system time after wake up) and it is much better, but certainly not enough for running for long periods of time.
As I have 32.768 kHz on board, I would like to use it.

ESP_igrr
Posts: 2071
Joined: Tue Dec 01, 2015 8:37 am

Re: RTC with 32.768 kHz crystal

Postby ESP_igrr » Mon Feb 13, 2017 8:28 pm

In the current ESP-IDF, using RTC as clock source isn't supported unfortunately. Expect to see support for this by the end of February.

User avatar
loboris
Posts: 514
Joined: Wed Dec 21, 2016 7:40 pm

Re: RTC with 32.768 kHz crystal

Postby loboris » Sun Mar 19, 2017 11:12 pm

ESP_igrr wrote:In the current ESP-IDF, using RTC as clock source isn't supported unfortunately. Expect to see support for this by the end of February.
Any news about RTC as clock source support ?

User avatar
loboris
Posts: 514
Joined: Wed Dec 21, 2016 7:40 pm

Re: RTC with 32.768 kHz crystal

Postby loboris » Tue Mar 28, 2017 7:15 am

Is this issue considered so unimportant or is it so complicated to implement the support?

ESP_igrr
Posts: 2071
Joined: Tue Dec 01, 2015 8:37 am

Re: RTC with 32.768 kHz crystal

Postby ESP_igrr » Tue Mar 28, 2017 8:03 am

This feature is planned, sorry that it's taking longer than expected.

eric24
Posts: 1
Joined: Thu May 04, 2017 7:49 pm

Re: RTC with 32.768 kHz crystal

Postby eric24 » Thu May 04, 2017 7:52 pm

Once the 32KHz issues have been worked out, will the ESP32 also support a 32.768KHz square wave input on a single pin (instead of a crystal on two pins)? The reason I ask is because this would provide the option of using an external temperature-compensated oscillator for better frequency stability that a crystal alone can offer.

don.vukovic
Posts: 31
Joined: Tue Mar 21, 2017 3:40 am

Re: RTC with 32.768 kHz crystal

Postby don.vukovic » Mon Aug 07, 2017 12:20 am

Has this issue been resolved ?
Any examples available ?

ESP_igrr
Posts: 2071
Joined: Tue Dec 01, 2015 8:37 am

Re: RTC with 32.768 kHz crystal

Postby ESP_igrr » Tue Aug 08, 2017 2:50 pm

Yes, you can enable 32k XTAL in menuconfig, under ESP 32 specific settings.

onehorse
Posts: 70
Joined: Mon Feb 15, 2016 1:35 am

Re: RTC with 32.768 kHz crystal

Postby onehorse » Wed Aug 09, 2017 2:58 am

Any plans to extend this to the Arduino core? My boards also have a 32.768 kHz crystal and I would like to be able to make us of it in my Arduino sketches.

anteph
Posts: 16
Joined: Mon May 08, 2017 2:12 pm

Re: RTC with 32.768 kHz crystal

Postby anteph » Sat Nov 18, 2017 7:21 pm

Hi!

I'm also looking for RTC support on the Arduino core.
It would be awesome to avoid the need for using an external RTC for timestamping, which is a need for most of all sensor related projects.

Best regards,
Nuno Santos

Who is online

Users browsing this forum: No registered users and 103 guests