??? 09/26/11 08:00 Read: times |
#183870 - One suggession for higher frequency Responding to: ???'s previous message |
Ralph,
In somewhere in your post you said that you may perhaps want to generate frequency greater than 50hz.This program is not guaranty of accuracy for higher frequency as scantime of program might affect the accuracy of freq.At that time you may utilse the feature of 89c52 of freq. generation.For this IC you need not to write the program for making pin high or low.The pin no#1(it is fix) is configured as freq. o/p.it is of 50 % duty cycle too.You have to just calculate the count(The formula is given in 89c52 datasheet) & load into the timer register and just set the timer bit on.That will make the desired freq. o/p at pin #1.If you need to stop this freq. at any time you just clear the timer flag.This way the minimum freq. of approx 45Hz & maximum greater than 10khz you may generate with 12MHz crystal. |