02-09-2011 01:54 PM
Can you use 2 pins to drive a crystal to make an oscillator with the CoolRunner II?
02-09-2011 02:48 PM
u,
It is not reecommended,nor supported. No: don't do it.
Although a simple 74HC04 inverter, with two capacitors, and aresistor may make a simple oscillator, the IO cell in the CPLD (or FPGA) is too complex, and the oscillator will very likely, not oscillate.
Simple cyrstal oscillators integrate the inverter, and a buffer, and the two capacitors, and the resistor, and get tested before they get shipped. Using crystrals is one of the toughest devices to get right, in high volumes. Any slight change in the crystal will result in the oscillator failing to start oscillating. Hence the reason why so many avoid the problem, and pass it along to their customers, and suggest they go buy a perfectly good, and tested, crystal oscillator.
Let someone else through away the bad ones, and provide you the good ones.
There are also (now) all silicon oscillators, with accuracies as good as a few hundred ppm (no crystal). At some point this technology shoud appear in PLD's (future).
02-09-2011 03:08 PM
We're using some very inexpensive MEMS oscillators from Ecliptek in a 2 x 2.5mm
package that you can squeeze almost anywhere on a board. I don't know if you can
get a crystal that small.
As for using a crystal, even with a circuit designed as a crystal oscillator you can
have problems. In my first job we were making flatbed position plotters made
for marine navigation. The 8085 CPU in the product had two pins and we attached
a crystal per the datasheet. Sometime down the road, the 8085 silicon got a
smidge faster and the plotters didn't work. I found out that the crystals were
suddenly oscillating in the "third overtone" mode. Additional capacitance on the
pins fixed the issue, but you get the picture. Oscillators are small, and cheap.
Crystals are not simple.
-- Gabor
02-09-2011 04:10 PM
Agreed - the simple answer is no.
Here are some other resources where this topic has been discussed before for CPLDs and FPGAs:
http://www.xilinx.com/support/answers/24167.htm (CPLD Frequently Asked Questions for XC9500/XL/XV and CoolRunner-II/XPLA3 families)
http://forums.xilinx.com/t5/Spartan-Family-FPGAs/Direct-Crystal-connection-to-Spartan-6-FPGA/m-p/79957 (Direct Crystal connection to Spartan-6 FPGA)
http://groups.google.com/group/comp.arch.fpga/browse_thread/thread/edacfd6565ccd1bf# (Dual-frequency quartz oscillator with a FPGA ?)
http://groups.google.com/group/comp.arch.fpga/browse_thread/thread/670708f58118601e/6bb5acbf5e7c8667 (behavior of crystal oscillator)
http://groups.google.com/group/comp.arch.fpga/browse_thread/thread/9ba1f52ad7c1183e# (Can I use a crystal for the clock source for a Xilinx Spartan 3A FPGA?)
Cheers,
bt
02-09-2011 04:33 PM
We're using some very inexpensive MEMS oscillators from Ecliptek in a 2 x 2.5mm package that you can squeeze almost anywhere on a board
How cheap, Gabor, and what sort of volume? When I was working for a huge consumer products company, we would get pricing under 20 cents for a "real" crystal oscillator. As an independent small fry, I'm looking at 60 cents or more for a Maxim non-crystal oscillator.
- Bob
02-10-2011 07:04 AM
The company I work for is small, but not so small that I'm involved in purchasing.
However in small quantities we're paying around $1.75 - $2.00 depending on
frequency and voltage. All of the oscillators are spec'd at 50 ppm over the industrial
temperature range, tough to get with "real" crystal oscillators without temperature
compensation. For our products this is cheap enough. I'm sure you could do better
in large volume. Also we originally used them for products with higher vibration
tolerance requirements, which is also tough to get from crystals. After I realized
that the price point was low enough, I've been using them pretty much everywhere,
especially for space-constrained applications like notebook add-in cards (ExpressCard)
and cameras. Another cool thing about the MEMS oscillators is that unlike crystals
they are not manufactured to frequency, but programmed after the fact, so you
can get quick turn on pretty much any frequency.
-- Gabor
02-10-2011 08:46 AM
Thanks Gabor.
To anyone else who might be listening, SiLabs Si500S parts may be worth considering. In moderate volumes, they are cost competitive with Maxim DS1088 parts (under $1) -- and without the supply/availability drama which Maxim parts occasionally bring.
Datasheet spec is +/- 10-20 PPM typical, +/- 250PPM over temperature and 10-year life. This isn't good enough fit for Gabor's application, but certainly good enough for many digital system designs.
- Bob Elkind