#include <16f628a.h>
#FUSES NOWDT
#FUSES INTRC_IO
#FUSES NOBROWNOUT
#FUSES NOLVP
#use delay(int=4000000)
#use fast_io(a)
#use fast_io(b)
unsigned int i=0,z=0;
#int_timer1 // timer0 kesmesi
void timer1_kesme()
{
set_timer1(55543);
i++;
if(i==100)
{
output_toggle(pin_b0);
i=0;z++;
if(z==10)
{
output_toggle(pin_b1);
z=0;
}
}
clear_interrupt(int_timer1);
}
void main()
{
set_tris_a(0x00);
set_tris_b(0x00);
output_a(0x00);
output_b(0x00);
setup_ccp1(CCP_OFF);
setup_timer_1(T1_INTERNAL|T1_DIV_BY_1);
set_timer1(55543);
enable_interrupts(INT_TIMER1);
enable_interrupts(GLOBAL);
while(1)
{
output_high(pin_b7);
}
}