Professional Documents
Culture Documents
equ__33FJ16MC304,1
.include
“p33FJ16MC304.INC”
.global_main
.text
_main:
mov #0x0000,w0
mov w0,TRISB
mov #0x0FFF,w1
mov w1,TRISC
mov #0x03e8,w3
inicio:
btss PORTC,#0
goto inicio
goto secuencia
secuencia:
mov #b0000000000001,w2
mov w2,PORTB
CALL delay
mov w0,PORTB
call delay
mov #b0000000000010,w2
mov w2,PORTB
CALL delay
mov w0,PORTB
call delay
mov #b0000000000100,w2
mov w2,PORTB
CALL delay
mov w0,PORTB
call delay
mov #b0000000001000,w2
mov w2,PORTB
CALL delay
mov w0,PORTB
call delay
mov #b0000000100000,w2
mov w2,PORTB
CALL delay
mov w0,PORTB
call delay
mov #b0000001000000,w2
mov w2,PORTB
CALL delay
mov w0,PORTB
call delay
mov #b0000010000000,w2
mov w2,PORTB
CALL delay
mov w0,PORTB
call delay
mov #b0000100000000,w2
mov w2,PORTB
CALL delay
mov w0,PORTB
call delay
mov #b0001000000000,w2
mov w2,PORTB
CALL delay
mov w0,PORTB
call delay
mov #b0010000000000,w2
mov w2,PORTB
CALL delay
mov w0,PORTB
call delay
mov #b0100000000000,w2
mov w2,PORTB
CALL delay
mov w0,PORTB
call delay
mov #b1000000000000,w2
mov w2,PORTB
CALL delay
mov w0,PORTB
call delay
delay:
dec w3,w4
mov w4,w3
repeat #0x03e8
nop
cp0 w4
bra nz,delay
mov #0x03e8,w3
return
.end