Can I use 16.9344Mhz Crystal Oscillator instead of 16.000Mhz ?

So the title explains it. I was making a PCB with ATMEGA328p tqfp and I needed a 16mhz crystal between XTAL1 and XTAL2. But, I accidentally bought 16.9344Mhz crystal oscillator instead of a 16.000Mhz crystal oscillator. So I wanted to know if I could use the one I bought or I need to get the 16Mhz one ?

Thanks in advance.

It will run but all the timing will be off. But not alone for things like millis, but also for Serial. And I think 6% difference is going to be to much for the faster Serial and thus bootloader.

So, what you are saying is, it should work but it will be inaccurate with errors with the 16mhz bootloader ??
So I should not use it ?

If you want to upload via serial with that you'd need to recompile the bootloader and make a new board definition to compile your sketches for that speed.

The crystal is used as the basis for all timing, so it messes up a lot of stuff when its not at the right speed.

16mhz crystals are dirt cheap. I suggest you get one.

UART protocols will stand up to about 10% frequency error - so you can probably down load .

But all the timing of your code will be off.

Aren't 16MHz crystals pretty cheap ? - get some

Allan

Thanks guys. I wanted to complete my board today. But I guess I gotta wait :). I know that the 16MHz are cheap and I have to go again tomorrow to buy them.

In the mean time you could run the board off the internal 8MHz :slight_smile:

Crystal, or crystal oscillator? They're different.