asp1987
New Member
Hi..
Could anyone provide some links on 18 series PIC programming? I wrote a simple LED flashing program. But it doesn't work. Pls help.
Could anyone provide some links on 18 series PIC programming? I wrote a simple LED flashing program. But it doesn't work. Pls help.
Code:
MOVLW 0x0F
MOVWF BSR,1 ; bankselect
BCF TRISD,1,1 ; rd1 output
ASP
BSF PORTD,1,1 ; led on
CALL DELAY
BCF PORTD,1,1 ; led off
CALL DELAY
GOTO ASP
DELAY
LOOP1
DECFSZ COUNT1,F,1
GOTO LOOP1
DECFSZ COUNT2,F,1
GOTO LOOP1
RETURN
COUNT1 EQU 0xFF00 ; variable dec.
COUNT2 EQU 0xFF01
Last edited: