132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
| int
;***** TMR0 Interruption ( 1 millisecond interval) ******
bcf intcon,t0if ;Clear timer int flag
movlw d'6' ;Set 1 millisecond
movwf tmr0 ;Set TMR0
movlw ra_adr ;Read RA table head adr
addwf ra_index,w ;RA table head + index
movwf fsr ;Set table address
movfw indf ;Read data
movwf porta ;Set data to PORTA
incf ra_index,f ;RA index + 1
movfw ra_index ;Read RA index
sublw d'5' ;Check upper limit
btfss status,c ;Over ?
clrf ra_index ;Yes. Clear PORTA index
以下省略 |