Difference between internal and external oscillator for a microcontroller?
Clash Royale CLAN TAG#URR8PPP
up vote
1
down vote
favorite
I am a beginner with respect to microcontrollers, so I just want to ask is there two option for choosing the frequency of the microcontroller: to be internal or external?
If there is internal frequency available in the controller, then we don't need to use external crystal oscillator?
microcontroller oscillator frequency timer
New contributor
Varun Sahni is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
add a comment |Â
up vote
1
down vote
favorite
I am a beginner with respect to microcontrollers, so I just want to ask is there two option for choosing the frequency of the microcontroller: to be internal or external?
If there is internal frequency available in the controller, then we don't need to use external crystal oscillator?
microcontroller oscillator frequency timer
New contributor
Varun Sahni is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
add a comment |Â
up vote
1
down vote
favorite
up vote
1
down vote
favorite
I am a beginner with respect to microcontrollers, so I just want to ask is there two option for choosing the frequency of the microcontroller: to be internal or external?
If there is internal frequency available in the controller, then we don't need to use external crystal oscillator?
microcontroller oscillator frequency timer
New contributor
Varun Sahni is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
I am a beginner with respect to microcontrollers, so I just want to ask is there two option for choosing the frequency of the microcontroller: to be internal or external?
If there is internal frequency available in the controller, then we don't need to use external crystal oscillator?
microcontroller oscillator frequency timer
microcontroller oscillator frequency timer
New contributor
Varun Sahni is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
New contributor
Varun Sahni is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
edited 48 mins ago


Greenonline
6212722
6212722
New contributor
Varun Sahni is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
asked 3 hours ago


Varun Sahni
61
61
New contributor
Varun Sahni is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
New contributor
Varun Sahni is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
Varun Sahni is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
add a comment |Â
add a comment |Â
3 Answers
3
active
oldest
votes
up vote
2
down vote
Main difference is that the internal oscillator is usually a RC type oscillator which is not very accurate. External oscillators can be of type quartz crystal which are far more accurate.
add a comment |Â
up vote
2
down vote
It depends on what you want to use the processor for, the manufacturer, etc.
RC internal oscillators are "only" good for 1-2% accuracy, there are some processors that have tuning adjustment registers that allow you to shift the frequency, so with the right software/calibration, etc. you can get better results.
For (asynchronous) serial port type communications, the RC inaccuracy can become critical at high baud speeds (generally 230kbps and above, depending on processor and baud rate clock flexibility)
With RC oscillators you typically get 1 or 2 frequencies unless the MCU offers PLL capabilities in which case there can be a wide range. This can be used to advantage to dynamically scale the clock speed for battery powered situations where you can't go to 'sleep' due to complicated monitoring situations, but don't have to be running flat-out.
A crystal can get you any frequency you would want within the MCU operating limits, however you need to verify that the loading is correct so that the oscillator starts up correctly and is accurate and stable over time and temperature.
The RC internal oscillator is generally guaranteed to work by the manufacturer with no hardware design issues.
New contributor
isdi is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
1
Good answer, but I'm not sure about "RC inaccuracy can become critical at high baud speeds". Why would that be the case? Because of more limited divisor selection for baudrate, or am I missing something?
– domen
59 mins ago
add a comment |Â
up vote
0
down vote
Most practical differences I have encountered:
Frequency stability (especially across different temperatures). It depends on your application if you need a very stable clock or not. I had issues once using an ATmega8 running from the internal oscillator with an UART that lost sync below zero. For VGA a crystal is a must.
Power consumption - internal oscillators usually will be more power efficient than external crystals
Available frequencies. For example to get ideal 115200 baud UART timing on an ATmega8 you will need a clock with an "oddball" frequency of 7.3728 MHz, while the closest frequency the internal clock can only deliver 8 Mhz (so some bauds will not be available).
Depending on the exact MCU you can also get great clock stability if you use it as an USB device. The internal oscillator can lock on to the clock signal from the USB host (that is crystal-stabilized).
add a comment |Â
3 Answers
3
active
oldest
votes
3 Answers
3
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
2
down vote
Main difference is that the internal oscillator is usually a RC type oscillator which is not very accurate. External oscillators can be of type quartz crystal which are far more accurate.
add a comment |Â
up vote
2
down vote
Main difference is that the internal oscillator is usually a RC type oscillator which is not very accurate. External oscillators can be of type quartz crystal which are far more accurate.
add a comment |Â
up vote
2
down vote
up vote
2
down vote
Main difference is that the internal oscillator is usually a RC type oscillator which is not very accurate. External oscillators can be of type quartz crystal which are far more accurate.
Main difference is that the internal oscillator is usually a RC type oscillator which is not very accurate. External oscillators can be of type quartz crystal which are far more accurate.
answered 3 hours ago


