Likewise, the highest I've seen is 8MHz - bear in mind this is an RC oscillator, 20MHz sounds unlikely for an RC oscillator!.
As already suggested, if you need this speed use a crystal - it will be far more accurate and stable, although you may need to move to a larger PIC to keep sufficient I/O pins.
Here's a related question. Using a 629 with the internal oscillator, I see communication errors occur at different voltages. For example I get proper communication at 3 V, but not at 4.5 volts (a few bit errors occur). It is obviously a timing problem. So is it to be expected that the frequency will deviate substantially at different voltages using the internal oscillator?
Here's a related question. Using a 629 with the internal oscillator, I see communication errors occur at different voltages. For example I get proper communication at 3 V, but not at 4.5 volts (a few bit errors occur). It is obviously a timing problem. So is it to be expected that the frequency will deviate substantially at different voltages using the internal oscillator?
It probably will, I believe the datasheet gives a number of graphs related to internal oscillator speed variations. Personally I've never had a problem though, how fast are you trying to run a serial link?, and are you using the hardware USART?.
9600 baud IRDa. It's just pure software - it doesn't seem the 629 has a USART. According to the datasheet, the 629 runs slower at 4.5V compared to 3.0V. Oddly enough, I have to increase my bit length from 104 uS to 110 uS to run properly at 4.5V, which is opposite of the datasheet. I should have to reduce my bit length if the PIC runs slower at the higher voltage, according to the datasheet. Weird.
Just noticed that I switched PICs mid-thread on you. The timing problem is specifically with the 629, although I mentioned the 628 at the beginning of the thread, which is for a different project.
There must be other variables affected by supply voltage besides the internal oscillator frequency. The Freq/Vdd timing chart for the '629 shows the typical osc. frequency varying from 4Mhz @ 3V to ~ 3.98Mhz @ 4.5V. Taken alone, this would increase the bit length to about 104.5 uS, not enough to account for the variation you're seeing.
Propagation delays decrease with increasing supply voltage (datasheet shows 10-40 nS range for the outputs) but not nearly enough for a difference of several microseconds. Maybe there's another factor we're missing. I'm stumped!
I placed a 1k resistor on vDD and that solved the problem. The frequency is stable from 2.8 to 6 V - at least stable enough so there is no communication errors.