;********************************************************************* ; * ; PIC12C5X Tutorial 3: Counter Mode Rising TOKI no prescalar * ; * ;********************************************************************* ;* TARGET PIC12C5X ;********************************************************************* ;* @version 0.1, 11 October 2001 ;* @author James Caska ;********************************************************************* ;* ;* Runs on Processors without change ;* ;* PIC12C508 ;* PIC12C518 ;* PIC12C509 ;* PIC12C519 ;* ;********************************************************************* #include list p=12C508 ORG .0 ;========================================== ;Autogenerated configuration code PIC12C5X ;Config Wiz V0.1, www.virtualbreadboard.com ;========================================== ;======Begin PORT Configuration ;======GPIO Port MOVLW .4 ;GPIO Configuration Bits TRIS GPIO CLRF GPIO ;========================================== ;Autogenerated configuration code PIC12C5X ;Config Wiz V0.1, www.virtualbreadboard.com ;========================================== ;======Begin Timer0 Configuration ;Timer0 Counter Mode, uses External clock source ;T0SE: TMR0 Source Edge Select bit: 0 = Increment on low-to-high transition on T0CKI pin ;Prescalor Assigned to Watchdog, Timer0 Prescalor = 1:1, WDT Prescalor = 1:1 MOVLW .40 OPTION ;======End Timer0 Configuration MAIN MOVF TMR0,W MOVWF GPIO GOTO MAIN END