Config Event_system = Dummy , _
Mux3 = Portd.1
Config Event_system = Dummy , Mux0 = Portd.1
Config Pind.1 = Input
Config Xpin = Pind.1 , Invertio = Disabled , Slewrate = Disabled , Outpull = Totem , Sense = Falling
Config Tcd1 = Normal , Prescale = E3 , Capturea = Enabled , Event_source = E3 , Event_action = Capture 'stary
'interrupt every one second
Capture_e:
cnt1= Tcd1_cnt 'counter pulses portd.1
Print#1 , "p" ; cnt1
Tcd1_cnt = 0
Return
|