PDA

View Full Version : Do I need an oscillator?



ERMEGM
- 29th July 2015, 05:14
Hello All,

I haven't finalized the design, but I'm thinking I will be using the 16F819. I have a module that I'm making that will do certain functions when certain inputs are activated, but I wanted to ask about one feature I was going to be implementing and needed to know if the oscillator was necessary.

The one feature this module will have is that when a certain input is activated, the module will begin a timed output. After this time expires, the output will turn off. However, the twist is this; because I want to monitor the other inputs in 1/10th second increments, do I even need an external oscillator? The pic usually handles short counts quite accurately. I would just use a counter to keep track of the number until say 5 minutes is reached. It doesn't have to be accurate, the timed output is simply to prevent excessive draw on the battery.

So, using a pause 100 command along with a counter seems pretty straight forward to me, but I just wanted to run it past you guys to see if I was missing something. If another input is activated, the timer would simply exit and reset it's count.

My logic seems sound unless someone objects.

Thanks,
Tony

HenrikOlsson
- 29th July 2015, 07:32
Hi Tony,
As long as the accuracy of the internal oscillator is good enough for you then it's fine.
Short times or long times doesn't matter from that perspective, if the oscillator is 2% "out" it's 2% "out". Short or long delays, no difference, it's still 2%.

/Henrik.

ERMEGM
- 30th July 2015, 20:49
That's what I thought, but I just wanted to be sure. Thank you.

Tony