I don't see why are needed here 1 and 2, the tmr0 always is rollowing from 255 to 0 at every intcon_t0if events. Also clearing intcon_t0if have nothing to do with t0ie or gie. You may use intcon_t0if without enabling any interrupts in the main program. regards, Vasile timer0_int 1 movlw 0 2 movwf TMR0 > bcf INTCON,T0IF > goto end_int On Thu, 14 Feb 2002, Tony Nixon wrote: > Benjamin Menk=FCc wrote: > > > > but it goes already to timer0_int so the bank should be right.... And i= am > > pretty sure that my pic is not broken.. However i am doing isp debuggin= =2E.. > > might that be the reason? > > I just simulated that code with this simple program and it works ok, so > perhaps you have the WDT enabled, or something is wrong in the main > loop. > > > =09list P =3D 16F84 > > =09#include "p16f84.inc" > > =09ORG 0h > =09goto start > > =09ORG 0x0004 > > =09btfsc INTCON,T0IF > =09goto timer0_int > =09goto end_int > timer0_int > =09movlw 0 > =09movwf TMR0 > =09bcf INTCON,T0IF > =09goto end_int > asdaa > =09nop > =09goto asdaa > end_int > =09retfie > > > start=09bsf STATUS,RP0=09=09; prescale =3D 1:2 > =09clrf OPTION_REG > =09bcf STATUS,RP0 > =09clrf INTCON > =09bsf INTCON,T0IE=09=09; enable TMR0 IRQ > =09bsf INTCON,GIE > > Loop=09nop > =09nop > =09goto Loop > > =09end > > > -- > Best regards > > Tony > > mICros > http://www.bubblesoftonline.com > mailto:sales@bubblesoftonline.com > > -- > http://www.piclist.com hint: The PICList is archived three different > ways. See http://www.piclist.com/#archives for details. > > -- http://www.piclist.com#nomail Going offline? Don't AutoReply us! email listserv@mitvma.mit.edu with SET PICList DIGEST in the body