2 timers in pic16f676

retched

Joined Dec 5, 2009
5,207
Ok. You dont need 2 timers to do this.

You only need to read the 1 timer and to perform an action after X number of ms and Y number or ms.

When you reset the timer, it will start counting.

You can read the timer and see that timer=5200 ms have passed so you would say:

You will code to say:
After beeptime=timer+500000ms then BEEP
buztimer=timer+1000000 then BUZZ

You are reading the current time (timer) then you want to perform an action 50000) ms later (timer+50000)

Your 50hz pulse could be done easily with a PIC that has hardware PWM.

I dont believe the 16f676 does. SO, search around for using PWM on the 16f676 with software, and you can do it that way.
 

ErnieM

Joined Apr 24, 2011
8,377
I have to know how configure Timer pin in mikroC for pic16f676.Would anyone help me!!
Hello Paul, welcome to the forums!

First off, each thread is assumed to be owned by the person who started it. It is confusing to ask your own question in someone else's thread, but threads are cheap so you should just start your own. A moderator may come by soon and move your q to it's own thread.

The '676 has 2 timers inside, each may be clocked either with an internal signal, or thru a pin from the outside.

Are you trying to use the external pin? For which timer?
 
Top