Stefan Wyss
1,21512
1,21512
add a comment |Â
add a comment |Â
up vote
2
down vote
It depends on what you want to use the processor for, the manufacturer, etc.
RC internal oscillators are "only" good for 1-2% accuracy, there are some processors that have tuning adjustment registers that allow you to shift the frequency, so with the right software/calibration, etc. you can get better results.
For (asynchronous) serial port type communications, the RC inaccuracy can become critical at high baud speeds (generally 230kbps and above, depending on processor and baud rate clock flexibility)
With RC oscillators you typically get 1 or 2 frequencies unless the MCU offers PLL capabilities in which case there can be a wide range. This can be used to advantage to dynamically scale the clock speed for battery powered situations where you can't go to 'sleep' due to complicated monitoring situations, but don't have to be running flat-out.
A crystal can get you any frequency you would want within the MCU operating limits, however you need to verify that the loading is correct so that the oscillator starts up correctly and is accurate and stable over time and temperature.
The RC internal oscillator is generally guaranteed to work by the manufacturer with no hardware design issues.
New contributor
isdi is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
1
Good answer, but I'm not sure about "RC inaccuracy can become critical at high baud speeds". Why would that be the case? Because of more limited divisor selection for baudrate, or am I missing something?
– domen
59 mins ago
add a comment |Â
up vote
2
down vote
It depends on what you want to use the processor for, the manufacturer, etc.
RC internal oscillators are "only" good for 1-2% accuracy, there are some processors that have tuning adjustment registers that allow you to shift the frequency, so with the right software/calibration, etc. you can get better results.
For (asynchronous) serial port type communications, the RC inaccuracy can become critical at high baud speeds (generally 230kbps and above, depending on processor and baud rate clock flexibility)
With RC oscillators you typically get 1 or 2 frequencies unless the MCU offers PLL capabilities in which case there can be a wide range. This can be used to advantage to dynamically scale the clock speed for battery powered situations where you can't go to 'sleep' due to complicated monitoring situations, but don't have to be running flat-out.
A crystal can get you any frequency you would want within the MCU operating limits, however you need to verify that the loading is correct so that the oscillator starts up correctly and is accurate and stable over time and temperature.
The RC internal oscillator is generally guaranteed to work by the manufacturer with no hardware design issues.
New contributor
isdi is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
1
Good answer, but I'm not sure about "RC inaccuracy can become critical at high baud speeds". Why would that be the case? Because of more limited divisor selection for baudrate, or am I missing something?
– domen
59 mins ago
add a comment |Â
up vote
2
down vote
up vote
2
down vote
It depends on what you want to use the processor for, the manufacturer, etc.
RC internal oscillators are "only" good for 1-2% accuracy, there are some processors that have tuning adjustment registers that allow you to shift the frequency, so with the right software/calibration, etc. you can get better results.
For (asynchronous) serial port type communications, the RC inaccuracy can become critical at high baud speeds (generally 230kbps and above, depending on processor and baud rate clock flexibility)
With RC oscillators you typically get 1 or 2 frequencies unless the MCU offers PLL capabilities in which case there can be a wide range. This can be used to advantage to dynamically scale the clock speed for battery powered situations where you can't go to 'sleep' due to complicated monitoring situations, but don't have to be running flat-out.
A crystal can get you any frequency you would want within the MCU operating limits, however you need to verify that the loading is correct so that the oscillator starts up correctly and is accurate and stable over time and temperature.
The RC internal oscillator is generally guaranteed to work by the manufacturer with no hardware design issues.
New contributor
isdi is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
It depends on what you want to use the processor for, the manufacturer, etc.
RC internal oscillators are "only" good for 1-2% accuracy, there are some processors that have tuning adjustment registers that allow you to shift the frequency, so with the right software/calibration, etc. you can get better results.
For (asynchronous) serial port type communications, the RC inaccuracy can become critical at high baud speeds (generally 230kbps and above, depending on processor and baud rate clock flexibility)
With RC oscillators you typically get 1 or 2 frequencies unless the MCU offers PLL capabilities in which case there can be a wide range. This can be used to advantage to dynamically scale the clock speed for battery powered situations where you can't go to 'sleep' due to complicated monitoring situations, but don't have to be running flat-out.
A crystal can get you any frequency you would want within the MCU operating limits, however you need to verify that the loading is correct so that the oscillator starts up correctly and is accurate and stable over time and temperature.
The RC internal oscillator is generally guaranteed to work by the manufacturer with no hardware design issues.
New contributor
isdi is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
New contributor
isdi is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
answered 2 hours ago
isdi
513
513
New contributor
isdi is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
New contributor
isdi is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
isdi is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
1
Good answer, but I'm not sure about "RC inaccuracy can become critical at high baud speeds". Why would that be the case? Because of more limited divisor selection for baudrate, or am I missing something?
– domen
59 mins ago
add a comment |Â
1
Good answer, but I'm not sure about "RC inaccuracy can become critical at high baud speeds". Why would that be the case? Because of more limited divisor selection for baudrate, or am I missing something?
– domen
59 mins ago
1
1
Good answer, but I'm not sure about "RC inaccuracy can become critical at high baud speeds". Why would that be the case? Because of more limited divisor selection for baudrate, or am I missing something?
– domen
59 mins ago
Good answer, but I'm not sure about "RC inaccuracy can become critical at high baud speeds". Why would that be the case? Because of more limited divisor selection for baudrate, or am I missing something?
– domen
59 mins ago
add a comment |Â
up vote
0
down vote
Most practical differences I have encountered:
Frequency stability (especially across different temperatures). It depends on your application if you need a very stable clock or not. I had issues once using an ATmega8 running from the internal oscillator with an UART that lost sync below zero. For VGA a crystal is a must.
Power consumption - internal oscillators usually will be more power efficient than external crystals
Available frequencies. For example to get ideal 115200 baud UART timing on an ATmega8 you will need a clock with an "oddball" frequency of 7.3728 MHz, while the closest frequency the internal clock can only deliver 8 Mhz (so some bauds will not be available).
Depending on the exact MCU you can also get great clock stability if you use it as an USB device. The internal oscillator can lock on to the clock signal from the USB host (that is crystal-stabilized).
add a comment |Â
up vote
0
down vote
Most practical differences I have encountered:
Frequency stability (especially across different temperatures). It depends on your application if you need a very stable clock or not. I had issues once using an ATmega8 running from the internal oscillator with an UART that lost sync below zero. For VGA a crystal is a must.
Power consumption - internal oscillators usually will be more power efficient than external crystals
Available frequencies. For example to get ideal 115200 baud UART timing on an ATmega8 you will need a clock with an "oddball" frequency of 7.3728 MHz, while the closest frequency the internal clock can only deliver 8 Mhz (so some bauds will not be available).
Depending on the exact MCU you can also get great clock stability if you use it as an USB device. The internal oscillator can lock on to the clock signal from the USB host (that is crystal-stabilized).
add a comment |Â
up vote
0
down vote
up vote
0
down vote
Most practical differences I have encountered:
Frequency stability (especially across different temperatures). It depends on your application if you need a very stable clock or not. I had issues once using an ATmega8 running from the internal oscillator with an UART that lost sync below zero. For VGA a crystal is a must.
Power consumption - internal oscillators usually will be more power efficient than external crystals
Available frequencies. For example to get ideal 115200 baud UART timing on an ATmega8 you will need a clock with an "oddball" frequency of 7.3728 MHz, while the closest frequency the internal clock can only deliver 8 Mhz (so some bauds will not be available).
Depending on the exact MCU you can also get great clock stability if you use it as an USB device. The internal oscillator can lock on to the clock signal from the USB host (that is crystal-stabilized).
Most practical differences I have encountered:
Frequency stability (especially across different temperatures). It depends on your application if you need a very stable clock or not. I had issues once using an ATmega8 running from the internal oscillator with an UART that lost sync below zero. For VGA a crystal is a must.
Power consumption - internal oscillators usually will be more power efficient than external crystals
Available frequencies. For example to get ideal 115200 baud UART timing on an ATmega8 you will need a clock with an "oddball" frequency of 7.3728 MHz, while the closest frequency the internal clock can only deliver 8 Mhz (so some bauds will not be available).
Depending on the exact MCU you can also get great clock stability if you use it as an USB device. The internal oscillator can lock on to the clock signal from the USB host (that is crystal-stabilized).
answered 10 mins ago
filo
5,5651930
5,5651930
add a comment |Â
add a comment |Â
Varun Sahni is a new contributor. Be nice, and check out our Code of Conduct.
Varun Sahni is a new contributor. Be nice, and check out our Code of Conduct.
Varun Sahni is a new contributor. Be nice, and check out our Code of Conduct.
Varun Sahni is a new contributor. Be nice, and check out our Code of Conduct.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2felectronics.stackexchange.com%2fquestions%2f401594%2fdifference-between-internal-and-external-oscillator-for-a-microcontroller%23new-answer', 'question_page');
);
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password