bianchi77
Advanced Member level 4
- Joined
- Jun 11, 2009
- Messages
- 1,313
- Helped
- 21
- Reputation
- 44
- Reaction score
- 20
- Trophy points
- 1,318
- Location
- California
- Activity points
- 9,442
Guys,
I have a code like this :
How can I create a counter so I will have 1ms timer ?
thanks
I have a code like this :
Code:
;....... 1ms timer counter here.....
clrf TMR0 ;Clear TMR0 and prescaler
banksel TMR0
movlw 0xB2 ;Count=B2
movwf TMR0
;=======================================
;....................................
incf COUNT, f
movlw .10 ;Compare count to 10 decimal
subwf COUNT, W ;Store the result back in
btfss STATUS, C ;Is the result 0, skip if no
goto exittimer
How can I create a counter so I will have 1ms timer ?
thanks