; __________________________________________________; |          "Mid Air" Oscillating LED Sign         |; |By Josh Wardell      April, 1999      for CSE 398|; |MPASM asm for the Microchip 16C84 microcontroller|; |(C) 1999 Josh Wardell     http://www.jwardell.com|; |_________________________________________________|		list    p=16C84		radix   hex		include "p16c84.inc"        cblock  0x0C		dtime		tick		tick2        endc                org     0x00                goto    start		org	0x04Intsvc		retfieinitstuff       movlw   0x00                tris    PORTB                clrwdt		movlw	0x18		;delay time		movwf	dtime                retlw   0dsmile		movlw	b'00010000'		movwf   PORTB                call    delay2		movlw	b'00100100'		movwf   PORTB                call    delay2		movlw	b'00100000'		movwf   PORTB                call    delay2		movlw	b'00100100'		movwf   PORTB                call    delay2		movlw	b'00010000'		movwf   PORTB                call    delay2		movlw	b'00000000'		movwf   PORTB                call    delay2		returndjcap		movlw	b'00100001'		movwf   PORTB                call    delay2		movlw	b'01000001'		movwf   PORTB                call    delay2		movlw	b'00111111'		movwf   PORTB                call    delay2		movlw	b'00000001'		movwf   PORTB                call    delay2		movlw	b'00000001'		movwf   PORTB                call    delay2		returndolow		movlw	b'00110000'		movwf   PORTB                call    delay2		movlw	b'01001000'		movwf   PORTB                call    delay2		movlw	b'00110000'		movwf   PORTB                call    delay2		movlw	b'00000000'		movwf   PORTB                call    delay2		returndslow		movlw	b'01010000'		movwf   PORTB                call    delay2		movlw	b'00101000'		movwf   PORTB                call    delay2		movlw	b'00000000'		movwf   PORTB                call    delay2		returndhlow		movlw	b'01111111'		movwf   PORTB                call    delay2		movlw	b'00001000'		movwf   PORTB                call    delay2		movlw	b'01110000'		movwf   PORTB                call    delay2		movlw	b'00000000'		movwf   PORTB                call    delay2		returndwcap		movlw	b'00011111'		movwf   PORTB                call    delay2		movlw	b'01100000'		movwf   PORTB                call    delay2		movlw	b'00010000'		movwf   PORTB                call    delay2		movlw	b'01100000'		movwf   PORTB                call    delay2		movlw	b'00011111'		movwf   PORTB                call    delay2		movlw	b'00000000'		movwf   PORTB                call    delay2		returndisplay     		;call	dsmile		                call    delay2                call    delay2		call	djcap		call	dolow		call	dslow		call	dhlow		call	dwcap                call    delay2                call    delay2		                call    delay2		                call    delay2                retlw   0delay           movf    dtime,0		movwf	tickdelayloop	decfsz  tick,f                goto    delayloop                return                retlw	0delay2          movf    dtime,0		movwf	tick2DL2		call	delay		decfsz  tick2,f                goto    DL2                return                retlw   0start           call    initstuffspin		call    display		goto    spin                end
