question about the oscillators

whateverever
Posts: 8
Joined: Wed May 03, 2017 7:21 pm

question about the oscillators

Postby whateverever » Mon May 22, 2017 8:25 am

In the esp32 datasheet (https://espressif.com/sites/default/fil ... eet_en.pdf) are 4 oscillators:
Internal 8 MHz oscillator with calibration
Internal RC oscillator with calibration
External 2 MHz to 40 MHz crystal oscillator
External 32 kHz crystal oscillator for RTC with calibration

But in the datasheet of the esp32 wroom (https://www.espressif.com/sites/default ... eet_en.pdf) there are only 3 oscillators: The Internal 8 MHz oscillator with calibration is missing there (page 7-8).

Also in the esp32 wroom datasheet there is the following text
"The frequencies of the main crystal oscillator supported include 40 MHz, 26 MHz and 24 MHz"
But in the esp32 datasheet there is "External 2 MHz to 40 MHz crystal oscillator".

I'm a little confused now.

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

Re: question about the oscillators

Postby ESP_igrr » Mon May 22, 2017 9:15 am

Internal 8 MHz oscillator with calibration
Internal RC oscillator with calibration
External 32 kHz crystal oscillator for RTC with calibration
External 2 MHz to 40 MHz crystal oscillator
All of these are indeed supported by the ESP32. Note that while the chip can run from any crystal from 2MHz to 40MHz, we only support some values when it comes enabling PLLs. PLLs must be used to produce 80MHz clock required for WiFi/BT to work properly.

The values supported in the SDK now include 26MHz and 40MHz. 24 MHz support is possible but hasn't been included yet.

whateverever
Posts: 8
Joined: Wed May 03, 2017 7:21 pm

Re: question about the oscillators

Postby whateverever » Mon May 22, 2017 7:04 pm

So the internal 8 MHz oscillator with calibration is supported.

.. and also included in the esp 32 wroom?

WiFive
Posts: 3529
Joined: Tue Dec 01, 2015 7:35 am

Re: question about the oscillators

Postby WiFive » Mon May 22, 2017 7:25 pm

I'm not sure how you would remove an internal oscillator ;)

whateverever
Posts: 8
Joined: Wed May 03, 2017 7:21 pm

Re: question about the oscillators

Postby whateverever » Mon May 22, 2017 7:27 pm

Touché. That was stupid question.

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

Re: question about the oscillators

Postby ESP_igrr » Tue May 23, 2017 2:50 am

8MHz is used by default as RTC_FAST_CLK.

dipankarpanda
Posts: 4
Joined: Thu Nov 23, 2017 12:33 pm

Re: question about the oscillators

Postby dipankarpanda » Thu Nov 23, 2017 3:34 pm

Guys, Can you please let me know the accuracy of the external crystal as well as internal RC oscillator used in dev board. For my application I need to make a fine tune timer interrupt. Where timer ISR should Run in every 0.0039064 sec or 3.9064 mili sec.

I have tried to achieve this but I couldn't get that much accurate value. I have tried with 1.25 / 2.5 / 5 / 10 / 20 / 40 MHz frequency but couldn't get the exact value. Even I observed that at high frequency the error is increased instead of decreasing. The result was like this -

at 5 MHz -- error value 1.4 micro Sec
at 10 MHz --- error value 1.8 micro sec
at 20 MHz --- error value 1.95 micro sec
at 40 MHz --- error value 1.97 micro sec All are for the same piece of code.

So, can you please let me know whether 0.0039064 sec accurately can be measured by ESP32 timer?

Thanks
Dipankar

ESP_Sprite
Posts: 9757
Joined: Thu Nov 26, 2015 4:08 am

Re: question about the oscillators

Postby ESP_Sprite » Fri Nov 24, 2017 8:30 am

How do you measure this? Sounds like you're not accounting for the overhead of the ISR being called.

dipankarpanda
Posts: 4
Joined: Thu Nov 23, 2017 12:33 pm

Re: question about the oscillators

Postby dipankarpanda » Mon Dec 11, 2017 11:50 am

i measured using a simple oscilloscope....

chevymn1964
Posts: 1
Joined: Thu Feb 15, 2024 6:35 pm

Re: question about the oscillators

Postby chevymn1964 » Thu Feb 15, 2024 7:09 pm

Hi all!
I would like to use a 40MHz external oscillator instead of a crystal, what pin would osc. connect to?

Who is online

Users browsing this forum: Baidu [Spider], Google [Bot] and 396 guests