Evening ,
looking at my next project which uses a pic16f73 with lcd display and a pwm output to drive a resistor to generate heat for checking thermocouples, with a lm58 temp sensor for feedback.
Not too sure how to select the crystal size looking for some advice as 20 Mhz seems a bit excessive and possibly too fast ?
i don't need mega quick, how will a 3 or a 1 mhz crystal affect the pwm and the lcd display ? Timings
how do i size the capacitors for the crystals ?
a confused steve
Crystal selection advise required please
- Steve001
- Valued Contributor
- Posts: 1189
- Joined: Wed Dec 31, 2008 3:37 pm
- Has thanked: 460 times
- Been thanked: 523 times
- Contact:
Crystal selection advise required please
Last edited by Steve001 on Thu Aug 11, 2011 7:24 am, edited 1 time in total.
Success always occurs in private and failure in full view.
- JohnCrow
- Valued Contributor
- Posts: 1367
- Joined: Wed Sep 19, 2007 1:21 pm
- Location: Lincolnshire
- Has thanked: 364 times
- Been thanked: 716 times
- Contact:
Re: Crystal selection advise required please
Hi Steve.
Sounds an interesting project.
What sort of temperatures are you looking to generate?
Not used the LM58, I've done a few programs with the LM35, thats a nice simple device to use).
Sounds an interesting project.
What sort of temperatures are you looking to generate?
Not used the LM58, I've done a few programs with the LM35, thats a nice simple device to use).
1 in 10 people understand binary, the other one doesn't !
- Steve001
- Valued Contributor
- Posts: 1189
- Joined: Wed Dec 31, 2008 3:37 pm
- Has thanked: 460 times
- Been thanked: 523 times
- Contact:
Re: Crystal selection advise required please
Hi John,
Looking for 150 C the LM58, is simlar to the LM35 but higher temp
Steve
Looking for 150 C the LM58, is simlar to the LM35 but higher temp
Steve
Success always occurs in private and failure in full view.
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: Crystal selection advise required please
Hello,
Regarding crystals you must remember that the pic will run at 1/4 of the crystal speed and then things like PWM will run up to 1/4/16 times slower.
If your using Flowcode then the LCD timings will always be correct as long as you enter the correct crystal speed into Flowcode. Otherwise you need to setup loops to delay for the correct period when driving the LCD.
Capacitor values can be seen in the device datasheet under the oscillator section but I normally use 18 or 22pF for most crystals.
Regarding crystals you must remember that the pic will run at 1/4 of the crystal speed and then things like PWM will run up to 1/4/16 times slower.
If your using Flowcode then the LCD timings will always be correct as long as you enter the correct crystal speed into Flowcode. Otherwise you need to setup loops to delay for the correct period when driving the LCD.
Capacitor values can be seen in the device datasheet under the oscillator section but I normally use 18 or 22pF for most crystals.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel