Hooking up another Xtal to the propeller
Zap-o
Posts: 452
If I were to hook up a xtal to 2 pins on the prop say pin0-pin1 would I need to insert a resistor to limit the current (I know - sounds stupid)? I looked over the data sheet and it mentioned nothing regarding current.
Second thing - According to wiki if a voltage is applied to the xtal it will resonate. Do i need to pulse one of the pins or leave it on high?
My idea is to make a quartz clock using the propeller and a xtal.
Thanks in advance,
Post Edited (Zap-o) : 5/15/2009 11:34:43 PM GMT
Second thing - According to wiki if a voltage is applied to the xtal it will resonate. Do i need to pulse one of the pins or leave it on high?
My idea is to make a quartz clock using the propeller and a xtal.
Thanks in advance,
Post Edited (Zap-o) : 5/15/2009 11:34:43 PM GMT
Comments
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
My new unsecure propmod both 1x1 and full size arriving soon.
I once tried what you're attempting using a counter with negative feedback and a 32KHz crystal. I got it to oscillate, and the fundamental frequency was correct, but there were high-frequency glitches on the transitions, which rendered the output useless as the input to an edge counter. I eventually ended up with so many external components trying to add hysteresis and other tricks to clean it up, that I gave up. It would've been easier just to build an external oscillator from scratch.
Beau Schwab is the real expert in these matters. Maybe if he's is lurking nearby, he can offer some suggestions.
-Phil
2) Not quite true. If a voltage is applied, the crystal will bend slightly with the direction dependent on the polarity of the voltage. If you turn off the voltage, the crystal will come back to center. The crystal will actually vibrate slightly for a brief period as the mechanical motion damps down. If you put the voltage back on the crystal as it's moving back off center, then it will continue moving. If you apply an alternating voltage to the crystal so that the frequency of the voltage changes matches the mechanical resonance of the crystal, then you'll get a steady vibration at the resonant frequency of the crystal.
3) Although it would be possible to make a crystal oscillator using two Propeller pins, one input and one output, you'd be better off using a cheap, simple CMOS IC like a hex buffer as an oscillator. You can find plenty of circuit diagrams for this on the internet. The output of the oscillator would be fed to a single Propeller I/O pin for counting.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
My Prop Info&Apps: ·http://www.rayslogic.com/propeller/propeller.htm
here is my clock circuit for the propgalore brain board. The ic is a standard hex inverter pack. I did not design it and have not goten my pcb back to test it yet.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
My new unsecure propmod both 1x1 and full size arriving soon.
Need to upload large images or movies for use in the forum. you can do so at propmodule.com/upload.html for free.
Post Edited (mctrivia) : 5/16/2009 8:37:57 AM GMT
-Phil
Some of you mentioned getting a dedicated clock ic, using the existing xtal on the prop etc. Sorry my hard head wont sleep well using that approach. I am really interested in learning more about the way xtals are used. I have read many data sheets for "clock" ics and most require a Xtal running a frequency at 32768
i have a temperature compensated rtc some where that has a built in xtal. much more accurate then most.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
My new unsecure propmod both 1x1 and full size arriving soon.
Need to upload large images or movies for use in the forum. you can do so at propmodule.com/upload.html for free.
I've got some sample code for it here:
http://www.rayslogic.com/propeller/Programming/Programming.htm
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
My Prop Info&Apps: ·http://www.rayslogic.com/propeller/propeller.htm
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
My new unsecure propmod both 1x1 and full size arriving soon.
Need to upload large images or movies for use in the forum. you can do so at propmodule.com/upload.html for free.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
My new unsecure propmod both 1x1 and full size arriving soon.
Need to upload large images or movies for use in the forum. you can do so at propmodule.com/upload.html for free.
Xtals are suposed to be extremely selective feedback components, not mecanical actuators. I tried many decades ago to use some 32KHz slabs as ultrasonic sender/receivers, the tx one would shatter before any useful range could be got.